Touch Actor, Add Points?

mvsprojects

  • Posts: 71
I am trying to find out how to add a number of points to the score when your character touches another actor. This is an actor behavior, which affects the coin, the actor that the player is supposed to touch. Here's a screenshot.
Boing Ball coming soon...
Co-Opetative coming soon...

MV's Projects- Something to Enable

Hectate

  • *
  • Posts: 4643
Do the "kill self" last. Once you kill self (the actor running the behavior), the behavior stops processing so you never get to add points.

Personally, I would put this on the Player actor, and look for a collision with a special "Coins" collision group instead. You can still kill the coin from itself separately, but since the score is something that belongs to the Player (I imagine it should anyway), it's easier to modify from a behavior attached to the player.
:
:
Patience is a Virtue,
But Haste is my Life.
Proud member of the League of Idiotic Stencylers; doing things in Stencyl that probably shouldn't be done.

mvsprojects

  • Posts: 71
I have done so, but for some reason, it does not add the score. Since managing the score itself is a scene behavior, would this unaffect the score?
Boing Ball coming soon...
Co-Opetative coming soon...

MV's Projects- Something to Enable

decletro

  • Posts: 235
I would make 'score' a game attribute that you add 300 to. Then just have a scene behaviour that draws the score on the screen.

mvsprojects

  • Posts: 71
It's still a bit glitchy whenI do that, so I will see what I can do to make it happen.
Boing Ball coming soon...
Co-Opetative coming soon...

MV's Projects- Something to Enable