Update of bug #9462 (project wormux):
Status: Confirmed => Fixed
Open/Closed: Open => Closed
_______________________________________________________
Follow-up Comment #9:
Fixed in r2759
The bug is due to Character::PrepareShoot which does not call DoShoot in some
case (for managing skin ?!?).
The DoShoot call was delayed after the game state change.
Solution:
void Character::DoShoot()
{
+ if (GameLoop::GetInstance()->ReadState() != GameLoop::PLAYING)
+ return; // hack related to bugs 8656 and 9462
Trace without fix:
11610|include/action_handler.cpp:void ActionHandler::NewAction(Action*,
bool):630| action_handler : New action : WEAPON_shoot
11610|include/action_handler.cpp:void ActionHandler::Exec(Action*):662|
action_handler : -> (709825988) Executing action WEAPON_shoot
11610|weapon/weapon.cpp:void Weapon::PrepareShoot(double, double):258|
weapon.shoot : Try to shoot with strength:0,000000, angle:0,000000
11610|character/character.cpp:void Character::PrepareShoot():542|
weapon.shoot : -> begin
11610|character/character.cpp:void Character::PrepareShoot():553|
weapon.shoot : <- end
11610|weapon/weapon.cpp:void Weapon::PrepareShoot(double, double):264|
weapon.shoot : End of shoot
11610|include/action_handler.cpp:void ActionHandler::Exec(Action*):670|
action_handler : <- (709825988) Executing action WEAPON_shoot
o MSG: Connochaetes gnu est tombé dans l'eau.
11610|include/action_handler.cpp:void ActionHandler::NewAction(Action*,
bool):630| action_handler : New action : GAMELOOP_set_state
11610|include/action_handler.cpp:void ActionHandler::Exec(Action*):662|
action_handler : -> (214678170) Executing action GAMELOOP_set_state
11610|game/game_loop.cpp:void GameLoop::__SetState_END_TURN():524|
game.statechange : End of turn
11610|include/action_handler.cpp:void ActionHandler::Exec(Action*):670|
action_handler : <- (214678170) Executing action GAMELOOP_set_state
11610|character/character.cpp:void Character::DoShoot():563| weapon.shoot :
-> begin
11610|weapon/weapon.cpp:bool Weapon::Shoot():269| weapon.shoot : Enough ammo
? 1
11610|weapon/weapon.cpp:bool Weapon::Shoot():270| weapon.shoot : Enough ammo
unit ? 1
11610|weapon/weapon.cpp:bool Weapon::Shoot():271| weapon.shoot : Use unit on
1st shoot ? 1
11610|weapon/weapon.cpp:bool Weapon::Shoot():294| weapon.shoot : Enough ammo
11610|weapon/weapon.cpp:bool Weapon::Shoot():301| weapon.shoot : Connochaetes
gnu Shooting at position:2020,1380 (hand: 2043,1414)
11610|weapon/weapon.cpp:bool Weapon::Shoot():306| weapon.shoot : shoot!
11610|character/character.cpp:void Character::DoShoot():568| weapon.shoot :
<- end
11610|game/game_loop.cpp:bool GameLoop::IsAnythingMoving():615|
game.endofturn : Weapon Marteau piqueur is still active
11610|game/game_loop.cpp:bool GameLoop::IsAnythingMoving():615|
game.endofturn : Weapon Marteau piqueur is still active
_______________________________________________________
Reply to this item at:
<http://gna.org/bugs/?9462>
_______________________________________________
Message posté via/par Gna!
http://gna.org/
_______________________________________________
Wormux-gna mailing list
[email protected]
https://mail.gna.org/listinfo/wormux-gna