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

Buildings granting resources and problematic sheep.

Status
Not open for further replies.
Level 7
Joined
May 11, 2010
Messages
278
Hey! I'm making a map called "Dragon Wars". It's a battle between Red, Black and Undead Dragons. Also, there's humans.
Well, those humans only want to survive. They build Meat Cages for the dragons.
Now, those cages are supposed to give a set amount of Meat (Wood) to the player destroying them. And i have no idea how to do a such trigger.
The tricky part (imo :p) is that the trigger will have to work for Cages being built during the game.
If it can be solved by giving the dragons an ability to use against the Meat Cages that is approved aswell.

Also, i have replaced trees with sheep, as you're farming meat, not wood, heh.
I have made triggers for spawning sheep in a certain area, and that works well. Now, it gets problematic when the sheep dies. their bodies are littering the ground and after a while you only see bloddy sheep everywhere...
I tried to make a "cleanup-trigger" but it made the game crash :eek:
Is there a way to make the sheep-bodies (treestumps) disappear after a while?

I'd really appreiciate help!
 
  • Trigger
  • Events
    • Unit - A unit dies
  • Conditions
    • (Unit-type of (Triggering unit)) Equal to Meat Cage
    • ((Owner of (Killing unit)) controller) Equal to Player
  • Actions
    • Player - Add 30 to (Owner of (Killing unit))'s Current lumber
  • Trigger
  • Events
    • Unit - A unit dies
  • Conditions
    • (Unit-type of (Triggering unit)) Equal to Sheep
  • Actions
    • Unit - Remove (Triggering unit) from the game
 
Level 7
Joined
May 11, 2010
Messages
278
Thanx alot, but i don't think the second will work, as the sheep are actually modified trees?
When i tried to make a trigger like the second the game crashed :s
whatever, i'll try it, thanks, +rep :smile:
 
Level 6
Joined
Apr 29, 2007
Messages
140
Change the Event to Destructible Dies and make sure everything else matches. Use basically everything Pharaoh_ said, just make sure it's for a destructible and not a unit.

You can also make units give lumber bounty just like you can with gold I believe. I may be wrong though.
 
Oh, sorry. I know it crashes, that's why you need a wait of 0.00 seconds ;)
  • Trigger
  • Events
    • Map Initialization
  • Conditions
  • Actions
    • Destructible - Pick every destructible in (Playable map area) and do (Actions)
      • Loop - Actions
        • Trigger - Add to Teg <gen> the event (Destructible - (Picked destructible) dies)
  • Teg
  • Events
  • Conditions
  • Actions
    • Wait 0.00 seconds
    • Destructible - Remove (Dying Destructible)
There was another similar issue: http://www.hiveworkshop.com/forums/world-editor-help-zone-98/doodad-problem-181425/#post1739684
 
Level 12
Joined
Jan 30, 2009
Messages
1,067
after a while you only see bloddy sheep everywhere...
OT:
Okay, I couldn't resist. That's the best line I've seen in quite a while! Put a nice big grin on my face when I'm otherwise quite annoyed. Thanks!

Back on topic... was it fixed? No more gory sheep carcasses plastered all over the place? :O

PS: This makes me want to make a map with sheep trees and kill them all! >:D
 
Level 7
Joined
May 11, 2010
Messages
278
Actually i haven't had time to try it yet :p
i'm modding an older map right now (i want to have that done tomorrow) but i hope the trigger won't make the game crash like it did when i tried to make the trigger on my own :p
 
Status
Not open for further replies.
Top