Change actor's name?
mhedges
Raised on VCSMember Posts: 634
Hello -
Let's say I have an actor named "Actor 1". If I touch/select the actor, can the actor be temporarily renamed "Actor A" until a particular event occurs? The event would lead to a(nother) change in attributes or its destruction.
Thanks, regards.
Comments
Hi @mhedges You can't change an actor's name anytime during runtime but a straightforward solution for you is to simply use a boolean as a switch or trigger, so-called ... it can start out at the default false, and when you want a particular event to occur, use a Change Attribute behaviour to change the attribute to true. Providing you've already got somewhere:
It'll all work as required.
""You are in a maze of twisty passages, all alike." - Zork temp domain http://spidergriffin.wix.com/alphaghostapps
Thanks for the response, gyroscope.
What I was thinking of doing was writing one event handler for "Actor A" and "Actor B" (temporary names) so any of a number of actors could use it, then revert them back to their original names (but with some new attributes) or destroy them outright. What I want is the event handler to be reusable.
Or am I taking the wrong approach?
My Blog / App Store / Google Play
I think you're trying to cut corners, to be fair (OK, you're taking the wrong approach!)
You'll need a different "event handler" (in this instance, a boolean acting as a switch) for each and every Actor you want independent of the others... I mean to say, if you just use one boolean and ActorA, ActorB and ActorC all react to this single boolean change, that's fine, if that's what you're after...
but if you want each actor to react individually, then you'll need a boolean for each.
""You are in a maze of twisty passages, all alike." - Zork temp domain http://spidergriffin.wix.com/alphaghostapps
Thanks again! Regards.
My Blog / App Store / Google Play