ID:261870
Nov 11 2003, 11:43 am
|
|
verb/Aura_on() set category = "Change" var/aura = 'ssjaura.dmi' icon_state = "ssjaura" usr.underlays += aura verb/Aura_off() set category = "Change" usr.underlays=0 it makes it so that it is an overlay and every time u change ur car it shuts off, can someone help me with this problem |
In response to Yota
|
|
verb/Aura_on()
set category = "Change" var/aura = 'ssjaura.dmi' icon_state = "ssjaura" src.underlays.Add(icon('ssjaura.dmi')) verb/Aura_off() set category = "Change" src.underlays.Cut() it gives me warning Carworld.dm:104:aura :warning: variable defined but not used where the var/aura = blah blah is plus it makes me turn into the aura then when i shut it off im invisible plz help what the heck? |
In response to Chibi_Gohan123
|
|
*sigh*
verb/Aura_on() set category = "Change" icon_state = "ssjaura" underlays.Add(icon('ssjaura.dmi')) verb/Aura_off() set category = "Change" icon_state = "normal" underlays.Cut() You forgot to remove the var/aura line. You also forgot to reset the icon_state for the mob then Aura_off() is called. Use that code up there changing "normal" to whatever your icon_state is before you turn the aura on. |
In response to Yota
|
|
alrity, it works now, but of course
i am an aura like before so im screwed with the underlays my code looks like: verb/Aura_on() set category = "Change" icon_state = "ssjaura" underlays.Add(icon('ssjaura.dmi')) verb/Aura_off() set category = "Change" icon_state = "normal" underlays.Cut() if you know how to fix the underlay problem please help cause i a noob coder so i kinda confused rite now |
In response to Chibi_Gohan123
|
|
You are an aura like before? You mean the aura doesn't go away?
|
In response to Yota
|
|
yes, exactly like before, i am an aura
when i click aura off it makes me invisible eheh |
In response to Chibi_Gohan123
|
|
Oy, you don't have an icon_state named "normal", remember when I said "Use that code up there changing "normal" to whatever your icon_state is before you turn the aura on."?
Change "normal" to the mob's normal icon_state. If it's fixed, (doesn't change other than "ssjaura") you mine as well use icon_state=initial(icon_state). |
Wha? I don't understand that. Every time you change your "car"? Overlay? You mean underlay?
Let me look at this.
"usr.underlays.Add(icon('ssjaura'))" will do.
I suggest you use src rather than usr. (Beat ya Lummox)
"usr.underlays=0"
Use "usr.underlays.Cut()".