1. Join other hivers in a friendly concept-art contest. The contestants have to create a genie coming out of its container. We wish you the best of luck!
    Dismiss Notice
  2. The Melee Mapping Contest #4: 2v2 - Results are out! Step by to congratulate the winners!
    Dismiss Notice
  3. We're hosting the 15th Mini-Mapping Contest with YouTuber Abelhawk! The contestants are to create a custom map that uses the hidden content within Warcraft 3 or is inspired by any of the many secrets within the game.
    Dismiss Notice
  4. The 20th iteration of the Terraining Contest is upon us! Join and create exquisite Water Structures for it.
    Dismiss Notice
  5. Check out the Staff job openings thread.
    Dismiss Notice

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

Discussion in 'World Editor Help Zone' started by tulee, May 8, 2019.

  1. tulee

    tulee

    Joined:
    Jul 26, 2008
    Messages:
    699
    Resources:
    5
    Maps:
    5
    Resources:
    5
    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)
     
  2. IcemanBo

    IcemanBo

    Joined:
    Sep 6, 2013
    Messages:
    6,104
    Resources:
    22
    Maps:
    3
    Spells:
    11
    Template:
    1
    Tutorials:
    4
    JASS:
    3
    Resources:
    22
    • 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
     
  3. tulee

    tulee

    Joined:
    Jul 26, 2008
    Messages:
    699
    Resources:
    5
    Maps:
    5
    Resources:
    5
    Eh. That was one of the best explanations someone could ever write. Thanks Icemanbo!
     
  4. tulee

    tulee

    Joined:
    Jul 26, 2008
    Messages:
    699
    Resources:
    5
    Maps:
    5
    Resources:
    5
    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.
     
  5. IcemanBo

    IcemanBo

    Joined:
    Sep 6, 2013
    Messages:
    6,104
    Resources:
    22
    Maps:
    3
    Spells:
    11
    Template:
    1
    Tutorials:
    4
    JASS:
    3
    Resources:
    22
    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?
     
  6. tulee

    tulee

    Joined:
    Jul 26, 2008
    Messages:
    699
    Resources:
    5
    Maps:
    5
    Resources:
    5
    Yup, here is a random custom GUI action that has been converted to custom script:

    Code (Text):


    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: May 10, 2019
  7. IcemanBo

    IcemanBo

    Joined:
    Sep 6, 2013
    Messages:
    6,104
    Resources:
    22
    Maps:
    3
    Spells:
    11
    Template:
    1
    Tutorials:
    4
    JASS:
    3
    Resources:
    22