Forum

> > CS2D > Scripts > get 1$ money from killing zombies not 300$
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch get 1$ money from killing zombies not 300$

7 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt Re: get 1$ money from killing zombies not 300$

DX
User Off Offline

Zitieren
@user Bowlinghead:
1
2
3
4
5
6
7
8
9
function showhealth()
     for _, id in pairs( player(0, 'table') ) do
          local HP = player(id, 'health')
          parse('hudtxt2 ' .. id .. ' 1 "\169255255255Health: ' .. HP .. '" 100 200')
     end
end


addhook("always","showhealth")
like this but money

alt Re: get 1$ money from killing zombies not 300$

TimeQuesT
User Off Offline

Zitieren
user Bowlinghead hat geschrieben
Get creative.
1
2
3
4
5
6
addhook("kill","yourself")
function yourself(vic,kil)
if (player(vic,"team") == 1) then
	parse("setmoney "..kil.. "..player(kil,"money")-299)
end
end


This will bug when @(16000-298) but nvm. How many zombies have to be killed aww (just calc some delta)

@user DX:
1
2
3
4
5
6
7
8
9
function showmuniez()
     for _, id in pairs( player(0, 'table') ) do
          local muny= player(id, 'money')
          parse('hudtxt2 ' .. id .. ' 1 "\169255255255Your inventory holds: ' .. muny.. ' dollarz" 100 200')
     end
end


addhook("always","showmuniez")
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht