What is the gml code of MOVE FIXED in the game maker?

0

I would like to know what the move fixed function is in gml ( game maker language ):

IfoundsomesimilarmovementswithwhichIcandosome"gambiarras" so that they act in the same way as move fixed , but if the fixed move exists in the "actions" certainly exists your code in gml .

    
asked by anonymous 26.02.2017 / 01:37

1 answer

0

Well the solution is actually quite simple.

When I asked the question I was wanting a randomization in the direction in which the object was (left / right) after colliding with another, this can be done with if.

if (condiction01 == true){

  //ir para a direita com a velocidade 10
  move_towards_point(object.x+1,y,10);
  //valores positivos adicionados a x, o levam para a direita na horizontal

}else{

  //ir para a esquerda com a velocidade 10
  move_towards_point(object.x-1,y,10);
  //valores negativos adicionados a x, o levam para a esquerda na horizontal
  
}

Remembering that even applying "selfie" requires this indication object.x (+ ou -) 10 and not only x (+ ou -) 1 to be relative to your position.

y is the opposite of conventional. With - goes up and + goes down.

Where does the image begin? I guess you have thought that in the upper left corner, that's it. The 0, 0 (x, y) point is in the upper left corner, so any value down or right increases its value.

    
22.03.2017 / 23:23