Request !shop hud to show player with highest points
#1
as per title anyone, say top 3 or 4
ty
[Image: b_560_95_1.png]


[Image: b_560_95_1.png]

Reply

#2
Wait i'll find function and post there

Edit:

Code:
public ServerClient getMostTop() { int temp = 0; ServerClient guy = null; List<ServerClient> players = GetClients(); for (int i = 0; i < players.Count; i++) { if (player[i].stats.kills >= temp) { temp = player[i].stats.kills; guy = players[i]; } } return guy; }
(Original credits to creators of rotu mod, i have rewritten this function to c#)
You can create variables like
Code:
serverclient top1 serverclient top2 serverclient top3

Then make it
Code:
top1 = getMostTop(); top2 = getMostTop(); top3 = getMostTop();

And add this line to 'getMostTop'
if(player[i].stats.kills >= temp && players[i] != top1 && players[i] != top3 && players[i] != top4 )
{
guy = etc....
}

Then print their names.
Code:
Use topX.Name

It was working perfectly in my killme zombiemod.
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply

#3
(02-21-2013, 14:12)SailorMoon Wrote: Wait i'll find function and post there

Edit:

Code:
public ServerClient getMostTop() { int temp = 0; ServerClient guy = null; List<ServerClient> players = GetClients(); for (int i = 0; i < players.Count; i++) { if (player[i].stats.kills >= temp) { temp = player[i].stats.kills; guy = players[i]; } } return guy; }
(Original credits to creators of rotu mod, i have rewritten this function to c#)
You can create variables like
Code:
serverclient top1 serverclient top2 serverclient top3

Then make it
Code:
top1 = getMostTop(); top2 = getMostTop(); top3 = getMostTop();

And add this line to 'getMostTop'
if(player[i].stats.kills >= temp && players[i] != top1 && players[i] != top3 && players[i] != top4 )
{
guy = etc....
}

Then print their names.
Code:
Use topX.Name

It was working perfectly in my killme zombiemod.
and that now with your kiLL ME mod?: :


: :
Reply

#4
ty i'l give it ago Wink

oh well i'm lost already sigh*
[Image: b_560_95_1.png]


[Image: b_560_95_1.png]

Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Help Sentry Gun kill = Player kill Snake 8 8,251 11-07-2013, 13:41
Last Post: Nekochan
  [Request] Health and Points on hud source robinvm 7 8,179 10-27-2013, 08:23
Last Post: robinvm
  [Release] CS addon for MW2(Sounds,show damage) Fl0w_.JACKDAN 1 6,300 09-29-2013, 19:46
Last Post: Nekochan
  Player can write Fl0w_.JACKDAN 2 5,136 09-19-2013, 16:36
Last Post: Fl0w_.JACKDAN
  Shop Database Hallla 5 6,562 07-23-2013, 07:33
Last Post: xfxtroll
  [News] Show your wallpaper. Nekochan 6 6,982 07-10-2013, 19:02
Last Post: House
Wink [Release] Shop system for Infected gametype Nekochan 125 100,573 07-05-2013, 18:09
Last Post: mohammadnanaa
  [CoD 4] Trying to set a player -- DidUknowiPwn 7 8,291 07-03-2013, 21:58
Last Post: Pozzuh
  [Release] Black Ops Single Player/Zombie Trainer V3.6 Craig87 52 101,664 07-01-2013, 15:12
Last Post: explosivebanana55
Video Preview AIZombies eXtreme 2.0 / Zombie Player (Music Player) DidUknowiPwn 4 8,085 06-24-2013, 16:37
Last Post: DidUknowiPwn

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2026 Melroy van den Berg.