well basically my understnading of the flick() is that it makes a mob so to say change icon for how ever long the animation is but I want to make it so the icon of the mob stays there and the flick() icon overlays it. I had a look at the reference but there's only one explination on
flick(). anything will help
ID:156184
Dec 12 2010, 7:32 am
|
|
In response to Spunky_Girl
|
|
what i mean is flick lets you chage the icon of somthing, well i want it leave the old icon there and put a new icon on top of it. The reson is because i have that puff of smoke that clears and when it starts to clear there is nothing in the opening.
|
In response to Jamesy577
|
|
Did you ever set the icon of the clone being created? The flick() proc may only be used to display a different icon for the duration of the flick'd icon's animation. That's all it is used for.
|
In response to Spunky_Girl
|
|
He wants to know how to make a clone appear with a puff of smoke, but he wants the smoke to be overlayed over the clone when the clone is created.
The answer is: use an overlay, of course. Create a blank overlay called 'smoke' and flick the smoke state onto it. When you're done with it, you can just delete the overlay. |
In response to Warlord Fred
|
|
i can't understand what mean i made the Flick a Blank icon then try it then i did it with the puff of smoke icon and nothing changed
|
In response to Jamesy577
|
|
Create a blank /icon object. Add it to the clones overlay var. Flick the smoke state onto the object.
|
In response to Warlord Fred
|
|
umm i get the jist of it but not all of it so basically
verb Clone() var/mob/Clone/m=new/mob/Clone add by here >>> m.overlays+=Smoke m.overlays+=usr.overlays m.underlays+=usr.underlays m.overlays-=src.underlays m.Move(get_step(usr,usr.dir,)) but i am not sure how i would add the blank icon in. |
In response to Jamesy577
|
|
To initialize a blank icon object:
var/icon/I = icon()
To flick that icon object:
flick('smoke.dmi', I)
|
In response to Warlord Fred
|
|
well i get it now but sadly i didn't some very bad coding well i think it's bad because when u add the coding to make the flick work the way i wanted it to it made my player no icon this is what i got to make my player an icon is this wrong
mob icon = 'Player normal.dmi' is there a better way to do it to like fix the icon to the usr? |
In response to Warlord Fred
|
|
ithis what u meant
mob Clone New() flick('Clone.dmi',usr) flick('smoke.dmi', I) var icon I = icon() verb Clone() if(Chakra >= 10) var/mob/Clone/m=new/mob/Clone m.overlays+=usr.overlays m.underlays+=usr.underlays m.Move(get_step(usr,usr.dir,)) usr.HurtChakra(10) |
If I understand this correctly, you want to change the icon variable of the mob? And add something to the overlays of the mob? You've pretty much answered your own question...