• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

GetEquippedItemID(Player(), ) doesnt work any more

Status
Not open for further replies.
Level 5
Joined
May 25, 2009
Messages
103
Hi again.

I'm going on with my babysteps and managed to solve my last question on my own.

Now I face different functions that dont work any more in modern World Editors.
Like this essential one (for my map).
(f.e.: Set ItemID = (GetEquippedItemTypeId(Player(0),1))


How could I get that running again?
I think I'll have to script it into the header, like GetFloorHeight, etc.

Does someone know how to do it?
 
Level 5
Joined
May 25, 2009
Messages
103
Ah, it's been a long time...
sry for wasting your time guessing my intention.

This function originates from MUI Advanced Equipment System (+Save/Load +Event)
more precisely:

Code:
GetEquippedItemTypeId takes player p, integer class returns integer
  this function returns the rawcode of the item equipped in the given class
 
  Example:
    If GetEquippedItemTypeId(Player(0),1) == 'I005' then
      ...
    endif
    => only if the unit owned by Player 1 which has the Equipment, has a item of type 'I005'
        in slot 1, the if then else block releases his actions
        (useful for: if unit blaa has equipped sword xy then...)

My problem now is that The Witcher stated this system works only with JNGP - i'm searching now for the reasoning for this, cause perhaps he is wrong/there is a workaround.
I don't know, if you have ever used that system. I will ask at the right subforum, too.

And my real problem is that my map depends on that system...
 
Level 5
Joined
May 25, 2009
Messages
103
I found a new relating problematic function - the pure integer raw code!?

My test-trigger:
  • Test
    • Ereignisse
    • Bedingungen
    • Aktionen
      • Custom script: set IntegerItemID = (GetEquippedItemTypeId(Player(0),1))
      • Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • 'IF'-Bedingungen
          • IntegerItemID Gleich (==) ('I001')
        • 'THEN'-Aktionen
        • 'ELSE'-Aktionen
That worked once upon a time.
Now it doesnt produce an error while loading with WEX only if i delete the 'I001' (jass) in the integer comparison and set a normal number.
Are there any problems now with raw codes?
 
Level 22
Joined
Sep 24, 2005
Messages
4,821
Is there a message window showing you the error? Might help if you could tell us or post an image of the error you are encountering.
 
Level 13
Joined
Oct 18, 2013
Messages
690
Don't bother adapting your map to current bnet patch, lest you'll be spending more time fixing their fuckups than making your own map ;)
 
Level 13
Joined
Oct 18, 2013
Messages
690
I was going to update to newest patch but it froze at 88%, so much for getting to enjoy blizzard moving my maps into documents folder, JNPG not working, hiding buttons from command card being temporarily patched out, etc etc etc. :'*(
 
Level 13
Joined
Oct 18, 2013
Messages
690
not use bnet for no reason
Bnet was alive back when enthosting allowed you to play with people connected via Garena, but this is no longer the case. Memory Library can be made to run on current patch, it's just not worth the time (excluding the asain dev who is hellbent on currentpatch memory) Thus, people wanting to play the best crafted mods are pretty much stuck on 1.26a atm.
 
Status
Not open for further replies.
Top