| 03-27-2006, 11:52 PM | #1 |
Here is the code I'm having problems with: JASS://########################################################################### constant function cs_H2I takes handle h returns integer return h return 0 endfunction constant function cs_I2U takes integer i returns unit return i return null endfunction constant function cs_I2T takes integer i returns trigger return i return null endfunction constant function cs_I2TT takes integer i returns texttag return i return null endfunction constant function cs_I2It takes integer i returns item return i return null endfunction constant function cs_I2D takes integer i returns destructable return i return null endfunction constant function cs_I2FM takes integer i returns fogmodifier return i return null endfunction //########################################################################### function SetAggro takes handle mob, integer player, real aggro returns nothing call StoreReal(udg_cs_cache, I2S(cs_H2I(mob)), "aggro" + I2S(player), aggro) endfunction //=========================================================================== function InitTrig_CS_Main_Script takes nothing returns nothing set udg_cs_cache = InitGameCache("WOWDATA.w3v") endfunction |
| 03-28-2006, 12:03 AM | #2 |
player is not a valid variable name, since it's also a variable type. Use a different variable name, like p. |
| 03-28-2006, 01:43 AM | #3 |
It worked thanks. So why can't I use player as a variable name? |
| 03-28-2006, 02:23 AM | #4 |
Because it's also a variable type, as Anitarf said. Notice how it's highlighted light blue in the text you pasted above? |
| 03-28-2006, 11:55 AM | #5 |
Should give the error "Handle Reserved for blah" Use PID |
| 03-28-2006, 05:58 PM | #6 |
actually it didn't |
