Staredit Network

Staredit Network -> UMS Assistance -> HP bar
Report, edit, etc...Posted by M_s4 on 2005-12-25 at 01:24:01
I designed a sort of "HP bar" system that can be used by placing a 1x50 (or whatever many points you want) peice of land, and placing mineral chunks to each tile and destroy them as you lose HP. In game on the minimap, it looks like an HP bar like in games. It seems pretty obvious but I kinda figured out how to make up to like 200 "hps" by only using 3 locations rather than 200.

First theres a line going down 1x50, of ground surrounded by water. Then there's location 1 which is 1x1, on the first mineral chunk (hp). Then there are location 2 and location 3 which are both 1x3 locations both stacked on top of each other with both of their "center tile" directly on location 1. (Yes, the top tile of the three tiles will be on top of water.) Now we can easily use a death counter to be the "to be damaged onto life bar" which has points added to it whenever damage is "inflicted" onto your character. That's pretty self explanatory. Now for the actual hard part.

When damage is first inflicted, (first point added to ToBeDamaged death counter). The mineral chunk at location 1 is destroyed. This is the only time you will use location 1, so you can get rid of that. Also, a switch (or Death Counter) is set (or added), regarding that first damage has been done for.

--Trigger--
Conditions:
-"First Damage" Switch is cleared
-Player 8 suffers at least 1 death of Kakaru*
Actions:
-Kill one Mineral Chunk at Location 1
-Set "First Damage" Switch
-Subtract one death from Player 8 for Kakaru**

*Using Kakaru (the bird critter, I think that is what it is called)
**If you are smart you would assume to remove one ToBeDamaged per life bar down.

Now we get down to the part where the triggers actually repeat themselves.

If you have done this right, you now see that both locations 2 and 3 have one mineral chunk in their vincinity (under the bottom tile).

The next idea is that there is a "tracker" and "killer". The If "Tracking Location" detects only 1 mineral chunk in it's vincinity, that means, a mineral chunk has recently been killed and it will interpret that to move down the life bar, and tell "Killing Location" to prepare to kill the next mineral when the ToBeDamaged counter has one or more deaths.

The triggeri of this is the following:

First, when location 2 detects only 1 mineral in it, it moves down one by center location of mineral in location 3.

--Trigger--
Conditions:
-"First Damage" Switch is set
-Player Neutral (or whichever player that the mins belong to) brings exactly 1 mineral chunk to Location 2.
Actions:
-Center location 2 on Mineral Chunk at Location 3.
-Preserve Trigger

The situation now, is that location 2 has two mineral chunks in its vincinity (all tiles but its top one) and location 3 has one mineral chunk in its vincinity (the tile at its bottom). So this leaves us the next trigger who's idea is the identify the mineral chunk meant to be killed by the means of giving it to a different player, then catching up with location 2.

--Trigger--
Conditions:
-Player Neutral (or whichever player that the mins belong to) brings exactly 2 mineral chunks to location 2.
-Player Neutral (or whichever player that the mins belong to) brings exactly 1 mineral chunk to location 3.
-Player 8 has suffered at least 1 death of Kakaru
Actions:
-Give all mineral chunks at location 3 to player 7 (or some other player that is not the player that the mineral chunks originally belonged to).***
-Center Location 3 on Mineral Chunk at Location 3.****
-Kill all Mineral Chunks at Location 3 for player 7 (or the player you specified).
-Preserve Trigger

***As you could realize, if player 7 (or whatever) is a different color player than neutral (or whatever), you could have it to have an effect on the minimap, where a life point instantly turns a different color before dying. If you don't want this effect, just make player 7 (or whatever) the same color as neutral (or whatever).
****As I don't have SC on this computer, I'm not so sure if you are allowed to center a location on a unit that's in the same specified location. I'm pretty sure you can, but if you can't, the entire system is flawed and will not work. (I PRAY THAT DOES NOT HAPPEN ermm.gif ).

There you have it, my system. However, the reason I planned to put this "map making assisstance" rather than "concepts" is the fact that I am in too much of a headache to think hard some more and I have decided if any of you can help, it would be much appreciated.


