Bug Issue: Actor Values are not inmmediately updated when the actor is created.


Pages: 1

LIBERADO

  • Expert Stencyler
  • *
September 22, 2015, 05:10:30 am
This bug is causing me problems in my games:



oripessach

  • Subscriber - Stencyl Studio
  • *
September 22, 2015, 08:08:47 am
Your actor's When Created event runs during the creation of the actor - meaning, it runs before the create actor block completes, and before your Set Actor Value block executes.

For your purposes, it's better to have the actor set its STATE value to READY in the When Created event. It's better encapsulation, and it ensures that every actor you create will be in the READY state, no matter where in your code you create it.


Jon

  • Chief Stencyler
  • *
September 22, 2015, 10:29:51 am
As oripessach says, this is working as intended. The "set actor state" doesn't happen until after the actor has been created, so I wouldn't expect the print statement to print out anything.

Order of execution is:

- actor creates in engine
- runs "when created" event
- then continues to next block

  • Status changed from New to Closed
  • Tags added: not-a-bug


LIBERADO

  • Expert Stencyler
  • *
September 22, 2015, 01:41:05 pm
Ok.


Pages: 1

Details

  • Reported
    September 22, 2015, 05:10:30 am
  • Updated
    September 22, 2015, 01:41:05 pm

  • View Status
    Public
  • Type
    Bug
  • Status
    Closed
  • Priority
    Normal
  • Version
    Stencyl 3.3
  • Fixed in
    (none)
  • Assigned to
    (none)
  • Category
    Compiling/Testing Games

Tags