Staredit Network

Staredit Network -> UMS Assistance -> mineral counter
Report, edit, etc...Posted by Toothfariy on 2006-04-26 at 21:14:21
wow... it been a while since i had a question. here it is :

im making a map where im counting killing spree one player has and im useing the players mineral count. when they die its set back to 0 again. but the problem is what trigger will detect if i kill exactly 1 unit at a time so it adds 1 mineral.

im pretty sure that if i do this it will repeat adding 1 mineral cause of the perserve trigger

condision
-"current player kills at most 1 men"
action
-"Add one mineral to Current Player"
-"Perserve Trigger"

any thoughts?
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 21:23:42
you can change the at most to at least if you want
and then you can add this into the conditions.
-set deaths for the enemy(or computer player) to 0 men
Report, edit, etc...Posted by Toothfariy on 2006-04-26 at 21:29:10
but its that the guy killed another guy. idk what setting deaths will do
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 21:36:38
QUOTE(Toothfariy @ Apr 26 2006, 05:28 PM)
but its that the guy killed another guy. idk what setting deaths will do
[right][snapback]473445[/snapback][/right]

yea i know, it'll detect the deaths when the players unit die and set the death count of their men to 0.
here's an example trigger

Conditions:
-current player suffers at least 1 death of unit
Actions:
-set deaths for current player to 0 men
-add 1 mineral for current player
-preserve trigger

i would also recommend the use of hyper triggers.

setting the deaths back to 0 for the current player will prevent it from firing infinitly and gaining minerals, and will only detect when the unit is killed. each time they kill a unit, it adds 1 mineral.
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 21:56:52
Use the kill score.

There are plenty of tutorials about this subject under the heading "Kills to cash". The only difference is that you are using "cash" as a measure of a player's killing spree rather than something that is spent.
Report, edit, etc...Posted by Toothfariy on 2006-04-26 at 21:58:31
so since there is 6 players it'd be like this

condition
-current player kills 1 men
action
-add 1 mineral to current player
-set deaths of player 1 to 0
-set deaths of player 2 to 0
-set deaths of player 3 to 0
-set deaths of player 4 to 0
-set deaths of player 5 to 0
-set deaths of player 6 to 0

im already useing kill score
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 22:03:11
Kills and kill score are NOT the same thing...look it up in the tutorials before you go any further.

And no, that trigger won't work. It'll add minerals infinitely.
Report, edit, etc...Posted by Toothfariy on 2006-04-26 at 22:07:05
kill score as in leader board thing? its being used
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 22:10:25
The leaderboard is a display. It has nothing to do with this.

Go read the kills to cash tutorials. Now. Then use that to measure the spree as briefly described in my first post.
Report, edit, etc...Posted by OhManTfe on 2006-04-26 at 22:16:55
Condition: Player 1 kill score is at least 1
Action: Set kill score to 0 for Player 1
Add 1 Mineral for Player 1
Preserve Trigger

have a seperate trigger creating the kill score in the first place.

Basically every time you kill somebody you'll get 1 mineral and because of the leaderboard thing it wont keep giving minerals.
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 22:18:18
QUOTE(Toothfariy @ Apr 26 2006, 05:58 PM)
so since there is 6 players it'd be like this

condition
-current player kills 1 men
action
-add 1 mineral to current player
-set deaths of player 1 to 0
-set deaths of player 2 to 0
-set deaths of player 3 to 0
-set deaths of player 4 to 0
-set deaths of player 5 to 0
-set deaths of player 6 to 0

im already useing kill score
[right][snapback]473488[/snapback][/right]

i think that trigger might make you map a little wierder or screw up a part of it, cause that will effect everyone...justs take the example trigger i posted earlier, then for the players who own the trigger, check the players 1 thru 6. that might work more efficiently(i think)

Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 22:19:16
QUOTE(OhManTfe @ Apr 26 2006, 09:16 PM)
Condition: Player 1 kill score is at least 1
Action: Set kill score to 0 for Player 1
           Add 1 Mineral for Player 1
           Preserve Trigger

have a seperate trigger creating the kill score in the first place.

Basically every time you kill somebody you'll get 1 mineral and because of the leaderboard thing it wont keep giving minerals.
[right][snapback]473507[/snapback][/right]



...I was hoping he'd have the sense to read that in the tutorials for himself, but oh well. Score one for the laziness team.

You don't need a seperate trigger for generating the kill scores. Kill score is generated by killing units according to the value of the units killed (there's a table in the tutorials that lists them all). Your seperate trigger would be for resetting the minerals when the player dies.

Sly: Your example trigger would give him points for dying, not killing. So no, don't use that.
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 22:25:06
oh i see, i read it wrong, my bad...i get it now...you can use my example trigger as a secondary trigger after this one with a few changes...

Players:
-1 thru 6
Conditions:
-Current player kills at least 1 men
Actions:
-set to 0 kills score
-add 'value' of custom points
-set resources, add 1 mineral for current player
-preserve trigger