######My question is: Is there anyway to trigger it so, you can like heal HP, and still have inflictions of damage properly put later?######


My thoughts on this is that if you tried it by simply by centering both locations on the last unit created, it would be very crude, and probably won't work, only work half the time, or hopefully work all the time. Also, when you mix in the fact that if someone buys max HP, you have to reinstall location 1 and the "First Damage" switch, which would be kind of hard to do.


Edit:Whoops, I posted this without finishing my post! Fwop_, you haven't read all I said, and probably don't get what I'm rying to say.
Report, edit, etc...Posted by Fwop_ on 2005-12-25 at 01:27:54
You shouldn't kill the mineral chunks because those arent creatable by triggers, therefore irreplacable.
Report, edit, etc...Posted by M_s4 on 2005-12-25 at 01:59:42
OMG, mineral chunks can't be replaced! I forgot about that, ah well, we could replace that marines instead, but it won't look nearly as nice...

OMG!! How am I going to replace marines neatly without using up 200 locations!! ranting.gif

Please help, if you think you know a solution to this.
Report, edit, etc...Posted by Fwop_ on 2005-12-25 at 03:07:30
You could replace mineral chunk with normal power-ups like uraj crystal or something or just not kill the mineral chunk, like give to different player (as your said). This system should work, it just might take lots of testing. I'll see if I can make a map similar to what your trying to say.
Report, edit, etc...Posted by Kumano on 2005-12-25 at 05:32:40
Or instead of removing/creating mineral chunks you could just move them to a corner of the map you don't see.

I'm not sure why this has been made so complicated to remove it though, since you could just remove X at anywhere, and it will still go left-right or down-up.

