Actor independence

JlmCJlmC Member Posts: 129
edited November -1 in Working with GS (Mac)
Hello,

This is my problem.

I set my actor(called BOX) everytime it gets destroyed get a random number. If the number is under 20, drop an object. However, every BOX in my screen drop the same object, i just want to drop a object only when A box is destroyed

thanks

Comments

  • JlmCJlmC Member Posts: 129
    basically

    game.drop = 0
    when box is desroyed generate a number between 0 to 100
    if number is below 20
    spawn an actor
  • spliketspliket Member Posts: 93
    you need to make the "drop" attribute an actor attribute, not a game attribute.

    self.drop=0
  • JlmCJlmC Member Posts: 129
    oh, thank you so much.

    im going to try it later :)
Sign In or Register to comment.