Skip to content

Commit

Permalink
Merge pull request #145 from mind-ar/fix-143
Browse files Browse the repository at this point in the history
Fix #143
  • Loading branch information
PalumboN authored Apr 3, 2024
2 parents f6cf36c + 7dfd747 commit a2a5a0e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/commands/extrasGame.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,8 @@ function invokeMethod(interpreter: Interpreter, visual: RuntimeObject, method: s
export function visualState(interpreter: Interpreter, visual: RuntimeObject): VisualState {
const image = invokeMethod(interpreter, visual, 'image')
const position = interpreter.send('position', visual)!
const roundedPosition = interpreter.send('round', position)!
const x = roundedPosition.get('x')!.innerNumber!
const y = roundedPosition.get('y')!.innerNumber!
const x = round(position.get('x')!.innerNumber!)
const y = round(position.get('y')!.innerNumber!)
const message = visual.get('message')?.innerString
return { image, position: { x, y }, message }
}
Expand Down

0 comments on commit a2a5a0e

Please sign in to comment.