The robot fired the bullet has been completed, below to see how to set obstacles to the player.
As you can see from the previous diagram, there are a number of obstacles directly to the machine and the basket. Let's see how to implement them first.
Open Spritebuilder, create a new SMALLBRICK.CCB in the Sprites folder, type node.
Drag from the control library into a Ccnodecolor node, called a child node of its root node. Decorate the appearance as you like, and open physical objects at the same time, physical types are static:
Create a new levels folder in which to build the LEVEL.CCB file, type node. First drag a physical node into its root node.
Then drag the 2 robots to the left of the screen and say 2 robots each.
Place 2 obstructions in the center of the screen and drag the right end of the screen into a Basket node object. Note that these new objects are child nodes of the physical node. The screen layout looks like this:
The object hierarchy in timeline is as follows:
Not yet, to the basket, 2 robots set up a code connection: _basket,_robot1,_robot2 for access in code.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
(no.00003) iOS games simple robot projection game forming (11)