Forum

> > CS2D > Scripts > Class script--request
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch Class script--request

4 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt Class script--request

DX
User Off Offline

Zitieren
Can someone make me up Class script with two different teams and the bot selects the class randomly, I tried editing classes.lua but it always fails can you guys build it for me

alt Re: Class script--request

Bowlinghead
User Off Offline

Zitieren
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
-- your generic class code 
--[[
	...
]]--
amountOfClasses = 12

addhook("spawn","mySpawn")
function mySpawn(id)
	if (player(id,"bot")) then
		rand = math.random(1, amountOfClasses);	
		if (rand == 1) then
			-- corresponding stats to the first class
			parse("speedmod "..id.." 100")
			return 50, 70; 
		elseif (rand== 2) then
		-- corr. stats to the second class
		elseif (rand==3) then
		-...		
		end
	end

end
Happy copy& pasting
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht