monicanagent/cypherpoker

Game - ActionScript: Full hand deal on game startup, crash

monicanagent opened this issue · 2 comments

A full hand is automatically dealt during which the game places 0 bets on players' behalves. At the end of the hand the game may crash with a runtime error.

This issue is not always reproducible and appears most commonly when running multiple instances on the same machine which suggests a startup-message/initialization sequencing problem.

This seems to be related to a 0 balance at startup. When testing with Ethereum where the balance already exists this issue is no longer reproducible.

The fun balance was being assigned when the "START GAME" button was clicked so that if another player was determined to be the initial dealer the "_gameParameters.funBalances" property wouldn't be set. This property is now being set in the "onLeaderFound" function.

Fixed with commit : 2d8df18