Home   Help Search Login Register  

Author Topic: scripting in mp question  (Read 1279 times)

0 Members and 1 Guest are viewing this topic.

Offline .pablo.

  • Former Staff
  • ****
  • When in doubt, empty the magazine.
scripting in mp question
« on: 25 Jun 2003, 23:40:13 »
i have about 12 civies in my mp coop, and i have 2 triggers for each of them

1st trig says that if the civie gets injured, addrating -1000
2nd trig says that if the civie gets killed, addrating -5000

i heard somewhere that running scripts speeds up the game, is that true?  if it is, can this script run in my mp coop?

and what is the difference between addrating and addscore?
« Last Edit: 25 Jun 2003, 23:43:51 by pablo_m123 »

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:scripting in mp question
« Reply #1 on: 26 Jun 2003, 11:25:35 »
Well, not exactly sure what you are trying to accomplish with this...but to answer your q's:

1.  I am pretty sure scripts will help speed up
2. addrating makes them "good guys" with better skills, or "bad guys"  a negative rating makes them renegades and everyone will attack them.
3.  Addscore affects the score value you see when you press"I" and also at the bebriefing, (I think)

Why addrating to dead people?  If I can figure out what you are trying to do, maybe addscore -1000 would be better?

Offline .pablo.

  • Former Staff
  • ****
  • When in doubt, empty the magazine.
Re:scripting in mp question
« Reply #2 on: 26 Jun 2003, 22:49:41 »
thx for your help, ill go into more detail:

i have a mp mission where the players need to complete a certain objective and there are civilians in the area.  i want the players to work as a team and therefore have a score/rating/whatever to judge how well they did.  so what i want is for the score to go down when a civilian is injured, and down again if a civilian is killed.  

what i ended up doing was creating 2 triggers per civilian, which gave me about 24 triggers just for the civilians, when i already have about 20 triggers for the rest of the game.  when i go to preview the mission in the editor it takes a good 5-10 seconds to load, which is pretty weird.  i figure it must be because of all the triggers i have, which are constantly checking for things.

so i was wondering how i could help the players judge how well they did, and whether using scripts would keep the game running smoothly.

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:scripting in mp question
« Reply #3 on: 27 Jun 2003, 23:27:00 »
Well, in a MP game, the score is automatically reduced for a TK, or for killing a civilian, and increased for killing an enemy.  I seem to be having trouble getting it to display a negative number tho, so I tried:
player addscore 100
in each players init, then when I shot a civilian or did a TK my score went down by 1 point and when I killed an enemy it went up by 1.

I have not had any luck injuring civilians either, they are quite fragile!  They go down with 1 shot.

Hope this helps.  This way you don't need triggers at all for the civilians if you are not worried about "protecting" them.  For protecting them, a scrpt something like this might help:
?(!alive civ1) player addscore -10
?(!alive civ2) player addscore -10
etc....
and create 1 trigger that calls this script just before the mission ends then you don't need individual triggers for each civ