Forum

> > CS2D > General > l4d.lua script bug
ForenübersichtCS2D-ÜbersichtGeneral-ÜbersichtEinloggen, um zu antworten

Englisch l4d.lua script bug

4 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt l4d.lua script bug

BoosterxD
User Off Offline

Zitieren
i play l4d.lua now
i chose tank its a tank
next round i chose francis it be tank
my frined say its bug

helpme!!!

Admin/Mod Kommentar

title changed. that seems to be a script bug and not a server bug. /DC

alt Re: l4d.lua script bug

Lee
Moderator Off Offline

Zitieren
Please, if you're going to report a bug in a Lua script and wants help debugging it, Post the Script so we know what you're talking about.

alt Re: l4d.lua script bug

BoosterxD
User Off Offline

Zitieren
i remake that it bug T^T

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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
---------------------------------------------------------------------------------------------------- 
-- Survivors/Zombies Classes Script by Bertykiller -- 
-- 20.04.2009 - Go to my server !!! -- 
-- Adds Survivors/Zombies Classes to your server -- 
---------------------------------------------------------------------------------------------------- 

if sdz==nil then sdz={} end 
sdz.classes={} 

---------------------------------------------------------------------------------------------------- 

function initArray(m) 
     local array = {} 
     for i = 1, m do 
          array[i]=0 
     end 
     return array 
end 
sdz.classes.classt=initArray(32) 
sdz.classes.classct=initArray(32) 
function sdz.classes.classmenut(id) 
     menu(id,"Select your Zombie,Smoker,Hunter,Wicth,Tankr") 
end 

function sdz.classes.classmenuct(id) 
     menu(id,"Select your Survivor,Fransic,Zoey,Bill,Louis")      
end 

---------------------------------------------------------------------------------------------------- 

addhook("team","sdz.classes.team") 
function sdz.classes.team(id,team) 
     if (team==1) then 
          sdz.classes.classmenut(id) 
     elseif (team==2) then 
          sdz.classes.classmenuct(id) 
     end 
end 

----------------------------------------------------------------------------------------------------      

addhook("menu","sdz.classes.menu") 
function sdz.classes.menu(id,menu,sel) 
     if (menu=="Select your Zombie") then 
          if (sel>=0 and sel<=4) then 
               sdz.classes.classt[id]=sel 
               if (player(id,"health")>0) then 
                    parse("killplayer "..id) 
               end 
          end 
     elseif (menu=="Select your Survivor") then 
          if (sel>=0 and sel<=4) then 
               sdz.classes.classct[id]=sel 
               if (player(id,"health")>0) then 
                    parse("killplayer "..id) 
               end 
          end 
     end 
end 

---------------------------------------------------------------------------------------------------- 

addhook("spawn","sdz.classes.spawn") 
function sdz.classes.spawn(id) 
           
          -- Smoker      
          if (sdz.classes.classt[id]==1) then 
               parse ("setmaxhealth "..id.." 150") 
               parse ("speedmod "..id.." 2") 	
	parse ("setarmor "..id.." 203") 	
               return "78"; 
          	end 
          -- Hunter 
          if (sdz.classes.classt[id]==2) then 
                parse ("setmaxhealth "..id.." 50") 
	parse ("setarmor "..id.." 203") 
               parse ("speedmod "..id.." 30") 
               return "78"; 
          	end 
          -- Wicth
          if (sdz.classes.classt[id]==3) then 
               parse ("setmaxhealth "..id.." 100") 
	parse ("setarmor "..id.." 202") 
               parse ("speedmod "..id.." 20") 
               return "78"; 
         	 end 
          -- Tank 
          if (sdz.classes.classt[id]==4) then 
               parse ("setmaxhealth "..id.." 100") 
	parse ("setarmor "..id.." 205") 
               parse ("speedmod "..id.." -1") 
               return "78"; 
          	end

          -- Francis
          if (sdz.classes.classct[id]==1) then 
               parse ("setmaxhealth "..id.." 200") 
               parse ("setarmor "..id.." 201") 
               parse ("speedmod "..id.." 2") 
               return "11,6,69,74,51,73"; 
          	end 
          -- Zoey 
          if (sdz.classes.classct[id]==2) then 
               parse ("setmaxhealth "..id.." 150") 
               parse ("setarmor "..id.." 202") 
               parse ("speedmod "..id.." 3") 
               return "34,2,69,74,51,73"; 
          	end
          -- Bill 
          if (sdz.classes.classct[id]==3) then 
               parse ("setmaxhealth "..id.." 150") 
               parse ("setarmor "..id.." 202") 
               parse ("speedmod "..id.." 2") 
               return "21,3,69,74,51,73"; 
          	end  
          -- Louis 
          if (sdz.classes.classct[id]==4) then 
               parse ("setmaxhealth "..id.." 120") 
               parse ("setarmor "..id.." 204") 
               parse ("speedmod "..id.." 3") 
               return "32,5,69,74,51,73"; 
          	end 
end 

---------------------------------------------------------------------------------------------------- 

addhook("buy","sdz.classes.buy") 
function sdz.classes.buy() 
     return 1 
end 

---------------------------------------------------------------------------------------------------- 

addhook("drop","sdz.classes.drop") 
function sdz.classes.drop() 
     return 1 
end 

---------------------------------------------------------------------------------------------------- 

addhook("die","sdz.classes.die") 
function sdz.classes.die() 
     return 1 
end 

----------------------------------------------------------------------------------------------------

wat = "51 52 53 54 72 73 75 76 77 86" -- Grenades

addhook ("attack","noreload")
function noreload(p)
w = player(p,"weapontype")
if (w~=0) then parse("equip "..p.." "..w) 
end
end

addhook("projectile","noreload1")
function noreload1(p,w)
if (string.find(wat,w)~=nil) then
	parse("equip "..p.." "..w)
	parse("setweapon "..p.." "..w)
end
end

----------------------------------------------------------------------------------------------------

Admin/Mod Kommentar

Please use the [code] tags, they really help us! /TheKilledDeath
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antwortenGeneral-ÜbersichtCS2D-ÜbersichtForenübersicht