Merge branch 'release/1.11.0' of ssh://git.mnml.gg:40022/~/mnml into release/1.11.0
This commit is contained in:
commit
c2c9113996
@ -33,6 +33,10 @@ const ws = createSocket(events);
|
||||
ws.connect();
|
||||
events.setWs(ws);
|
||||
|
||||
if (process.env.NODE_ENV !== 'development') {
|
||||
LogRocket.init('yh0dy3/mnml');
|
||||
}
|
||||
|
||||
const App = () => (
|
||||
<Provider store={store}>
|
||||
{window.Stripe
|
||||
|
||||
@ -106,13 +106,12 @@ function registerEvents(store) {
|
||||
}
|
||||
|
||||
function setAccount(account) {
|
||||
if (account && process.env.NODE_ENV !== 'development') {
|
||||
LogRocket.init('yh0dy3/mnml');
|
||||
LogRocket.identify(account.id, account);
|
||||
if (account && window.Notification) {
|
||||
window.Notification.requestPermission();
|
||||
}
|
||||
|
||||
if (window.Notification) {
|
||||
window.Notification.requestPermission();
|
||||
}
|
||||
if (process.env.NODE_ENV !== 'development') {
|
||||
LogRocket.identify(account.id, account);
|
||||
}
|
||||
|
||||
store.dispatch(actions.setAccount(account));
|
||||
|
||||
@ -1,5 +1,2 @@
|
||||
# FIXME
|
||||
game ready not auto starting resolve phase
|
||||
|
||||
slay animation still looks a bit weird
|
||||
triaged / decayed / siphoned / electrocute effect removal with purify / purge
|
||||
|
||||
@ -950,7 +950,10 @@ impl Construct {
|
||||
if self.is_ko() { return vec![Event::TargetKo { construct: self.id }] }
|
||||
|
||||
if let Some(p) = self.effects.iter().position(|ce| ce.effect == effect) {
|
||||
self.effects.remove(p);
|
||||
let ce = self.effects.remove(p);
|
||||
|
||||
if ce.effect.hidden() { return vec![] }
|
||||
|
||||
return vec![Event::Removal {
|
||||
construct: self.id,
|
||||
effect: effect,
|
||||
@ -986,11 +989,13 @@ impl Construct {
|
||||
if self.is_ko() { return vec![Event::TargetKo { construct: self.id }] }
|
||||
|
||||
while let Some(ce) = self.effects.pop() {
|
||||
removals.push(Event::Removal {
|
||||
construct: self.id,
|
||||
effect: ce.effect,
|
||||
display: EventConstruct::new(self),
|
||||
});
|
||||
if !ce.effect.hidden() {
|
||||
removals.push(Event::Removal {
|
||||
construct: self.id,
|
||||
effect: ce.effect,
|
||||
display: EventConstruct::new(self),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
return removals;
|
||||
|
||||
@ -336,7 +336,11 @@ impl Game {
|
||||
|
||||
|
||||
pub fn clear_skill(&mut self, player_id: Uuid) -> Result<&mut Game, Error> {
|
||||
self.player_by_id(player_id)?;
|
||||
let player = self.player_by_id(player_id)?;
|
||||
if player.ready {
|
||||
return Err(err_msg("cannot clear skills while ready"));
|
||||
}
|
||||
|
||||
if self.phase != Phase::Skill {
|
||||
return Err(err_msg("game not in skill phase"));
|
||||
}
|
||||
@ -2060,7 +2064,7 @@ mod tests {
|
||||
let resolutions = &game.resolutions[last];
|
||||
|
||||
assert!(resolutions.iter().any(|r| match r.event {
|
||||
Event::Damage { construct, colour, amount, mitigation: _, display: _ } =>
|
||||
Event::Damage { construct, colour, amount, mitigation: _, display: _ } =>
|
||||
construct == target && amount == 320.pct(50) && colour == Colour::Blue,
|
||||
_ => false,
|
||||
}));
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user