Forum

> > CS2D > Scripts > About Trigger
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch About Trigger

5 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt About Trigger

X-Files
User Off Offline

Zitieren
hi i m maked rp lua for own server.but I could not pass here.
my English is bad, so I'll give an example.

player = x-files
x-files have 10000$
x-files want to buy house
but
house is 15000$

so x-files press house's trigger but it doesnt work,because x-files not have 15000$ money

I hope you understand
plss help me

alt help

X-Files
User Off Offline

Zitieren
yess √

Does anyone know this???
helpp
2× editiert, zuletzt 08.01.11 14:39:05

alt Re: About Trigger

EngiN33R
Moderator Off Offline

Zitieren
1
2
3
4
5
6
addhook("use","buyhouse")
function buyhouse(id)
	if (player(id,"tilex")==BUYTILEX and player(id,"tiley")==BUYTILEY and MONEYVAR>=15000) then
		-- WHATEVER YOU PUT HERE
	end
end

Where BUYTILEX and BUYTILEY - position of the trigger, MONEYVAR is your server's money variable, WHATEVER YOU PUT HERE - you write the house owning part there.

alt Re: About Trigger

X-Files
User Off Offline

Zitieren
thx engineer I solved this problem

again if another problem occurs, you can ask?
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht