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.

Trigger- Replacing Model, without replacing stats

Discussion in 'Map Development' started by NoobMag, Jul 15, 2006.

  1. NoobMag

    NoobMag

    Joined:
    May 6, 2006
    Messages:
    44
    Resources:
    0
    Resources:
    0
    I need a trigger that replaces a units model, but not the skills, and go back and forth, any possible way?
    or do i need to make a "hidden" unit with the same base stats and as the hero levels, so will the hidden unit, and just replace them? please help, thank you.
     
  2. Teh_Ephy

    Teh_Ephy

    Joined:
    Jun 26, 2006
    Messages:
    3,042
    Resources:
    0
    Resources:
    0
    *dies laughing, comes back to laugh some more* :lol:
    use bear form or something and give both forms the same abils. if you've checked the gameplay constants you would have tried that
    *repeats above cycle of dying and coming back to laugh some more* :lol:
     
  3. NoobMag

    NoobMag

    Joined:
    May 6, 2006
    Messages:
    44
    Resources:
    0
    Resources:
    0
    *laughs harder*
    the last to laugh laughs better

    don't you think i know that?

    cant you read? i need a TRIGGER, NOT SKILL

    lets say player 1 types message "transform" then he gets a new model replacing the hero he is using.

    btw the units i want to transform are heroes, so the stats constantly will be changing, since its at a fast leveling map.
     
  4. Teh_Ephy

    Teh_Ephy

    Joined:
    Jun 26, 2006
    Messages:
    3,042
    Resources:
    0
    Resources:
    0
    ah. maybe replace the unit with something w/ same stats but different model. all i can think of
     
  5. NoobMag

    NoobMag

    Joined:
    May 6, 2006
    Messages:
    44
    Resources:
    0
    Resources:
    0
    yes, but will he keep the old units level, strenght, agility, and intellegence? thats what im looking for
     
  6. Modeler

    Modeler

    Joined:
    Aug 27, 2004
    Messages:
    496
    Resources:
    0
    Resources:
    0
    It is impossible to swap models with a trigger. The closest you can get is use triggers to get the old units stats, and then use triggers to set the new ones stats.

    Natives to get the old stats.
    ----------
    native GetHeroAgi takes unit whichHero, boolean includeBonuses returns integer

    native GetHeroInt takes unit whichHero, boolean includeBonuses returns integer

    native GetHeroStr takes unit whichHero, boolean includeBonuses returns integer

    native GetHeroXP takes unit whichHero returns integer
    ----------

    Use thoes on the hero in question, put each of them into an integer. It is exactly the same to set the stats, except replace get with set. (Set also takes an integer argument)

    If you're not into jass dont worry, thoes are in the gui editor under the hero section.
     
  7. Ramza

    Ramza

    Joined:
    Jan 10, 2005
    Messages:
    3,194
    Resources:
    3
    Models:
    1
    Maps:
    2
    Resources:
    3
    save the stats (real) level (real) as vars and set the replaced units stats and lvl to the vars. or just use metamorfosion
     
  8. NoobMag

    NoobMag

    Joined:
    May 6, 2006
    Messages:
    44
    Resources:
    0
    Resources:
    0
    ok guys, thx for the help, i think ill try the metamorph or bear form thingy, since its easier than all those variables, one thing, anyone know how to erase that bar that covers the heroes lvl saying " Metamorphosis " or will i have to be perm metamorphosis ( but then with perm i cant go back...or can i? )

    ill try out metamorphosis, if it works out, ill stay with it, or ill try the variable thingys...sound complicated to me..

    maybe later on, when the map is more finished, ill take the time to learn how to use those triggers
     
  9. Alvatar

    Alvatar

    Joined:
    Apr 4, 2005
    Messages:
    299
    Resources:
    0
    Resources:
    0
    you can turn it off I think or make another metamorphosis with vice versa morphers and give it to morphed one
     
  10. Ramza

    Ramza

    Joined:
    Jan 10, 2005
    Messages:
    3,194
    Resources:
    3
    Models:
    1
    Maps:
    2
    Resources:
    3
    change that metamorphosion thing under the unit name by changing the buff

    in advanced => gameplay constants, u can choose if u want to be able to turn metamorphosion off