• 🏆 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!

[General] Third Party WE Editor Trigger Data as Custom Script

Status
Not open for further replies.
Level 23
Joined
Jul 26, 2008
Messages
1,317
Hey guys, I know this is not a simple question, but if anyone knows the answer it would really help.


Normal WE cannot open maps with third party editor trigger data (in GUI form), but I have found that they are able to open them if those GUI triggers have been converted to custom script--- So I was wondering, is this actually a feasible workaround to being able to open maps otherwise un-openable, or will that custom script which was previously third party editor GUI triggers not actually work (i.e so the map is openable, but the script won't work)
 
  • People created custom GUI functions in thrid party editors, which are not known to the default editor. So loading the custiom GUI does not work anymore.
  • Neverless, GUI always converts to JASS, so it does not matter for custom GUI, or default GUI.
  • Custom script = JASS
  • The default editor can handle JASS
  • So when a map has worked before with custom GUI, then the default editor will also work the same, when having the code in Custom Script / JASS
 
Level 23
Joined
Jul 26, 2008
Messages
1,317
  • People created custom GUI functions in thrid party editors, which are not known to the default editor. So loading the custiom GUI does not work anymore.
  • Neverless, GUI always converts to JASS, so it does not matter for custom GUI, or default GUI.
  • Custom script = JASS
  • The default editor can handle JASS
  • So when a map has worked before with custom GUI, then the default editor will also work the same, when having the code in Custom Script / JASS
Eh. That was one of the best explanations someone could ever write. Thanks Icemanbo!
 
Level 23
Joined
Jul 26, 2008
Messages
1,317
Hi Icemanbo! Sorry to double-post, but I just wanted to mention that when I was discussing converting custom GUI to custom script as a means to make maps openable in the standard WE with another user, he mentioned that it was not just that simple--- I would need to make sure those functions had their definitions somewhere in the map that is accessible to all triggers and scripts, preferably in the map header.

He then said in order to find those definitions, I would need to extract war3map.j from the map's MPQ archive and just find whatever function that is needed for the regular WE to save the map correctly and place them in the map header in trigger editor.

Since I am completely ignorant on this issue, I was just wondering if you thought what this guy said was correct. I ask because, many of the maps I intend to use this method on are so complex and convoluted, that if I was required to do the things this person mentioned (as opposed to simply converting custom GUI to custom script and expecting the map to work), then I should probably not even try since it would take too much time.
 
You're right, I haven't thought of everyhting. I have thought of "usual" custom GUI extensions, such like WEU/UMSWE used... they finaly still used normal JASS iirc.
In theory one could put effort into it and add completly new GUI functionality, not working with JASS-only syntax anymore. If that's the case, it might be not so easy to simply import it. The goal basically is to get the functionality, and ensure it becomes valid JASS, or vJASS, if it's not. At least if it should work with the standard editor.

Can you show a concrete example?
 
Level 23
Joined
Jul 26, 2008
Messages
1,317
Yup, here is a random custom GUI action that has been converted to custom script:

Code:
function Trig_Initialization_OtherSettingActions takes nothing returns nothing
    call StoreIntegerBJ(udg_INT_GC_GameDifficulty, "INT_GC_GameDifficulty", MDKSaveDir, udg_GC)
endfunction

//===========================================================================
function InitTrig_Initialization_OtherSetting takes nothing returns nothing
    set gg_trg_Initialization_OtherSetting = CreateTrigger()
#ifdef DEBUG
    call YDWESaveTriggerName(gg_trg_Initialization_OtherSetting, "Initialization OtherSetting")
#endif
    call TriggerAddAction(gg_trg_Initialization_OtherSetting, function Trig_Initialization_OtherSettingActions)
endfunction

The action itself seems to be something like "Not recommended to do this- Record: XXX, Name of Use: YYY, Genre Name: ZZZ, Save As: WWW
 
Last edited:
Status
Not open for further replies.
Top