Hey all Pinky once again!
I have a scenario set up where I have units being dynamically created and then junkyard dogging around a portion of the map. In this section of the map there are two types of enemies:
Leaders & Followers.
Leaders strut around with a multitude of Followers trailing after them (if you have played L4D2, you know the Clown Infected? Like that.) This way you can't really fight a leader on his own as he will always have followers backing him up.
I can't for the life of me think of a way to do this. The Leaders and Followers belong to the same player, how would I get multiple dynamically created leaders to have followers following them? I mean I could center a location but the location would only detect the leftmost Leader...
Hope I explained my problem correctly, thanks guys.
None.
You could do it using two computer players. Center a location on the first leader, order all followers in said location to that location (towards the leader), give the leader in that location to the other computer player, repeat the process.
I don't know if this'll work for your map specifically, but it's a possible solution.
You could just change the conditions to check if the marine is still alive by centering it on a marine at anywhere and if there is no marine in location, then it is dead. If there is, then it just moved, but is still alive.
None.
Mmm that is rather ingenious but unfortunately uses up too many locations for the amount of things I will need for my map.
I have sort of thought up a "work-a-round" myself if there is no other method its slightly different to what I originally wanted but it might have to do unless anyone knows any other techniques. Basically when the Leader "sees" the player (walks into a location that is being constantly centered on the player) he stops and begins "screaming" (wav file + visual effect), players have X seconds to kill him before many Followers (who are just junkyard-dogging around) rush in for the kill.
Something probably people new already but I only just thought of today as well, for those of you who are interested:
I originally just had five locations spread around my battlefield, with units spawning on them and then junkyarding around. But then I thought of something much more location efficient and useful. I have multiple burrowed zerglings spread throughout the battlefield owned by a neutral player, then I have a location (the only location that i need) center on any zergling at ANYWHERE, then spawn units and give the zergling to another neutral player, and then continue to the next zergling, so on and so forth, repeat repeat.
The problem with this was that the spawns always started left to right, which was a bit predictable and allowed for easy camping, so then I decided to add RANDOMIZED switches, which pretty much gives the illusion that the spawns are happening anywhere everywhere, and stops the players from camping. All this for just one location to boot!
Anyway just thought I'd share that, though I'm sure someone probably thought of this years ago its new to me hahaha.
Also if anyone would have any more methods I could try out for my Leader-Follower concept that would be much appreciated!
None.
I've done this before, except, I used two different computer players. I'd say using two different computer players would be the simplest solution to this.
None.
Ok, but how exactly would you do it? One computer for the Leaders and one for the followerS?
None.
Yep, one computer for leaders, one for followers.
Me, I'd probably have a really big location around a leader. Any followers in that location would be ordered to the leader, and the leaders would Junk Yard Dog. This, of course, creates the potential problem of two leaders getting too close, with one of them "leeching" the other's followers away... Plus, it's probably not elegant (in any way, shape, or form). But it is simple. (Probably too simple.)
Course, recently I've only been doing SC maps for fun (usually while waiting for pages to load) -- I haven't really finished anything advanced. I have several maps that are just incomplete terrain, with plans and dialogue marked out by locations, but no triggers... Chances are, the solutions above are more elegant and efficient.
EDIT: With two players, if both the leaders and followers are the same unit, you need (using my method) multiple locations. For three players, you can get away with one. (Center the location on a leader, order the followers, give the leader, repeat... Then return all leaders to the original controlling player).
EDIT: If followers and leaders are different types of units, on the other hand, then you could do this with one player and multiple locations, or two players and one location.
Post has been edited 2 time(s), last time on Dec 12 2009, 3:12 am by DavidJCobb.
None.
Ultimo says:
Why not use two locations? It works well unless you are stressed for locations. Two computers is not efficient, unless you have several to spare. How many leaders are there going to be?
None.
around 10ish. with about 30ish followers
they spawn dynamically, both the leaders and followers.
None.
Well you are going to be using your two different computers so that you can order each computer to different locations without affecting the other. Take advantage of this, and then rig up some sort of system to allow Computer A to be followed by Computer B.
If you want to do this, you need to be able to center a location over each leader, and then order all the Computer B units to that location. To do this, you can cycle through your leaders by giving them to multiple players, or you can keep a burrowed unit underneath your leaders and then cycle through those burrowed units. Both tactics work, and the cycling with a burrowed unit would be best, imo.
To cycle through units and center locations over them, you need to make sure that the locations don't all center onto a single unit. To do this, you center a location over a leader owned by Computer A, and then give it to Computer B. Repeat this process until A has no leaders, and then give all the leaders owned by B back to A. Do all of this within a single trigger cycle. The alternative is to cycle through burrowed units underneath the leaders, say, a drone.
It would be far easier to just order groups of units altogether to certain locations (including leaders and followers), instead of ordering groups of units to leaders.
None.
It would be easier yes but that would require too many locations and their patterns would fast be predictible... also triggers would get messy and not produce intended effect and etc. etc.
I think for ease and for location and trigger efficiency I am just going to stick with the Leader doing a 'spell" where he calls all surrounding followers (who are junk yard dogging around) to his position. This spell will have a visual/audio cue and a buildup so the player has time to kill the leader before it draws the horde to it, yes I think that will suffice.
Thank you SEN!
None.