Players:
-1 thru 6
Conditions:
-current player suffers at least 1 death of (men) or unit
Actions:
-set resources, set to 0 minerals
-set deaths for current player to 0 men
-preserve trigger
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 22:27:53
That also won't work. You can't change kills, only the kill score.

Look at the trigger that OhManTfe put up. It's basically right out of the tutorial that I was trying to get Toothfairy to read, and with the minor correction that I noted, will serve just fine.
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 22:37:33
QUOTE(Wing-of-no-Wing @ Apr 26 2006, 06:27 PM)
That also won't work. Setting the number of deaths doesn't affect the number of kills. Your first trigger will fire forever once activated, and your second trigger will fire when the player dies, and do nothing related to the action of the first trigger.

Look at the trigger that OhManTfe put up. It's basically right out of the tutorial that I was trying to get Toothfairy to read, and with the minor correction that I noted, will serve just fine.
[right][snapback]473518[/snapback][/right]

sorry i'm getting a little sloppy posting without thinking. but the first trigger won't fire forever now, but deaths are kills. when the player suffers a death of the minerals will get set to 0 for the streak. the triggers won't fire forever now.
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 22:39:28
Deaths are not kills. Just...no.

Try your triggers out and then come back. I've already tried my way of working with this in practice, and it works.
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 22:48:32
QUOTE(Wing-of-no-Wing @ Apr 26 2006, 06:39 PM)
Deaths are not kills. Just...no.

Try your triggers out and then come back. I've already tried my way of working with this in practice, and it works.
[right][snapback]473531[/snapback][/right]

well when they kill something it adds a death count of that unit. but with the trigger it sets the death of that back to 0 and does something along with it where you can set it.

like setting the deaths of the units to 0 would probably mean that the kills don't exist in a sense.
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 22:53:44
QUOTE(SlyShadow @ Apr 26 2006, 09:48 PM)
well when they kill something it adds a death count of that unit. but with the trigger it sets the death of that back to 0 and does something along with it where you can set it.
[right][snapback]473540[/snapback][/right]


It adds a death count for the player who controlled the unit that was killed, not the player who controls the unit that killed it. Have you ever actually used your system? This, for example, shows the use of kill score in setting minerals. Of course, this example was originally made as a concept for defenses, so it has a lot of extra stuff that Toothfairy won't need, but it does show that the kill score system works. No "probably" about it.
Report, edit, etc...Posted by Kyuubi. on 2006-04-26 at 23:27:54
sorry, i'm not thinking and posting straight today. here's a hastily,sloppy, example map i created...
it utilizes the kill scores,deaths, and a customized score setting
[attachmentid=18533]

in this;
-each time you kill a unit, it adds 2 custom points to the leaderboard, and adds 1 mineral
-when you die or get killed, the minerals are set to 0 and respawn top left
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-26 at 23:49:57
See, now that you're using kill score (and the trigger that I was originally describing) it works. You can remove the death count action from your triggers with no effect at all on the system.
Report, edit, etc...Posted by Urmom(U) on 2006-04-27 at 14:43:45
If you detect the death of the unit and not the kill score, you can't detect who killed the unit. That is why it's best to use kill score like Wing-of-no-Wing has been saying.
Report, edit, etc...Posted by Kyuubi. on 2006-04-27 at 15:59:17
QUOTE(urmom @ Apr 27 2006, 10:43 AM)
If you detect the death of the unit and not the kill score, you can't detect who killed the unit.  That is why it's best to use kill score like Wing-of-no-Wing has been saying.
[right][snapback]473820[/snapback][/right]

ya, as i said i was getting a little hasty without thinking...sorry about that. the kill score could be detected and converted into custom points and stuff like that. i made a sloppy map anyway.
Report, edit, etc...Posted by Toothfariy on 2006-04-27 at 16:27:23
ok, i cant read any of those links an i cant dl that map idk y

any way, i think i understand now. is it possible to use custom score for it instead?
Report, edit, etc...Posted by Kyuubi. on 2006-04-27 at 16:44:30
QUOTE(Toothfariy @ Apr 27 2006, 12:27 PM)
ok, i cant read any of those links an i cant dl that map idk y

any  way, i think i understand now. is it possible to use custom score for it instead?
[right][snapback]473931[/snapback][/right]

yea you can convert the kill score points into custom points. for an example

Conditions
current player kill score is at least 1
current player kill score is at most 50
Actions:
-set score to 0 kills for current player
-set score, add 'value' custom
-preserve trigger

to dl a map off a thead, just right click on the file>save as>change the extension to scm/scx or to all into your maps folder.
Report, edit, etc...Posted by Wing-of-no-Wing on 2006-04-27 at 16:51:01
That trigger will only work for a few possible units, since not many have a kill score below 50. Read this table and pick a more appropriate value based on what unit(s) the players will be killing, that is, if you have some reason for having a maximum value in the first place.
Next Page (1)