File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -843,13 +843,13 @@ export class ArimaaGame extends GameBase {
843843 // placement
844844 if ( this . hands !== undefined && this . hands [ this . currplayer - 1 ] . length > 0 ) {
845845 if ( from !== undefined ) {
846- this . board . set ( from , [ pc , owner ] ) ;
846+ this . board . set ( from , [ pc , this . currplayer ] ) ;
847847 this . results . push ( { type : "place" , what : pc , where : from } ) ;
848848 // update hand
849849 if ( ! this . variants . includes ( "free" ) ) {
850850 this . hands ! [ this . currplayer - 1 ] . splice ( this . hands ! [ this . currplayer - 1 ] . indexOf ( pc ) , 1 ) ;
851851 }
852- lastmove . push ( `${ owner === 1 ? pc : pc . toLowerCase ( ) } ${ from } ` ) ;
852+ lastmove . push ( `${ this . currplayer === 1 ? pc : pc . toLowerCase ( ) } ${ from } ` ) ;
853853 } else if ( i !== steps . length - 1 ) {
854854 throw new Error ( "Invalid placement detected in the middle of the move." ) ;
855855 }
You can’t perform that action at this time.
0 commit comments