need help about rotate

mintmomegmintmomeg Member, PRO Posts: 261
edited November -1 in Working with GS (Mac)
I make game about actor2 falling then If I click on actor 2 and actor1 at the bottom will rotate to position of actor 2 and fire bullet to it but I cannot do please help

Comments

  • scitunesscitunes Member, Sous Chef Posts: 4,047
    Create game.Actor1X and game.actor1Y (real)

    In actor1 constrain these attributes to self.positionX and Y

    In bullet actor have a change velocity behavior. In the angle box: 0 to self

    In the spawner have a spawn actor behavior. In the angle box (set to scene) have the following:

    VectorToAngle(game.Actor1X-self.positionX, game.Actor1Y-self.positionY)
  • mintmomegmintmomeg Member, PRO Posts: 261
    thanks I got it
Sign In or Register to comment.