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

Day passive skills

Status
Not open for further replies.
Level 5
Joined
Nov 4, 2011
Messages
64
I am created a spell called presence of the sun can u help me the trigger which is a day effected passive skill. which will gives agility bonus in day time in night time gives nothing.
i have done 3 abilities in object editor
1. Presence of the sun (Day time)
2. Presence of the sun (learning)
3. Presence of the sun (night time)
can u help me in this triggers. to change the spells in day & night. tell me what changes to do.
(NOte:pOTS_Hero is learning hero)

trigger 1:- learning

  • presence of the sun learning
    • Events
      • Unit - A unit Learns a skill
    • Conditions
      • (Learned Hero Skill) Equal to Presence of the sun [Learning]
    • Actions
      • Set POTS_HeRo = (Learning Hero)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (In-game time of day) Greater than or equal to 6.00
          • (In-game time of day) Less than 18.00
        • Then - Actions
          • Unit - Add Presence of the sun [Day time] to POTS_HeRo
          • Unit - Set level of Presence of the sun [Day time] for POTS_HeRo to (Level of Presence of the sun [Learning] for POTS_HeRo)
        • Else - Actions
          • Unit - Add Presence of the sun [Night Time] to POTS_HeRo
          • Unit - Set level of Presence of the sun [Night Time] for POTS_HeRo to (Level of Presence of the sun [Learning] for POTS_HeRo)
          • Unit - Remove Presence of the sun [Day time] from POTS_HeRo

trigger 2:- changing the spell day time:-


  • presence of the sun continue
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (In-game time of day) Greater than or equal to 6.00
          • (In-game time of day) Less than 18.00
        • Then - Actions
          • Unit - Remove Presence of the sun [Night Time] from POTS_HeRo
          • Unit - Add Presence of the sun [Day time] to POTS_HeRo
          • Unit - Set level of Presence of the sun [Day time] for POTS_HeRo to (Level of Presence of the sun [Learning] for POTS_HeRo)
        • Else - Actions
          • Do nothing
trigger 3:- Night time:-
  • presence of the sun night time
    • Events
      • Time - Every 2.00 seconds of game time
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (In-game time of day) Less than 6.00
          • (In-game time of day) Greater than or equal to 18.00
          • (In-game time of day) Greater than or equal to 0.00
        • Then - Actions
          • Unit - Remove Presence of the sun [Day time] from POTS_HeRo
          • Unit - Add Presence of the sun [Night Time] to POTS_HeRo
          • Unit - Set level of Presence of the sun [Night Time] for POTS_HeRo to (Level of Presence of the sun [Learning] for POTS_HeRo)
        • Else - Actions
          • Do nothing
 
Remove the Do nothing's, they Do Nothing, and so it's totally useless. And your spell isn't MUI. You also should disable the Day/Night triggers before the spell is learned.

And use the In-Game time of day becomes, as maker said.

For the MUI, you can look one of my very old spells (this one was used to work only at night) :

  • Arc dElune
    • Evénements
      • Unité - A unit Apprend une compétence
    • Conditions
      • (Learned Hero Skill) Egal à Arc d'Elune
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • Si - Conditions
          • (AdE_UGroup is empty) Egal à TRUE
        • Alors - Actions
          • Déclencheur - Turn on Arc dElune Jour <gen>
          • Déclencheur - Turn on Arc dElune Nuit <gen>
        • Sinon - Actions
      • Groupe unité - Add (Triggering unit) to AdE_UGroup
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • Si - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • (In-game time of day) Supérieur ou égal à 18.00
              • (In-game time of day) Inférieur à 6.00
        • Alors - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • Si - Conditions
              • (Level of Arc d'Elune for (Learning Hero)) Egal à 1
            • Alors - Actions
              • Unité - Add Arc d'Elune Bonus to (Triggering unit)
              • Joueur - Désactiver Arc d'Elune Bonus for (Triggering player)
            • Sinon - Actions
          • Unité - Set level of Objet bonus vitesse d'attaque Arc d'elune for (Triggering unit) to (Learned skill level)
          • Unité - Set level of Objet bonus aux dégâts Arc d'Elune for (Triggering unit) to (Learned skill level)
        • Sinon - Actions
  • Arc dElune Nuit
    • Evénements
      • Partie - The in-game time of day becomes Egal à 18.00
    • Conditions
    • Actions
      • Groupe unité - Pick every unit in AdE_UGroup and do (Actions)
        • Boucle - Actions
          • Unité - Add Arc d'Elune Bonus to (Picked unit)
          • Unité - Set level of Objet bonus aux dégâts Arc d'Elune for (Picked unit) to (Level of Arc d'Elune for (Picked unit))
          • Unité - Set level of Objet bonus vitesse d'attaque Arc d'elune for (Picked unit) to (Level of Arc d'Elune for (Picked unit))
  • Arc dElune Jour
    • Evénements
      • Partie - The in-game time of day becomes Egal à 6.00
    • Conditions
    • Actions
      • Groupe unité - Pick every unit in AdE_UGroup and do (Actions)
        • Boucle - Actions
          • Unité - Remove Arc d'Elune Bonus from (Picked unit)
 
Status
Not open for further replies.
Top