Forum
CS2D Scripts Lua Scripts/Questions/HelpHeres a .
leegao has written
And so comes the spirit of do it yourself. This thread isn't called 'Make me a Script', it's called 'Lua Scripts/Questions/Help'. If you're coming here to request a complete script without even bothering to attempt it yourself, trust me, no one here will want to help you.
Here are the things to get you started, when you made this request the first time I've already written the word filter for you, the rest is up to you to finish.
http://6.dot.ch/2009/wordfilter-in-lua/
And google for Lua Boolean values, and then read the CS2D Lua Readme. This can't be all that difficult.
Also, for future reference, on behalf of those of us here who helps out every day on the lua topic (TKD, Linux, KK, Wups, Flacko, Blazing, etc), no more Script requests are allowed on here. You can hire us, and I'm sure we can determine a reasonable rate for freelancing for you (usually $12 per hour), but if you're not willing to at least attempt to write it yourself, we're definitely not going to waste our time on someone who doesn't want to learn.
On the other hand, if you come here with an attempted script (no matter how ugly it looks), we'll be happy to help you sort out the problem.
Yrael has written
i need someone who can make scripts to make me a bad word filter.
And so comes the spirit of do it yourself. This thread isn't called 'Make me a Script', it's called 'Lua Scripts/Questions/Help'. If you're coming here to request a complete script without even bothering to attempt it yourself, trust me, no one here will want to help you.
Here are the things to get you started, when you made this request the first time I've already written the word filter for you, the rest is up to you to finish.
http://6.dot.ch/2009/wordfilter-in-lua/
And google for Lua Boolean values, and then read the CS2D Lua Readme. This can't be all that difficult.
Also, for future reference, on behalf of those of us here who helps out every day on the lua topic (TKD, Linux, KK, Wups, Flacko, Blazing, etc), no more Script requests are allowed on here. You can hire us, and I'm sure we can determine a reasonable rate for freelancing for you (usually $12 per hour), but if you're not willing to at least attempt to write it yourself, we're definitely not going to waste our time on someone who doesn't want to learn.
On the other hand, if you come here with an attempted script (no matter how ugly it looks), we'll be happy to help you sort out the problem.
ok, wtv, forget it. wtv happened to just doing it for the heck of it? ive got a friend who needs spray tags and he doesnt have the software or the knowledge, and i just do it for him. cs2d is a free game, so why should we pay for the scripts? and this (http://6.dot.ch/2009/wordfilter-in-lua/) guy doesn't make you pay!!
i totally disagree. its about giving.
i put " #55000000 "Killer!" @c but when i try it , it comes out like this:
#55000000Killer!
Yrael has written
ok, wtv, forget it. wtv happened to just doing it for the heck of it? ive got a friend who needs spray tags and he doesnt have the software or the knowledge, and i just do it for him. cs2d is a free game, so why should we pay for the scripts? and this (http://6.dot.ch/2009/wordfilter-in-lua/) guy doesn't make you pay!!
i totally disagree. its about giving.
i totally disagree. its about giving.
And I totally disagree with you as well, it's about Sarcasm.
And why should you pay for the script? I don't know, if you want to pay me for it even after I released as a free, no-obligation copy-left material onto the internet then that's your choice, charity always helps.
But either way, you definitely need to brush up on your English a little bit more because apparently we're having a major communication problem here.
Let me rephrase this.
I've already written the word filter for a you a couple weeks ago when you asked for it the first time. Apparently you never took the initiative back then so I'm giving you the link again.
It's up to you to figure out the easy part (linking that script together with CS2D). We're not going to do everything for you. We can try to help you, but we don't make completed scripts for other people. It's entirely selfish to presume so.
@Mex - Use the copyright sign instead of #
Quote
How do i code in amx2d too check if a user is admin and logged in?
like a for loop that check the whole player(0,"table") list.
And check if a user is admin and logged in. And then do something.
I have readed the auth code, but can't really get how to use that way.
like a for loop that check the whole player(0,"table") list.
And check if a user is admin and logged in. And then do something.
I have readed the auth code, but can't really get how to use that way.
The irony here is that I had to go back to my code and pick out the admin accessors again
The following tables will help you determine who's an admin, what level or admin, and who they are higher than
admins[p] - takes the current player ID - returns the type of admin the player is.
users[username] - Complete table of all admins/users
userpid[username] - Gives out the player_id of the User (None if not exists)
playeruid[player_id] - Gives out the user_name of the player (None of the player is not logged in)
The following function determines the priority of the user (returns a table with all the user-groups who are lower then him)
adminhierarchy(user_group) - Table with user-groups
edited 1×, last 21.08.09 05:41:18 pm
@C = At center
RRRGGGBBB = color values; red green and blue.
1
"©[b]RRRGGGBBB[/b][i]Player 1[/i] text in between [i]Player 2[/i]@C"
1
"©200200200'..killer..' killed '..victim..'@C"
KimKat has written
@Mexican:
@C = At center
RRRGGGBBB = color values; red green and blue.
This would work depending on how you use it.
@C = At center
RRRGGGBBB = color values; red green and blue.
1
"©[b]RRRGGGBBB[/b][i]Player 1[/i] text in between [i]Player 2[/i]@C"
1
"©200200200'..killer..' killed '..victim..'@C"
ohh so i put copyright sign , not #?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
2
3
4
5
6
7
8
9
10
11
12
13
14
thenumber=1 addhook("triggerentity","mat5b") function mat5b(x,y) 	if x==2 then 		if y==14 then 			thenumber+1 		end 	end 	if x==8 then 		if y==14 then 			thenumber+1 		end 	end end
EDIT: Ok, I tried sth else. Nevermind this post.
edited 1×, last 21.08.09 06:48:48 pm
Mexican has written
ohh so i put copyright sign , not #?
Well yea, the colors wouldn't show if you put # infront of the number values so it is © instead. KimKat has written
@Mexican:
@C = At center
RRRGGGBBB = color values; red green and blue.
This would work depending on how you use it.
@C = At center
RRRGGGBBB = color values; red green and blue.
1
"©[b]RRRGGGBBB[/b][i]Player 1[/i] text in between [i]Player 2[/i]@C"
1
"©200200200'..killer..' killed '..victim..'@C"
ohh so i put copyright sign , not #?
KimKat has written
Mexican has written
ohh so i put copyright sign , not #?
Well yea, the colors wouldn't show if you put # infront of the number values so it is © instead. KimKat has written
@Mexican:
@C = At center
RRRGGGBBB = color values; red green and blue.
This would work depending on how you use it.
@C = At center
RRRGGGBBB = color values; red green and blue.
1
"©[b]RRRGGGBBB[/b][i]Player 1[/i] text in between [i]Player 2[/i]@C"
1
"©200200200'..killer..' killed '..victim..'@C"
ohh so i put copyright sign , not #?
it doesnt work.... once i put the © and save, somthing pops up and i put ok... then when i try it , it shows up as
" !i!55000000Player Has made a doublekill! "
notepad cant read those special characters or somthing?
I have a question:
Can someone make me a script, that after a team wins, wether Ct or T, then comes a sound?
I'm talking about lua scripting here, putting symbols and codes like that into value fields won't do anything except making it look really wrong.
You should try learning some LUA. I can't help you, and I said I've stopped helping people with LUA, so please go learn some.
1
2
3
4
2
3
4
addhook("endround","roundendmusic") function roundendmusic() 	parse("sv_sound \"__Directiory__\"") end
Write Sound directory
and if u want to play with other players
and u want to server play in they computer
sound you must give the sound on map but
dont playonly for download !!
Skipper has written
And, if CT wins or T wins, that's necessary too, or, I need it.
Then, pray to all the gods you know that DC will be implementing that to make it easier...
I wanna make that thing: You choose class 1 and it teleports you to some X and some Y. But when i try to make it, CS2D crashes. What's the problem? By the way, the menu must appear to T team only, but not to CT. Here's the script:
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
if engi==nil then engi={} end engi.classes={} -- engine function initArray(m) 	local array = {} 	for i = 1, m do 		array[i]=0 	end 	return array end engi.classes.class=initArray(32) function engi.classes.classmenu(id) 	menu(id,"Select your Class,Wastelander,Steel Brother,Enclave Solider,Raider,Mercenary")	 end -- team addhook("team","engi.classes.team") function engi.classes.team(id,team) 	if (team<=1) then 		sample.classes.classmenu(id) 	end end -- serveraction addhook("serveraction","engi.classes.serveraction") function engi.classes.serveraction(id) 	engi.classes.classmenu(id) end -- selection addhook("menu","sample.classes.menu") function engi.classes.menu(id,menu,sel) 	if (menu=="Select your Class") then 		if (sel>=0 and sel<=5) then 			engi.classes.class[id]=sel 			if (player(id,"health")>0) then 				parse("killplayer "..id) 			end 		end 	end end -- classes list addhook("spawn","engi.classes.spawn") function engi.classes.spawn(id) 	-- Wastelander 	if (engi.classes.class[id]<=1) then 		parse ("setpos "..id.." 2640 432") 		parse ("setmaxhealth "..id.." 75") 		parse ("speedmod "..id.." 5") 		return "1"; 	end 	-- Steel Brother 	if (engi.classes.class[id]==2) then 		parse ("setmaxhealth "..id.." 125") 		parse ("setarmor "..id.." 200") 		parse ("speedmod "..id.." -5") 		return "46,3"; 	end 	-- Enclave Solider 	if (engi.classes.class[id]==3) then 		parse ("setmaxhealth "..id.." 125") 		parse ("setarmor "..id.." 200") 		parse ("speedmod "..id.." -5") 		parse ("setpos "..id.." 80 6064") 		return "45,72,78"; 	end 	-- Raider 	if (engi.classes.class[id]==4) then 		parse ("setmaxhealth "..id.." 125") 		parse ("setarmor "..id.." 75") 		parse ("setpos "..id.." 2640 4208") 		return "46,6,73"; 	end 	-- Mercenary 	if (engi.classes.class[id]==5) then 		parse ("setmaxhealth "..id.." 75") 		parse ("setarmor "..id.." 50") 		parse ("speedmod "..id.." 15") 		parse ("setpos "..id.." 1872 5520") 		return "5,69,54"; 	end end
edited 1×, last 21.08.09 09:05:36 pm
1
2
3
4
5
6
2
3
4
5
6
addhook("team","engi.classes.team") function engi.classes.team(id,team) if (team[b]<=[/b]1) then sample.classes.classmenu(id) end end
if (team>0) then
as far as I know