Forum

> > CS2D > General > Small scripts needed.
Forums overviewCS2D overviewGeneral overviewLog in to reply

English Small scripts needed.

23 replies
Page
To the start Previous 1 2 Next To the start

old Re: Small scripts needed.

Lee
Moderator Off Offline

Quote
Jonzku777 has written
This doesn`t overwrite that scripts i currently have?


Edit2: AND do i have to move my previous luas to this amx2d-place?

edit4: Where can i find commands for this amdx2 things?


No, you just place them into the sys/lua/amx2d/mods/ folder and add them in the mods.cfg settings file (in sys/lua/amx2d/settings/mods.cfg)

For the commands, open up a server with amx2d loaded (read the readme I've just posted) and type in !help

old Re: Small scripts needed.

RedPillow
User Off Offline

Quote
I have found all the commands and i get the system now, last guestions:

Do you know what is wrong with this piece of code? it doesnt show me the id of player
1
2
3
4
5
6
7
8
9
10
11
function adm_getid_admin(p, cmd)
     cmd = trim(cmd)
     local names = {}
     for i =1, 32, 1 do
          if player(i, "exists") then
               names[player(i, "name")] = i
          end
     end
     if names[cmd] then msg2(p, "Player "..cmd.." is at ID: "..names[cmd]) end
     return 2
end

And what the thing with that !guns-command? when i typed !guns Laser, my whole pc crashed

Thanks.

old Re: Small scripts needed.

Lee
Moderator Off Offline

Quote
oke, they should work now, go redownload the AMX2D package via Revision 23

http://code.assembla.com/mod2d/subversion/nodes

And @getid can only be used once you login using !login and only if you provide a name, ie:

@getid Player or @getid Player 3

if you don't want to login, but still want to know your own ID, then use

!getid

note, use ! not @ for the second one.

For guns, use

@guns Laser

this shouldn't return any type of error (worked on me)

and to give it to other people, use

@guns 5 Laser
To the start Previous 1 2 Next To the start
Log in to replyGeneral overviewCS2D overviewForums overview