For moving them back, You could center a location on one of the chunks, and make sure the 'First Damage' switch is set (this is not really necessary if you're moving them, since it wouldn't do an unplaceable message since it's moving). Then you could use a mobile grid to move it to the left or down, and then move a chunk from the corner to the location.
Report, edit, etc...Posted by Urmom(U) on 2005-12-25 at 09:08:14
I did this in a Halo map that I was going to make. The health used to regenerate but it got screwed up for some reason thats unknown. I have to ask DeathKnight on that one.

I hope it's this one.[attachmentid=16334]
Report, edit, etc...Posted by Snipe)r( on 2005-12-25 at 10:17:17
what does this have to do with Map Making assistance?

Edit: Oh i didnt read the bottom of ur post... also i like that system u have
Report, edit, etc...Posted by M_s4 on 2005-12-25 at 11:56:57
OMG, Kumano, does it really just go left-right or up-down??? I thought it was random! That's why I thought this entire system up!! If that is true than totally screw this, I'm just making one big location!
Report, edit, etc...Posted by Oo.Insane.oO on 2005-12-25 at 12:17:14
If you were to move the mineral chunks instead of killing them it would have the same effect and it would use the same units and work
Report, edit, etc...Posted by M_s4 on 2005-12-25 at 12:23:07
I don't understand what you are saying insane, considering that my system is based on 3 locations, I don't get it. But anyways, if Kumano is right about that left-right and up-down theory, I'm forgetting all this (which kinda makes me mad, because I spent a lot of time thinking about this).
Report, edit, etc...Posted by Oo.Insane.oO on 2005-12-25 at 12:30:59
QUOTE(M_s4 @ Dec 25 2005, 12:23 PM)
I don't understand what you are saying insane, considering that my system is based on 3 locations, I don't get it. But anyways, if Kumano is right about that left-right and up-down theory, I'm forgetting all this (which kinda makes me mad, because I spent a lot of time thinking about this).
[right][snapback]389324[/snapback][/right]


Just make like a 6x6 square of terrain with a location stretched over it in the corner and have the mineral chunks move over there and move back its not too hard to do really just hard to not glitch
Report, edit, etc...Posted by KABOOM on 2005-12-25 at 12:34:44
lol well by knowing the left to right and up to bottom is how the grid systems work
Report, edit, etc...Posted by M_s4 on 2005-12-25 at 12:35:28
Yes, the fact is, that if random points starting popping out of a life bar, that would look kind of stupid, wouldn't it? It would be preffered that the life bar HP goes down like in a "real" life bar starting from top to bottom. I thought I needed some complicated trigger system, so I built one. Little did I know that it goes up-down or left-right if I make just ONE STUPID LOCATION. Well, I didn't have SC on hand at the time, so I really didn't know that didn't work.
Report, edit, etc...Posted by LurkerEgg on 2005-12-25 at 14:18:21
Use 2 players and Dark Templar. Place them all originally for a player with shared vision, then convert one at a time to one without.
Report, edit, etc...Posted by Kumano on 2005-12-25 at 14:36:06
Oh, it's down-up not up-down, but make sure if you are doing down-up that they are all EXACTLY on the same coordinate for left-right, or it will do the ones farthest to left first.

The problem with just 1 big location, is that you still need a way to make sure it places the things again in the right place. It will always try to put it in the middle of the big location, and go around the middle then. Then it will also not even go around the entire thing, but only around 10 tiles around the middle (I have no clue if it's even near 10, but I know there is some limit). I would still recommend using the mobile grid thing I said earlier to restore health.
Report, edit, etc...Posted by Fwop_ on 2005-12-25 at 15:31:47
Wouldn't making the area 50x1 rather than 1x50 be easier? Because I have noticed that it changes from down-up and up-down, but will always be left to right.
Report, edit, etc...Posted by LurkerEgg on 2005-12-25 at 15:48:21
QUOTE(Fwop_ @ Dec 25 2005, 03:31 PM)
Wouldn't making the area 50x1 rather than 1x50 be easier? Because I have noticed that it changes from down-up and up-down, but will always be left to right.
[right][snapback]389443[/snapback][/right]


SC goes left-right then up-down. So it would remove in this order in a square:

147
258
369
Report, edit, etc...Posted by Subrosian on 2005-12-25 at 16:33:15
The "move location" trigger moves to the last unit created, for all units of the same left-right coordinate. That's why the order of location moving goes from up-down and down-up.
Report, edit, etc...Posted by Fwop_ on 2005-12-25 at 16:35:08
It varies from units. Mutas for example are like this:

347
268
159

But it also changes from the position on the map (I think)

And what I meant about the up-down left-right I mean that all the units on the left will first be removed before it it moves over right.
Report, edit, etc...Posted by LurkerEgg on 2005-12-25 at 16:44:22
QUOTE(Fwop_ @ Dec 25 2005, 04:35 PM)
It varies from units.  Mutas for example are like this:

347
268
159
[right][snapback]389483[/snapback][/right]


The Muta lines weren't vertical, then. I assure you, it's left-right and top-bottom.
Report, edit, etc...Posted by Subrosian on 2005-12-25 at 17:01:01
it is NOT TOP-BOTTOM. The location moves to the last unit created in the left-right coordinate.
Report, edit, etc...Posted by Fwop_ on 2005-12-25 at 17:12:02
Yeah, Subrosian is right, but it would still change, because not all units spawn the same way, and it really only effects the ones that spawn in the exact same X cooridinate
Report, edit, etc...Posted by LurkerEgg on 2005-12-25 at 17:37:46
QUOTE(Subrosian @ Dec 25 2005, 05:01 PM)
The location moves to the last unit created in the left-right coordinate.
[right][snapback]389515[/snapback][/right]


I have no idea what you meant by that, can you clarify? Anyway, we aren't talkin about after-start creation: this health bar is placed in the editor.
Report, edit, etc...Posted by Fwop_ on 2005-12-25 at 18:22:44
If two of the same units have the same X cooridinate, meaning they are directly above each other, and you center location over 1 of them, the location will center over whichever was created first.
Report, edit, etc...Posted by Subrosian on 2005-12-25 at 18:49:50
QUOTE(LurkerEgg @ Dec 25 2005, 04:37 PM)
Anyway, we aren't talkin about after-start creation: this health bar is placed in the editor.
[right][snapback]389538[/snapback][/right]

The order of the units placed in an editor is the order they are created in-game.

At least for Starforge.
Next Page (1)