1. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  2. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. The Lich King demands your service! We've reached the 19th edition of the Icon Contest. Come along and make some chilling servants for the one true king.
    Dismiss Notice
  4. The 4th SFX Contest has started. Be sure to participate and have a fun factor in it.
    Dismiss Notice
  5. The poll for the 21st Terraining Contest is LIVE. Be sure to check out the entries and vote for one.
    Dismiss Notice
  6. The results are out! Check them out.
    Dismiss Notice
  7. Don’t forget to sign up for the Hive Cup. There’s a 555 EUR prize pool. Sign up now!
    Dismiss Notice
  8. The Hive Workshop Cup contest results have been announced! See the maps that'll be featured in the Hive Workshop Cup tournament!
    Dismiss Notice
  9. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

[Solved] Acolyte corrupts trees

Discussion in 'World Editor Help Zone' started by LordPerenoldeII, Sep 10, 2019.

  1. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    I noticed that if you give Acolytes Harvest Gold and Lumber abiliy and you make them chop one they corrupt it into a permanent blighted one. Any way i can avoid this from happening, or take the tree back to its normal form at least?
     
  2. Warseeker

    Warseeker

    Joined:
    Feb 18, 2014
    Messages:
    2,590
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Just change the race of the Acolyte to Human for example.
     
  3. FeelsGoodMan

    FeelsGoodMan

    Joined:
    Dec 13, 2018
    Messages:
    649
    Resources:
    2
    Maps:
    2
    Resources:
    2
    I think you can also just change the destructible animation through triggers I believe.
     
  4. Warseeker

    Warseeker

    Joined:
    Feb 18, 2014
    Messages:
    2,590
    Resources:
    1
    Maps:
    1
    Resources:
    1
    The problem is that there is no easy way of detecting when a destructible is damaged/harvested.
     
  5. Linaze

    Linaze

    Joined:
    Feb 28, 2007
    Messages:
    2,991
    Resources:
    2
    Models:
    1
    Tutorials:
    1
    Resources:
    2
    Then the worker will also construct like a human worker would.
     
  6. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    Yep, and the reason for that unit to be "undead race" is specifically because i want it to warp buildings in the "undead" fashion. I just didn't expect this glitch to happen.
     
  7. FeelsGoodMan

    FeelsGoodMan

    Joined:
    Dec 13, 2018
    Messages:
    649
    Resources:
    2
    Maps:
    2
    Resources:
    2
    You can make a dummy unit that repairs the building and remove it when construction finishes. With some workarounds it should be possible.
     
  8. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    1,169
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    It isn't a glitch, that is a game mechanic... just like ghouls when harvesting trees they become blight.
    There is no way to turn the tree to normal afaik.
     
  9. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    The Ghoul's ability is Harvest Lumber(Ghoul), i didn't know this would happen even with the common Harvest Lumber and Gold ability.
     
  10. Warseeker

    Warseeker

    Joined:
    Feb 18, 2014
    Messages:
    2,590
    Resources:
    1
    Maps:
    1
    Resources:
    1
    You could manually edit the tree model by replacing the Replaceable ID 31 texture with a normal tree texture or import a non-blighted version of that tree and change its path to something like : ReplaceableTextures\LordaeronTree\LordearonSummerTreeBlight.blp
     
  11. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    i was also looking for the path to replace but couldn't find it so far. Is this the one?
     
  12. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    1,169
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    This is not about ghoul's ability, it is about the undead race. Just like if you move a peasant to undead race, it would have undead build style. Same thing with harvesting, trees will be blight with any undead race unit.
     
  13. Warseeker

    Warseeker

    Joined:
    Feb 18, 2014
    Messages:
    2,590
    Resources:
    1
    Maps:
    1
    Resources:
    1
    This only works for the Lordaeron Tree model, if you want to use a different one then check in ReplaceableTextures folder to find the path. example :

    ReplaceableTextures\AshenvaleTree\AshenTree.blp
    ReplaceableTextures\AshenvaleTree\AshenTreeBlight.blp
     
  14. FeelsGoodMan

    FeelsGoodMan

    Joined:
    Dec 13, 2018
    Messages:
    649
    Resources:
    2
    Maps:
    2
    Resources:
    2
    Maybe you can do something with this.

    • Build Dummy
      • Events
        • Unit - A unit Begins construction
      • Conditions
        • Or - Any (Conditions) are true
          • Conditions
            • (Unit-type of (Constructing structure)) Equal to Necropolis
            • (Unit-type of (Constructing structure)) Equal to Halls of the Dead
            • (Unit-type of (Constructing structure)) Equal to Black Citadel
            • (Unit-type of (Constructing structure)) Equal to Ziggurat
            • (Unit-type of (Constructing structure)) Equal to Spirit Tower
            • (Unit-type of (Constructing structure)) Equal to Nerubian Tower
            • (Unit-type of (Constructing structure)) Equal to Altar of Darkness
            • (Unit-type of (Constructing structure)) Equal to Crypt
            • (Unit-type of (Constructing structure)) Equal to Sacrificial Pit
            • (Unit-type of (Constructing structure)) Equal to Graveyard
            • (Unit-type of (Constructing structure)) Equal to Slaughterhouse
            • (Unit-type of (Constructing structure)) Equal to Temple of the Damned
            • (Unit-type of (Constructing structure)) Equal to Boneyard
            • (Unit-type of (Constructing structure)) Equal to Haunted Gold Mine
            • (Unit-type of (Constructing structure)) Equal to Tomb of Relics
      • Actions
        • Set ConstructingBuilding = (Constructing structure)
        • Set TempLoc = (Position of ConstructingBuilding)
        • Set TempGroup = (Units within 250.00 of TempLoc matching ((Unit-type of (Matching unit)) Equal to Acolyte))
        • Unit Group - Pick every unit in TempGroup and do (Actions)
          • Loop - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • ((Picked unit) is alive) Equal to True
              • Then - Actions
                • Unit - Remove Repair (Human) from (Picked unit)
              • Else - Actions
        • Unit - Create 1 RepairDummy for (Owner of (Triggering unit)) at TempLoc facing Default building facing degrees
        • Set ConstructionDummy = (Last created unit)
        • Custom script: call RemoveLocation (udg_TempLoc)
        • Countdown Timer - Start ConstructionTimer as a One-shot timer that will expire in 0.00 seconds


    • Construction Timer Expires
      • Events
        • Time - ConstructionTimer expires
      • Conditions
      • Actions
        • Unit - Order ConstructionDummy to Orc Peon - Repair ConstructingBuilding
        • Unit Group - Pick every unit in TempGroup and do (Actions)
          • Loop - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • ((Picked unit) is alive) Equal to True
              • Then - Actions
                • Unit - Add Repair (Human) to (Picked unit)
              • Else - Actions
        • Custom script: call DestroyGroup (udg_TempGroup)


    Just keep in mind that you have to remove the dummy somehow. I haven't thought of a smart way to do it because I don't know how to make stuff MUI.
     

    Attached Files:

    Last edited: Sep 10, 2019
  15. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    I'll do it. +rep for both of you in the mean time.
     
  16. Deserted

    Deserted

    Joined:
    Dec 31, 2017
    Messages:
    19
    Resources:
    0
    Resources:
    0
    If you are willing to keep blighted trees in the game, you can use something like this:
    • Town Hall
      • Events
        • Unit - A unit Begins construction
      • Conditions
        • (Unit-type of (Constructing structure)) Equal to Town Hall ++
      • Actions
        • Custom script: local real x
        • Custom script: local real y
        • Set Temp_Point = (Position of (Constructing structure))
        • Custom script: set x = GetLocationX (udg_Temp_Point)
        • Custom script: set y = GetLocationY (udg_Temp_Point)
        • Wait 0.00 seconds
        • Unit - Create 1 Dummy for (Owner of (Constructing structure)) at Temp_Point facing Default building facing degrees
        • Unit - Remove (Constructing structure) from the game
        • Unit - Add Build Town Hall (Dummy) to (Last created unit)
        • Custom script: call IssuePointOrderById (GetLastCreatedUnit(), 852619 , x, y)
        • Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
        • Custom script: call RemoveLocation(udg_Temp_Point)
    "Town Hall ++" is just a copy of "Town Hall" given to the worker instead.
    Build Town Hall is ability based on "Build Tiny..." ability.

    On the downside, it has lag that probably can't be dealt with (even if you relocate worker properly).
     
    Last edited: Sep 11, 2019
  17. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    mmmmhhhhh!! thanks but i'll use the path replacement. Seems more fit with what i want to do.
     
  18. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    I managed to make it work, but in game it displays the tree with black squares around its branches, like something has gone wrong. Any tips?

    EDIT: Sorry for double post.
     
  19. Warseeker

    Warseeker

    Joined:
    Feb 18, 2014
    Messages:
    2,590
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Maybe something is wrong with the path? I'm not really sure. What type of tree are trying to replace by the way?
     
  20. LordPerenoldeII

    LordPerenoldeII

    Joined:
    Nov 20, 2005
    Messages:
    869
    Resources:
    2
    Maps:
    2
    Resources:
    2
    The LordaeronSnowTree or something like that. I tracked down its path through Viewer, extracted it, jpg-ed it, tga-ed it, blp-ed it and reimported it in the editor with what seemed to be the blighted tree path in the viewer. The model displays correctly, but around its layers of leafs it's got black edged squares.