Home   Help Search Login Register  

Author Topic: Team Score  (Read 693 times)

0 Members and 1 Guest are viewing this topic.

StonedSoldier

  • Guest
Team Score
« on: 26 May 2004, 15:21:04 »
how would i go about making a script that would show the scores of all the men in my group, i would like it displayed in a hint box that looks like this,

Scores

Bobby Bruning : 3
James Pound : 1
Adam Shillingsburg : 0
Ryan Carriera : 6

thankx

Dubieman

  • Guest
Re:Team Score
« Reply #1 on: 26 May 2004, 18:40:04 »
Well I'd imagine that a score script for each guy is needed and then one titletext script that brings everything together.

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Team Score
« Reply #2 on: 26 May 2004, 20:34:43 »
Use the format command.

Example:

hint format ["Player score: %1", _playerScore]
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

StonedSoldier

  • Guest
Re:Team Score
« Reply #3 on: 26 May 2004, 22:10:38 »
thankx guys, i know how to use the format command, i was just wondering if there was a easy way to do what i want......i foresee me having to do a heck of a lot of scripting

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Team Score
« Reply #4 on: 27 May 2004, 04:07:28 »
No, the only 'big scripting' you will have to do is the part where you give 'score' to the units in the group (you do know that the "score" command only works on players, right?). Otherwise, you just use the 'format' command, and the 'name' command, and you are all set, display-wise:

hint format["SCORES\n%1: %2\n%3: %4", name unit1, SCORE_1, name unit2, SCORE_2]

And so on. I don't see where the big deal is... ???
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

StonedSoldier

  • Guest
Re:Team Score
« Reply #5 on: 27 May 2004, 09:42:33 »
i had written the script slighty easier,

having one varible brought together to make a single string,

_score1 = format ["%1 %2", name man, score man]

i made it nice a pretty only to find that the score command only works for human players like you stated and CPU players,

do you know if there is a way to calculate a non-human players kills??  :gunman: