From 225da72f92b9e0b5caded3e0b85de30633af55fb Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Mon, 15 Jan 2018 13:59:49 +0100 Subject: finished project 11 --- projects/11/Pong/Ball.vm | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'projects/11/Pong/Ball.vm') diff --git a/projects/11/Pong/Ball.vm b/projects/11/Pong/Ball.vm index b8154eb..9d7b984 100644 --- a/projects/11/Pong/Ball.vm +++ b/projects/11/Pong/Ball.vm @@ -86,11 +86,11 @@ return function Ball.setDestination 3 push argument 0 pop pointer 0 -push argument 0 +push argument 1 push this 0 sub pop this 2 -push argument 1 +push argument 2 push this 1 sub pop this 3 @@ -114,21 +114,21 @@ pop local 0 push local 2 pop local 1 push this 1 -push argument 1 +push argument 2 lt pop this 8 push this 0 -push argument 0 +push argument 1 lt pop this 9 goto setDestination.Endif0 label setDestination.Else0 push this 0 -push argument 0 +push argument 1 lt pop this 8 push this 1 -push argument 1 +push argument 2 lt pop this 9 label setDestination.Endif0 @@ -300,7 +300,7 @@ push this 3 push constant 10 call Math.divide 2 pop local 3 -push argument 0 +push argument 1 push constant 0 eq not @@ -313,14 +313,14 @@ push this 2 push constant 0 lt not -push argument 0 +push argument 1 push constant 1 eq and push this 2 push constant 0 lt -push argument 0 +push argument 1 push constant 1 neg eq -- cgit v1.2.3