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. We have recently started the 16th edition of the Mini Mapping Contest. The theme is mini RPG. Do check it out and have fun.
    Dismiss Notice
  4. Dismiss Notice
  5. The Highway to Hell has been laid open. Come along and participate in the 5th Special Effect Contest.
    Dismiss Notice
  6. 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] fixing a unit limit trigger

Discussion in 'Triggers & Scripts' started by foamy125, Sep 3, 2007.

  1. foamy125

    foamy125

    Joined:
    Aug 30, 2007
    Messages:
    18
    Resources:
    0
    Resources:
    0
    ok i'm makeing a builder map and i wanted to limit the building of towers and when i play the map the it seems to mix 2 of my builidings up with eachother the trigger is set up like this:
    minor tower limit
    • Trigger
      • Events
        • Time - Elapsed game time is 1.00 seconds
      • Conditions
      • Actions
        • Player - Limit training of human arcane magic tower to 15 for Player 1 (Red)
        • Player - Limit training of human arcane magic tower to 15 for Player 2 (Blue)
        • Player - Limit training of human arcane magic tower to 15 for Player 3 (Teal)
        • Player - Limit training of human arcane magic tower to 15 for Player 4 (Purple)
        • Player - Limit training of human arcane magic tower to 15 for Player 5 (Yellow)
        • Player - Limit training of human arcane magic tower to 15 for Player 6 (Orange)
        • Player - Limit training of human arcane magic tower to 15 for Player 7 (Green)
        • Player - Limit training of human arcane magic tower to 15 for Player 8 (Pink)

    and what happens in game is that it mixes these units up with my income building when there upgraded. but when i make 15 income buildings it dosnt also take them off the list. but it dose take the towers off the list plz help me
     
    Last edited by a moderator: Sep 4, 2007
  2. PurplePoot

    PurplePoot

    Joined:
    Dec 14, 2005
    Messages:
    11,161
    Resources:
    3
    Maps:
    1
    Spells:
    1
    Tutorials:
    1
    Resources:
    3
    If you mean that the restriction doesn't hold after upgrading, it's because it limits that specific unit type, and not that type + all subtypes.
     
  3. foamy125

    foamy125

    Joined:
    Aug 30, 2007
    Messages:
    18
    Resources:
    0
    Resources:
    0
    what i mean is that when my income is upgraded its included in the count for the trigger for example:
    if i have 5 towers and 10 upgrade income buildings it acts as if theres 15 towers
     
  4. Elton

    Elton

    Joined:
    Sep 4, 2007
    Messages:
    5
    Resources:
    0
    Resources:
    0
    Could they be based off the same tower?
     
  5. Bobo_The_Kodo

    Bobo_The_Kodo

    Joined:
    Jan 15, 2007
    Messages:
    192
    Resources:
    0
    Resources:
    0
    basing them from the tower would not cause this kind of problem it might happen if you upgrade the mage tower to the income tower or something
     
  6. Just_Spectating

    Just_Spectating

    Joined:
    May 16, 2007
    Messages:
    7,023
    Resources:
    46
    Models:
    11
    Icons:
    9
    Skins:
    26
    Resources:
    46
    use food to limit your income buildings.
     
  7. foamy125

    foamy125

    Joined:
    Aug 30, 2007
    Messages:
    18
    Resources:
    0
    Resources:
    0
    i do use food to limit them the problem is because its confuseing 2 completely different units as one and the same i only have the triggers to limit the towers and no trigger to limit income and i added a 3rd tier and the works correctly only when ur on the first and 3rd tiers.when ur at 2 it thinks that they are towers and takes the towers off the building list even if u havent built a single tower
     
  8. Just_Spectating

    Just_Spectating

    Joined:
    May 16, 2007
    Messages:
    7,023
    Resources:
    46
    Models:
    11
    Icons:
    9
    Skins:
    26
    Resources:
    46
    make the income building cost 1 food, and in the start give everyone 15 food to use.
     
  9. foamy125

    foamy125

    Joined:
    Aug 30, 2007
    Messages:
    18
    Resources:
    0
    Resources:
    0
    thats what i do, there is no trigger to limit the amount of income buildings in my map, only the towers, and now i have a tier 3 income building and the problem gose away after u get to it
     
  10. Just_Spectating

    Just_Spectating

    Joined:
    May 16, 2007
    Messages:
    7,023
    Resources:
    46
    Models:
    11
    Icons:
    9
    Skins:
    26
    Resources:
    46
    you cannot create more than 15 income buildings unless you get more food, and make it so you cant get more food. then you can only get 15 income buildings. you have to make the upgraded buildings cost food also.
     
  11. foamy125

    foamy125

    Joined:
    Aug 30, 2007
    Messages:
    18
    Resources:
    0
    Resources:
    0
    god dam it thats exactly the system i have. listen to me. I USE NO TRIGGERS TO LIMIT INCOME ONLY TOWERS. it was a problem that had somthing to do with a mistake in how i set up the unit but like i said before, now that i have a tier 3 it works only when ur on tier 1 and 3 but it still confuses them on 2
     
  12. Just_Spectating

    Just_Spectating

    Joined:
    May 16, 2007
    Messages:
    7,023
    Resources:
    46
    Models:
    11
    Icons:
    9
    Skins:
    26
    Resources:
    46
    what are you saying... that tier 2 doesnt work.. WHAT doesnt work? that it confuses them with WHAT??? you must explain a lil more PLEASE
     
  13. foamy125

    foamy125

    Joined:
    Aug 30, 2007
    Messages:
    18
    Resources:
    0
    Resources:
    0
    heres an example:
    i have 5 income buildings that are tier 2AND ARE NOT UPGRADED FROM TOWERS NOR ARE THE TOWERS UPGRADED TO THESE
    i have 10 towers
    it acts like theres 15 towers when theres only 10
    the units are not realated in any way to the income
     
  14. raft_pl

    raft_pl

    Joined:
    May 27, 2006
    Messages:
    496
    Resources:
    1
    Maps:
    1
    Resources:
    1
    W8... As far as i understanded, it goes:

    1. You have 10 towers, already placed on the map by you (not triggers) through WE. These towers MAY be upgraded to income buildigns.

    2. You have 5 income buildings, already placed on the map by you (not triggers) through WE. These buildings MAY be upgraded from towers, but are already placed. Like already-placed-on-map Arcane Tower, that can be upgraded from Watch Tower?

    If its correct, i see no way why it doesn`t work... Most probably you used wrong triggers to limit the units. You can use:

    • Limit
      • Events
        • Time - Every 1 second of game time.
      • Conditions
      • Actions
        • For each (Integer A) from 1 to 8 do actions:
          • Unit Group - Pick every unit of type TOWER owned by (Player(Player number(Integer A))) and do (Actions):
            • If, Then, Else - Multiple actions:
              • If - Conditions
                • If (Number of (Units of type TOWER)) owned by (Player(Player number(Integer A))) Equal to or greater than 15
              • Then - Actions
                • Player - Make TOWER unavaible to build/train/whatever by (Player(Player number(Integer A)))
              • Else - Actions
                • Player - Make TOWER avaible to build/train/whatever by (Player(Player number(Integer A)))