skip faceoff serverside
This commit is contained in:
parent
6c1c411092
commit
9fe9020ac9
@ -3,7 +3,6 @@
|
|||||||
|
|
||||||
_ntr_
|
_ntr_
|
||||||
* can't reset password without knowing password =\
|
* can't reset password without knowing password =\
|
||||||
* skip faceoff on server side
|
|
||||||
* change cooldowns to delay & recharge
|
* change cooldowns to delay & recharge
|
||||||
- delay is cooldown before skill can first be used
|
- delay is cooldown before skill can first be used
|
||||||
- recharge is cooldown after using skill
|
- recharge is cooldown after using skill
|
||||||
|
|||||||
@ -220,11 +220,6 @@ function registerEvents(store) {
|
|||||||
const player = v.players.find(p => p.id === account.id);
|
const player = v.players.find(p => p.id === account.id);
|
||||||
store.dispatch(actions.setPlayer(player));
|
store.dispatch(actions.setPlayer(player));
|
||||||
|
|
||||||
const skip = v.time_control === 'Practice' && v.phase === 'Lobby';
|
|
||||||
if (skip) {
|
|
||||||
ws.sendInstanceReady(v.id);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (v.phase === 'Finished') {
|
if (v.phase === 'Finished') {
|
||||||
ws.sendAccountInstances();
|
ws.sendAccountInstances();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -706,7 +706,10 @@ pub fn instance_practice(tx: &mut Transaction, account: &Account) -> Result<Inst
|
|||||||
|
|
||||||
instance.add_player(player.clone())?;
|
instance.add_player(player.clone())?;
|
||||||
instance.add_player(bot)?;
|
instance.add_player(bot)?;
|
||||||
|
|
||||||
instance.player_ready(bot_id)?;
|
instance.player_ready(bot_id)?;
|
||||||
|
// skip faceoff
|
||||||
|
instance.player_ready(player.id)?;
|
||||||
|
|
||||||
instance = instance_create(tx, instance)?;
|
instance = instance_create(tx, instance)?;
|
||||||
player_create(tx, player, instance.id, account)?;
|
player_create(tx, player, instance.id, account)?;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user