Forum

> > CS2D > Scripts > Lua Scripts/Questions/Help
Forums overviewCS2D overview Scripts overviewLog in to reply

English Lua Scripts/Questions/Help

6,770 replies
Page
To the start Previous 1 2279 280 281338 339 Next To the start

old Re: Lua Scripts/Questions/Help

Loooser
User Off Offline

Quote
try this:
1
2
3
4
5
6
addhook("walkover","walkover")
function walkover(id,iid,type)
         	if iid==47 then
          		return 1
         	end
end

old Re: Lua Scripts/Questions/Help

maPmaKer
User Off Offline

Quote
loooser has written
try this:
1
2
3
4
5
6
addhook("walkover","walkover")
function walkover(id,iid,type)
         	if iid==47 then
          		return 1
         	end
end


Is not working (I tryed it)

old Re: Lua Scripts/Questions/Help

maPmaKer
User Off Offline

Quote
Flacko has written
You have to use item(iid,"type")==47 to get the actual type id instead of the object id of the weapon


Thanks now it works. You're cool too

old PLEASE HELP MEH!!

berk
User Off Offline

Quote
Could someone script a lua to deactivate the "Ennemy down" and the "Fire in the hole" Sound&Message?

PLEASE!

old Re: Lua Scripts/Questions/Help

DC
Admin Off Offline

Quote
the fire in the hole message can be disabled (locally) in the options menu. you don't even need lua for that.

options > more > hud_fireinthehole > 0 - Off / False > Apply

for everything else: radio hook, return 1 in hooked function

old Re: Lua Scripts/Questions/Help

berk
User Off Offline

Quote
And how i disable Teammate down ?

And how you mean radio hook return 1 in hooked function?

And if you say locally you mean i have to change it in the Server setting or in the Options of meh?

Couldn't you write that as a lua ?

old Re: Lua Scripts/Questions/Help

hyh2
COMMUNITY BANNED Off Offline

Quote
ethand has written
Can anybody supply me with a script that saves a user's money [ for RP ] and loads it on connection ? thanks a lot


Code your own.

old Re: Lua Scripts/Questions/Help

RyceR
User Off Offline

Quote
Can anybody make for me script to save chat in "sys/lua/SERVER.txt" file like:
1
2
3
4
15/10/2010 day:
[8:29] RyceR says: Hi all!
[8:29] The G0D says: Hello.
[8:30] The G0D says: What is name of this mode?
or
1
2
3
[8:29] RyceR says: Hi all!
[8:29] The G0D says: Hello.
[8:30] The G0D says: What is name of this mode?

EDIT: Fixed
edited 1×, last 15.10.10 06:40:10 pm

old Re: Lua Scripts/Questions/Help

HaRe
User Off Offline

Quote
CoolioG has written
Yes, is there anyway that I can disable the "rcon quit" function?


No, Unless you dont make an "Admin Script" Wich dosent use "quit" command

old Re: Lua Scripts/Questions/Help

sixpack
User Off Offline

Quote
HaRe has written
CoolioG has written
Yes, is there anyway that I can disable the "rcon quit" function?


No, Unless you dont make an "Admin Script" Wich dosent use "quit" command


HaRe is right. You have to make an Admin Script else you are not able to do this...

If you want one, ask here...

old Re: Lua Scripts/Questions/Help

Lee
Moderator Off Offline

Quote
CoolioG has written
is there anyway that I can disable the "rcon quit" function?


Yes

1
2
3
4
addhook("parse", "remove_rcon_quit")
function remove_rcon_quit(text)
	if text == "quit" then return 2 end
end

Since rcon is only parsed on the clientside, the server still parses quit.

old Re: Lua Scripts/Questions/Help

Fehu
User Off Offline

Quote
Why this dont work ?:

1
2
3
4
5
6
addhook("hit","god_on")
function god_on(id,source,weapon,hpdmg,apdmg)
    if god[id]==1 then
	return 1
    end
end

//Edit

Skipper, yes!
edited 1×, last 16.10.10 03:33:41 pm

old Re: Lua Scripts/Questions/Help

RAVENOUS
BANNED Off Offline

Quote
Fehuziom has written
Why this dont work ?:

1
2
3
4
5
6
addhook("hit","god_on")
function god_on(id,source,weapon,hpdmg,apdmg)
    if god[id]==1 then
	return 1
    end
end


You implemented an array on god?
To the start Previous 1 2279 280 281338 339 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview