Jass Help What does this mean?

worldofDeath

New Member
Reaction score
47
What does this mean and can i change it to something else to make it work.

function Implosion_EndDamageEvent takes nothing returns nothing
local string s =HS(tm)

local ImplosionDatas datas =GetStoredInteger(GC(),HS(t),"datas")

What are they and these two for some reason stop the trigger from working. Help Please +rep

And:
call StoreInteger(GC(),HS(missile),"gfx",H2I(AddSpecialEffectTarget(MissileGFX,missile,MissileAttach)))

What is HS? I have no clue why its in a string and in these other two triggers. Its all for the same spell.
 

Charapanga

New Member
Reaction score
46
Well, i see the problem is in line 5 of the trigger you posted

also, we have a JASS help forum too
 

Darthfett

Aerospace/Cybersecurity Software Engineer
Reaction score
615
I would recommend reading a few tutorials before just trying to instantly understand a script. Especially one that's using attachment systems, and gamecache.

HS is probably a function that returns I2S(H2I(HANDLE)), in other words, converting a handle into an integer, and then into a string.

The full script would help a lot more, since you're missing all the functions.

JASS:
function Implosion_EndDamageEvent takes nothing returns nothing
    local string s =HS(tm)
    local ImplosionDatas datas =GetStoredInteger(GC(),HS(t),"datas")
    call StoreInteger(GC(),HS(missile),"gfx",H2I(AddSpecialEffectTarget(Missile GFX,missile,MissileAttach)))
//assuming that this is there somewhere:
endfunction


Although you probably won't be able to understand, here's a breakdown of those 4 lines:

line 1: Declaring a function called "Implosion_EndDamageEvent, which doesn't take or return any arguments.

line 2: declare a local variable of type string, named s, and set it to the return value of the function HS, supplied with the tm argument.

line 3: local variable of type ImplosionDatas (a struct) named datas, which is then stored in the gamecache returned by function GC, stored under the "t" handle variable, with the key-string "datas".

line 4: creates a special effect attached to the missile "missile", the effect's model path is "Missile GFX" (probably a naming error, that space cannot be there), and it is attached to the 'missile's "MissileAttach" attachment point.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top