How can I set a variable to equal an object that is between the AI and its target?
Selecting an object as a variable
Started by The Legend, Apr 24 2012 08:29 PM
4 replies to this topic
#1
Posted 24 April 2012 - 08:29 PM
#2
Posted 24 April 2012 - 08:53 PM
variable = foundObject;
Edited by thegame, 24 April 2012 - 08:54 PM.
#3
Posted 24 April 2012 - 09:16 PM
Can you elaborate?
#4
Posted 24 April 2012 - 09:20 PM
foundObject = collision_line(); //You fill it it, as I know nothing of your objectsThen, if you need to set something to this object that is now in foundObject, set it like a normal variable.
Collision line returns the id of the object that it finds. You can then store the id in a variable and use the object like foundObject.x = 5;
#5
Posted 24 April 2012 - 11:08 PM
Thanks.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users











