• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

hashtable how to use handle id as a key?

Status
Not open for further replies.
Level 12
Joined
Nov 3, 2013
Messages
989
I've had some problem before with world editor & hashtable because it didn't work to use abilityID variables as keys (since they're just integers or whatever it was).


It's been a while since I even used the WE nevermind hashtables, but am I missing something or is my WE bugged somehow? I'm pretty sure "Get Handle ID" is supposed to allow me to use the regular functions e.g. using (Triggering Unit) as a primary key and then saving a bunch of stuff to the secondary key...

500904eb8c.png


fea699c7e4.png


c809a26a69.png


so to explain the pictures just in case:

picture 1: I clicked on the second "Value" meant to be used as the primary key.

picture 2: I clicked on "Handle" from "Get Handle ID" to later select my unit to use as the key in the next step.

picture 3: apparently it only show the "Variable" section...
And I ried the other ones as well, none of the Hasltable - Save (integer/unit/real/whatever) worked as far as I can tell...

Now I assume that I could still do it with jass, but that sort of beat the whole point here. I wasn't really going to do anything complex. I just wanted an easy to use 2d array...
 
Are you using JNGP are any other special editor?
I use JNGP and it is bugged for me as well. I don't care much, because I only use them in JASS. It's confusing to use hashtables in JASS and GUI at the same time, because the parameters are swapped.
You can use custom script before that:
set udg_Key = GetHandleId(GetTriggerUnit())
and then use your GUI hashtable action and use the integer Key as your key.
 
Are you using JNGP are any other special editor?
I use JNGP and it is bugged for me as well. I don't care much, because I only use them in JASS. It's confusing to use hashtables in JASS and GUI at the same time, because the parameters are swapped.
You can use custom script before that:
set udg_Key = GetHandleId(GetTriggerUnit())
and then use your GUI hashtable action and use the integer Key as your key.
ah clever workaround, and yeah I do use a special editor.
 
Status
Not open for further replies.
Back
Top