- 
          
 - 
                Notifications
    
You must be signed in to change notification settings  - Fork 19
 
mp_linear_objects
        CryoEagle edited this page Feb 11, 2019 
        ·
        1 revision
      
    Returns false when colliding with specified objects while moving with object
mp_linear_objects(Xgoal, Ygoal, StepSize, obj)| Argument | Description | 
|---|---|
float Xgoal | 
Target X position to move | 
float Ygoal | 
Target Y position to move | 
int  StepSize | 
Pixels to move per call | 
Type[] obj  StepSize | 
Objects that is checked for collision | 
Returns: bool
This function will move with an object to a target position if an object will collide with a specified object, a function will return false.
if (mp_linear_objects(10,10,20,new []{typeof(oBrick), typeof(oGem)}) == false)
{
    show_message("hello world");
}Above code will move with an object to X: 10, Y:10, if there will be an object named oBrick or oGem in a way function, will return false.
Back to Motion Planning