Tutorial of hacking robot
I want to present you a video with tutorial during early gameplay, allows player to learn how to use basic three widnows:
- Avalible Units - there is a list of robot units which we can link up to camera window or script AI window. Not all units in the level will be avalibe on this list.
- Camera View - shows what's going on around us or follows the linked robot unit from Avalible Units list.
- Script AI - this window allows us to send command to the linked robot by pressing "Execute" button. As you can se below on thie video, the player will learn 5 commands to executing thanks to this window:
- robot.back(); - robot turn back;
- robot.walk(5); - robot walks 5 steps forward
- robot.aim(12); - robot aims 12 degrees up
- robot.shoot(); - robot shoots once
- robot.action(); - robot does any action if posible e.g. press a button
The fourth window called Controler has 8 buttons. For each button player can save an AI script, also for each button player can define keyboard shortcut. In this kind of script (assigned for one of the buttons) we can use function isPressed("shortcut");. For example if we want robot to walk only when the button with shortcut "W" is pressed, we will create the script for this button:
key = "W"; robot.walkIf("isPressed(key)");
I will remind you that robot.walkIf("code"); means that robot walk while code is returning true. Another example with walkIf function:
max = 1000; robot.walkIf("robot.getX() < max");
It means that the robot will walk while its x-coordinate is smaller than 1000.
See more on a video below:
And at the end a video with passing the tutorial by one command and a teleport efect:
The command is:
robot.back().walk(5); robot.aim().shoot(); robot.aim(12).shoot(); robot.aim(-12).shoot(); robot.walk(6).action();