1. Find your way through the deepest dungeon in the 18th Mini Mapping Contest Poll.
    Dismiss Notice
  2. A brave new world lies beyond the seven seas. Join the 34th Modeling Contest today!
    Dismiss Notice
  3. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
Hive 3 Remoosed BETA - NOW LIVE. Go check it out at BETA Hive Workshop! Post your feedback in this new forum BETA Feedback.
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Spike Pit Trap

Discussion in 'Triggers & Scripts' started by fargs, Mar 20, 2007.

  1. fargs

    fargs

    Joined:
    Sep 15, 2005
    Messages:
    35
    Resources:
    0
    Resources:
    0
    Ok so here is the challenge:

    My current map is a survival type game and what i want to do is to have a trip wire type spell. The effects of teh spell are yet to be determined, like it could be an explosive or a stasis trap life effect. but the hard part will be creating the actuall trip wire "wire" in game. The spell would have the caster (just a random unit) would select two points on the terrain, (these would be the two endpoints of the "wire" then it would create the trip wire, idk if it would have a special effect or not, but the key would be if any unit were to walk through the line created between the two points, selected by the unit's ability, then the unit walking through would get stunned or damaged..... i am gona try to do it myself but i would love soem helping ideas, like creating the imaginary line between the two points.... and what not
    Well thanks for the help
     
  2. she_ep

    she_ep

    Joined:
    Mar 18, 2007
    Messages:
    51
    Resources:
    0
    Resources:
    0
    well IF you want
    you can make the line a region
    and the event could be
    Unit > Unit enters region TRIPWIRE > explode triggering unit
    or something like that.
    Im not that skilled in triggering myself
    but i have triggered all
    the maps ive made so if you
    want to use that go ahead
     
  3. fargs

    fargs

    Joined:
    Sep 15, 2005
    Messages:
    35
    Resources:
    0
    Resources:
    0
    There is a "line" type of region? do u know how i would go about creating it between the two points? i have a slight idea but i'd like to hear other peoples ideas... thanks
     
  4. paskovich

    paskovich

    Joined:
    Jul 12, 2005
    Messages:
    794
    Resources:
    2
    Tutorials:
    2
    Resources:
    2
    You can do this only with jass, and i don't think you really want to do it so... It's coordinate-geometrics and many math functions. It is hell complicated. I recommend you to forget it.
     
  5. she_ep

    she_ep

    Joined:
    Mar 18, 2007
    Messages:
    51
    Resources:
    0
    Resources:
    0
    I think i might have found a way without using JASS. You could always make a dummy unit that is long but skinny and the trigger would be

    Event> Unit comes within range of (THE UNIT)

    Action> Unit> Explode (triggering unit)
    Action> Special Effect> Create special effect at (position of unit(triggering unit)) (EFFECT)


    Im not sure if that is correct i dont have the editor up right now but maybe that would work
     
  6. fargs

    fargs

    Joined:
    Sep 15, 2005
    Messages:
    35
    Resources:
    0
    Resources:
    0
    that would work but thats basically teh same function as a land mine....
     
  7. she_ep

    she_ep

    Joined:
    Mar 18, 2007
    Messages:
    51
    Resources:
    0
    Resources:
    0
    Yea but you wouldnt be able to see it or you could try and find a model that looks like string and use that then it would look like a trip wire i guess... just throwin out suggestions.
     
  8. V_V_V

    V_V_V

    Joined:
    Sep 20, 2005
    Messages:
    72
    Resources:
    0
    Resources:
    0
    hmm how would a black tint color wall doodad with small scale look for a wire? perhaps a simple custom model of some rectangle? or ive seen ppl use lightning b4 quite flexible for this purpose, but it kinda looks too obvious to be used as a trap... well, im in the same boat, waiting for a better solution =/

    what would be your complex jass method be, paskovich? keep track of units in the region and compare xy to line function or something like that? (i really dont know how that would work) but that would be quite annoying....

    there must be a simpler way...........
     
  9. fargs

    fargs

    Joined:
    Sep 15, 2005
    Messages:
    35
    Resources:
    0
    Resources:
    0
    I could easily create a simple rope model, i model a bit.... so i don't think that cgetting the model for the thing is a problem.... is there a way to creatingn units like the rope model, in a line? like create 1 unit, then offeset the next by +4 x +4 y towards the other unit (the end of the trip wire)
     
  10. lex90

    lex90

    Joined:
    Feb 18, 2007
    Messages:
    33
    Resources:
    0
    Resources:
    0
    i got the ideea --- just make 2 dummys and give one a spell to canst on the other so that theres a permanent lightning between them (and schoose a lightning effect that has the least lightning looking like effect) and then just do a trigger where choose 10 points between the 2 units (add a range of 25around the point) and if a unit comes close just make another dummy cast a stun spell on him for example --- lkets see if this heps :D
     
  11. V_V_V

    V_V_V

    Joined:
    Sep 20, 2005
    Messages:
    72
    Resources:
    0
    Resources:
    0
    creating units in a line can be done by finding the angle between to locations and looping through to create a unit with polar offset at every interval.

    but then... what would u do with a line of units? detecting unit comes within range of rope unit? but then you would need some dynamic trigger with events you add on the fly...which would be quite annoying jass stuff...:confused:
     
  12. Dalaran_Guard

    Dalaran_Guard

    Joined:
    Sep 13, 2006
    Messages:
    429
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Using the idea of creating multiple units,you could use goblin land mine ability and, after the explosion/other animation, either bring back the old land mine unit or create a new one.
     
  13. fargs

    fargs

    Joined:
    Sep 15, 2005
    Messages:
    35
    Resources:
    0
    Resources:
    0
    Yeah, i actually am starting to agree with V_V_V here, this is gona be some tough triggering for the outcum. if anyone could make an example then awesome otherwise i might focus on other aspects of hte map...