Page 1 of 1

How to use actors with same graphics?

PostPosted: Tue May 22, 2012 6:13 pm
by Lacotemale
I want to redo a game which I gave up on a while back and stupidly deleted all the code! :D

So I want to program it better this time. I had 5 individual actors but they all had the same graphics. I wonder can I just create this actor once and use clone. I need to be able to move individual cloned actors without moving all of them.

How can this be done? :)

Re: How to use actors with same graphics?

PostPosted: Tue May 22, 2012 6:20 pm
by skydereign
How were you moving the actors? Using clones and moving with the mouse, you could just have a mouse button down event with drag enabled.
clone_actor -> Mouse Button Down (drag enabled) -> Script Editor
Code: Select all
//

That would allow you to drag around the clone you clicked.

Re: How to use actors with same graphics?

PostPosted: Tue May 22, 2012 8:06 pm
by Lacotemale
I was using the move function in a script. Would that be ok?

Re: How to use actors with same graphics?

PostPosted: Tue May 22, 2012 8:16 pm
by skydereign
If you are unsure if it works, you can always try it out. And by move function do you mean MoveTo? As long as you specify "Event Actor" for the actor (or some other clone specific reference) and as long as the event is clone specific as well it is fine (a keydown event is not clone specific because all actors of that type receive it, while with a mouse event, only one actor is triggered by it).

Re: How to use actors with same graphics?

PostPosted: Tue May 22, 2012 8:35 pm
by Lacotemale
Yes I did mean moveTo, sorry its been a while since I did any GE stuff! :oops:

Yup I will be using the mouse event! :)

Thanks for the help! +1 for you! :wink: