Forum

> > CS2D > Scripts > Lua Scripts/Questions/Help
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch Lua Scripts/Questions/Help

6.770 Antworten
Seite
Zum Anfang Vorherige 1 2175 176 177338 339 Nächste Zum Anfang

alt Re: Lua Scripts/Questions/Help

Flacko
User Off Offline

Zitieren
Dark Byte hat geschrieben
Flacko hat geschrieben
@Noxic:[...] Alt+169 code. [...]

no it is Alt+0169


Ugh...
It's exactly the same...

alt Re: Lua Scripts/Questions/Help

archmage
User Off Offline

Zitieren
Flacko hat geschrieben
Dark Byte hat geschrieben
Flacko hat geschrieben
@Noxic:[...] Alt+169 code. [...]

no it is Alt+0169


Ugh...
It's exactly the same...

no (at least not for me)
Alt+169 == ⌐
Alt+0169 == ©

alt My Q

Kostyan1996
User Off Offline

Zitieren
Hello, modmakers ! I want to ask two or questions on modmaking:
1) I will ask for an example (classes.lua). How do I, that place of spawn depended on what class a player choose?
2) Is it possible to do so (all the same clases.lua), so that some classes were only available for Ts, and others only for CTs?
Thank for reading Kost@n

alt Re: Lua Scripts/Questions/Help

DRoNe
User Off Offline

Zitieren
Kostyan1996 hat geschrieben
Hello, modmakers ! I want to ask two or questions on modmaking:
1) I will ask for an example (classes.lua). How do I, that place of spawn depended on what class a player choose?
2) Is it possible to do so (all the same clases.lua), so that some classes were only available for Ts, and others only for CTs?
Thank for reading Kost@n


1)
1
parse ("setpos "..id.." "..x.." "..y")

2) Yes, it is possible
example:
1
2
if (team==1) -- for Ts
	if (team==2) -- for Cts

alt TO DRONE

Kostyan1996
User Off Offline

Zitieren
Thank, but one Q.
1
parse ("setpos "..id.." "..x.." "..y")
I dont understand, "x" and "y", that change to "x" and "y", what I need? and with "..", or not?
---------------------
OW! And 1 Q. (last XD)
Can I make the players were able to take up arms or throw them?
1× editiert, zuletzt 17.03.10 15:18:05

alt Re: Lua Scripts/Questions/Help

TimeQuesT
User Off Offline

Zitieren
Kostyan1996 hat geschrieben
Thank, but one Q.
1
parse ("setpos "..id.." "..x.." "..y")
I dont understand, "x" and "y", that change to "x" and "y", what I need? and with "..", or not?
---------------------
OW! And 1 Q. (last XD)
Can I make the players were able to take up arms or throw them?

example:

x= 300
y=300
parse("setpos "..id.." "..x.." "..y)
-- or
parse ("setpos "..id.." 300 300")--the same crap

alt Re: Lua Scripts/Questions/Help

DRoNe
User Off Offline

Zitieren
Khaleed hat geschrieben
hey can someone get me a script that just my and my friends usng id can enter on terroris or ct
???


1
2
3
4
5
6
7
8
9
10
11
addhook("team","admteam")
function admteam(id,team)
	if (team==1) then
		if (player(id, "usgn") == your_usgn_here) or (player(id, "usgn") == your_freind_usgn_here) then
			parse("maket "..id)
		else
			return 1 
			
		end
	end
end

i make for you : you and your friends can join T, other players can't join T ... only ct

alt Re: Lua Scripts/Questions/Help

siuL
User Off Offline

Zitieren
yes but its alot of friends like 17 .
i need like to make "vip" and "admin" but i already have this script i need this and anothers lol

alt Re: Lua Scripts/Questions/Help

siuL
User Off Offline

Zitieren
no im sayin same thing of before but i need much things to put and will not write that more 15 times o.O
oh i want skins too
i will create ... later lol

alt RPG Shop

Kostyan1996
User Off Offline

Zitieren
And 1 question...
Who know, how to use RPG Shop?
Say me plz, or give manual...
Ang if you have, give me RPG Shop (Script) plz...
Thank
1× editiert, zuletzt 17.03.10 17:43:13

alt RPG SHOP

Kostyan1996
User Off Offline

Zitieren
OMG! ITS VERY HARD FOR ME!!!
Give plz rpg shop script and say me how to USE THAT!!!1111ONEONEoneone...
Thank

alt Re: Lua Scripts/Questions/Help

siuL
User Off Offline

Zitieren
can someone help with this script :
if sample==nil then sample={} end
sample.gl={}
sample.gh={}
addhook("always","sample.gl.always")
addhook("say","sample.gh.say")

function sample.gl.always()
parse("sethealth 1 250")
parse("setmaxhealth 1 250")
end

function sample.gh.say(p,txt)
if (txt=="god 0") then freehook("always","sample.gl.always"); end
if (txt=="god 0") then parse("killplayer 1"); end
if (txt=="god 1") then addhook("always","sample.gl.always"); end
if (txt=="god 1") then parse("equip 1 83"); end
end

its right but .. i ned like god just for cts ( all of cts team )

alt Re: Lua Scripts/Questions/Help

Cure Pikachu
User Off Offline

Zitieren
@ Khaleed

All of CTs have god mode? Well try this code then (I did a change, so don't mind OK?) (Fixed up, Thanks Flacko! )

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
if khaleed==nil then khaleed={} end 
khaleed.gl={} 
khaleed.gh={} 

addhook("always","khaleed.gl.always") 
addhook("say","khaleed.gh.say") 

--This function will save me some writing 
--to get the team of a player 
function p_team(id) return player(id,"team") end 

function khaleed.gl.always() --Always hook has no parameters 
	--Loop thru all the players in server 
	for indx,id in ipairs(player(0,"table")) do 
		if p_team(id)==2 then 
			parse("sethealth "..id.." "..250); 
			parse("setmaxhealth "..id.." "..250); 
		end 
	end 
end 

function khaleed.gh.say(id,txt) 
     --Turn to lowercase so the cmd is case-unsensitive 
	txt = txt:lower() 
	if p_team(id)==2 then 
		if txt=="god 0" then 
			freehook("always","khaleed.gl.always"); 
			parse("killplayer "..id); 
		elseif txt=="god 1" then 
			addhook("always","khaleed.gl.always"); 
			parse("equip "..id.." "..83); 
		end 
	end 
end
3× editiert, zuletzt 14.04.10 14:40:55

alt Re: Lua Scripts/Questions/Help

DRoNe
User Off Offline

Zitieren
1
math.random = (0, trigger("blabla"))

or :

1
math.random = (0, ("trigger blabla"))

What is better and what is wrong, if this two codes are bad write me that good code
2× editiert, zuletzt 18.03.10 16:20:41
Zum Anfang Vorherige 1 2175 176 177338 339 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht