• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Door Trigger

Status
Not open for further replies.
Level 5
Joined
Jul 25, 2008
Messages
155
Hello :) I want to open a "Door trigger" which opens/removes a door after 5 minutes, could anyone give me some help how I write it?
 
Level 5
Joined
Jul 25, 2008
Messages
155
Oh I see, thanks for the quick reply :) Was in perfect timing, was just about to upload it to epicwar :p
 
Level 5
Joined
Jul 25, 2008
Messages
155
DoorOpen
Events
Time - Elapsed game time is (30.00 x 6.00) seconds
Conditions
Actions
Destructible - Remove Demonic Gate (Horizontal) 0131 <gen>

like this?
 
Level 5
Joined
Jul 25, 2008
Messages
155
yeah I know, i wrote that before but then you said something which i didnt understand :p but i hope it works now :] wrote it exactly like him
btw how do make that trigger thing? I can only copy the text, not a photo with the trigger
 
Level 5
Joined
Jul 25, 2008
Messages
155
Alrite thanks :)

  • Initizializing
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player - Add 1000 to Player 1 (Red) Current gold
      • Player - Add 1000 to Player 2 (Blue) Current gold
      • Player - Add 1000 to Player 3 (Teal) Current gold
      • Player - Add 1000 to Player 4 (Purple) Current gold
      • Player - Add 1000 to Player 5 (Yellow) Current gold
      • Player - Add 1000 to Player 6 (Orange) Current gold
      • Player - Add 1000 to Player 7 (Green) Current gold
      • Player - Add 1000 to Player 8 (Pink) Current gold
      • Player - Add 1000 to Player 9 (Gray) Current gold
      • Player - Add 1000 to Player 10 (Light Blue) Current gold
      • Player - Add 1000 to Player 11 (Dark Green) Current gold
      • Player - Add 1000 to Player 12 (Brown) Current gold
      • Game - Display to (All players) the text: The marine is stron...
      • Game - Display to (All players) the text: This is the beta of...
is this trigger good for a initiliziation?
 
Level 5
Joined
Jul 25, 2008
Messages
155
oh oki :] ill just try it then i guess
if you have time, could you show me how i make tips? i want to make 10 tips which pops up each 1 minute
 
Level 5
Joined
Jul 25, 2008
Messages
155
How ya mean prisonlove? :p
Btw servily it's in order yeah, like:
first minute comes this:
Tip 1: blabalblablablabla
second minute:
Tip 2: blablblablalbalblablalblablaaaaa
then after 10 minutes it resets
 
Level 6
Joined
Jul 26, 2004
Messages
210
well if it was me I would probably end up doing it like this:

  • tips
    • Events
      • Time - Elapsed game time is 60.00 seconds
    • Conditions
    • Actions
      • Game - Display to (All players) the text: Tip 1
      • Wait 60.00 game-time seconds
      • Game - Display to (All players) the text: Tip 2
      • Wait 60.00 game-time seconds
      • Trigger - Run (This trigger) (ignoring conditions)
Another way anyone?
 
Level 5
Joined
Jul 25, 2008
Messages
155
oh thats nice :) ill write it right away =) lucky theres nice ppl here, otherwise i wouldnt be able to make my map >_<
 
Level 5
Joined
Jul 25, 2008
Messages
155
oh yeah that saves some memory so i can add some more models, thx :) didnt know it was able to do that, i should do it for -kick command aswell
 
Level 5
Joined
Aug 27, 2007
Messages
138
Actually... Doing it the way PrisonLove suggested would leak, therefore costing memory. And models don't take memory, they take map size. As for tips, at the initialization, set up a string array variable to hold your tips, and every 60 seconds, display Tips[Random integer from 1 to max].

FYI, you posted this in the wrong section. This belongs in the Triggers & Scripts forum.
 
Level 6
Joined
Jul 26, 2004
Messages
210
Actually... Doing it the way PrisonLove suggested would leak, therefore costing memory. And models don't take memory, they take map size. As for tips, at the initialization, set up a string array variable to hold your tips, and every 60 seconds, display Tips[Random integer from 1 to max].

FYI, you posted this in the wrong section. This belongs in the Triggers & Scripts forum.

and also he wants the tips in a particular order, not random.
and as for prisonlove's trigger couldn't you just do it this way:

  • Start
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Player - Add 1000 to (Picked player) Current gold)
 
Level 17
Joined
May 6, 2008
Messages
1,598
Alrite thanks :)

  • Initizializing
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Player - Add 1000 to Player 1 (Red) Current gold
      • Player - Add 1000 to Player 2 (Blue) Current gold
      • Player - Add 1000 to Player 3 (Teal) Current gold
      • Player - Add 1000 to Player 4 (Purple) Current gold
      • Player - Add 1000 to Player 5 (Yellow) Current gold
      • Player - Add 1000 to Player 6 (Orange) Current gold
      • Player - Add 1000 to Player 7 (Green) Current gold
      • Player - Add 1000 to Player 8 (Pink) Current gold
      • Player - Add 1000 to Player 9 (Gray) Current gold
      • Player - Add 1000 to Player 10 (Light Blue) Current gold
      • Player - Add 1000 to Player 11 (Dark Green) Current gold
      • Player - Add 1000 to Player 12 (Brown) Current gold
      • Game - Display to (All players) the text: The marine is stron...
      • Game - Display to (All players) the text: This is the beta of...
is this trigger good for a initiliziation?
Yes.

Why would it be bad?
 
Level 5
Joined
Aug 27, 2007
Messages
138
If you want in a particular order, just make an integer that increases by one every time the trigger fires. Every 60 seconds of game, display tips and set i = i + 1. It's silly to hardcode everything. Set up a system. It'll save time.
 
Level 14
Joined
Jul 1, 2008
Messages
1,314
You can Pick all Players from 1 to 12 in a Player loop, search in GUI, so u can write those lines more easily.
Like This:
Pick every Player in All Players and do
Actions:
Add 1000 to Picked Players Gold

Greets
 
Level 6
Joined
Jul 26, 2004
Messages
210
If you want in a particular order, just make an integer that increases by one every time the trigger fires. Every 60 seconds of game, display tips and set i = i + 1. It's silly to hardcode everything. Set up a system. It'll save time.


Don't know if it saves time really, seeing as you still have to write out each hint to equal a variable, but it does make it more organized. I like it.
 
Level 7
Joined
Jul 20, 2008
Messages
377
It doesn't save time, it's just that you usually want to avoid hard-coding things when it's possible. This way, your code has a lot of flexibility and can be modified with ease.
 
Level 5
Joined
Aug 27, 2007
Messages
138
Being able to modify it more easily saves time. Maybe that doesn't apply so much here, but it does apply elsewhere. I'd go ahead and get used to creating systems if I was you. An example:

In my current project, I add slight stat bonuses to every spell cast, and so I use texttags to show the total damage of spells. I don't write it out for each one, but, instead I use CreateSpellDamageTextTag(), a function I've written. It may be another function call, but it saves me writing it out for every spell. And, let's say I want to change the angle/size/color of the text, and maybe add an exclamation point (or four!!!!). Instead of digging through the JASS in about 50 spells and replacing every one, I just modify that one function. Sounds like a time-saver to me.
 
Status
Not open for further replies.
Top