Merge branch 'develop' of ssh://mnml.gg:40022/~/mnml into develop
This commit is contained in:
commit
437eaf8039
@ -40,7 +40,7 @@ function Skill(props) {
|
||||
const s = construct.skills[i];
|
||||
const ko = construct.green_life.value === 0 ? 'ko' : '';
|
||||
|
||||
if (!s) {
|
||||
if (!s || !game) {
|
||||
return (
|
||||
<button
|
||||
disabled='true'
|
||||
|
||||
@ -26,6 +26,7 @@ class TargetSvg extends Component {
|
||||
render(props, state) {
|
||||
const { game, account, animating, animTarget } = props;
|
||||
const { width, height } = state;
|
||||
if (!game) return false; // game will be null when battle ends
|
||||
|
||||
// resolutions happening
|
||||
// just put skill name up
|
||||
|
||||
@ -9,14 +9,15 @@ function registerEvents(store) {
|
||||
store.dispatch(actions.setPing(ping));
|
||||
}
|
||||
|
||||
function setTeam(team) {
|
||||
store.dispatch(actions.setTeam(team));
|
||||
}
|
||||
|
||||
function setNav(v) {
|
||||
store.dispatch(actions.setNav(v));
|
||||
}
|
||||
|
||||
function setTeam(team) {
|
||||
store.dispatch(actions.setTeam(team));
|
||||
setNav('list');
|
||||
}
|
||||
|
||||
function setConstructList(constructs) {
|
||||
store.dispatch(actions.setConstructs(constructs));
|
||||
}
|
||||
|
||||
@ -1238,9 +1238,6 @@ pub fn get_combos() -> Vec<Combo> {
|
||||
Combo { components: Item::Break.combo(), item: Item::Break },
|
||||
Combo { components: Item::BreakPlus.combo(), item: Item::BreakPlus },
|
||||
Combo { components: Item::BreakPlusPlus.combo(), item: Item::BreakPlusPlus },
|
||||
Combo { components: Item::Absorb.combo(), item: Item::Absorb },
|
||||
Combo { components: Item::AbsorbPlus.combo(), item: Item::AbsorbPlus },
|
||||
Combo { components: Item::AbsorbPlusPlus.combo(), item: Item::AbsorbPlusPlus },
|
||||
Combo { components: Item::Banish.combo(), item: Item::Banish },
|
||||
Combo { components: Item::BanishPlus.combo(), item: Item::BanishPlus },
|
||||
Combo { components: Item::BanishPlusPlus.combo(), item: Item::BanishPlusPlus },
|
||||
|
||||
@ -242,7 +242,7 @@ fn logout(req: &mut Request) -> IronResult<Response> {
|
||||
|
||||
tx.commit().or(Err(MnmlHttpError::ServerError))?;
|
||||
|
||||
let mut res = iron_response(status::Ok, "token_res".to_string());
|
||||
let mut res = iron_response(status::Ok, "logout".to_string());
|
||||
res.headers.set(SetCookie(vec![AUTH_CLEAR.to_string()]));
|
||||
Ok(res)
|
||||
|
||||
|
||||
@ -314,7 +314,7 @@ fn post_resolve(_skill: Skill, game: &mut Game, mut resolutions: Resolutions) ->
|
||||
.find(|e| e.effect == Effect::Absorb).unwrap().clone();
|
||||
match meta {
|
||||
Some(EffectMeta::Skill(s)) => {
|
||||
resolutions = absorption(&mut target, &mut source, resolutions, skill, amount, s);
|
||||
resolutions = absorption(&mut source, &mut target, resolutions, skill, amount, s);
|
||||
},
|
||||
_ => panic!("no absorb skill"),
|
||||
};
|
||||
@ -1495,7 +1495,7 @@ fn electrocute(source: &mut Construct, target: &mut Construct, mut results: Reso
|
||||
let electrocute = ConstructEffect::new(effect, duration).set_tick(Cast::new_tick(source, target, tick_skill));
|
||||
results.push(Resolution::new(source, target)
|
||||
.event(target.add_effect(skill, electrocute))
|
||||
.stages(EventStages::StartPost));
|
||||
.stages(EventStages::EndPost));
|
||||
return electrocute_tick(source, target, results, tick_skill);
|
||||
}
|
||||
|
||||
@ -1679,7 +1679,7 @@ fn purge(source: &mut Construct, target: &mut Construct, mut results: Resolution
|
||||
if turns > 0 {
|
||||
let mut effect = skill.effect()[0];
|
||||
effect.duration = effect.duration * turns;
|
||||
results.push(Resolution::new(source, target).event(target.add_effect(skill, effect)));
|
||||
results.push(Resolution::new(source, target).event(target.add_effect(skill, effect)).stages(EventStages::PostOnly));
|
||||
}
|
||||
|
||||
return results;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user