English Jail Weapon {[Five-Seven]}

16 replies
Goto Page
To the start Previous 1 Next To the start
13.08.13 01:56:31 pm
Up
Mora_rus
User
Offline Off
Hello
Please help me with (Jail weapon)
i made this script,but is not full:
i need help please
Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
polices = {114940}

addhook("say","_say")

function _say(id,message)
     for _, usgn in ipairs(polices) do
          if player(id,'usgn')==usgn then
               msg("©000000255"..player(id,"name").." (Police): "..message)
               return 1
          end
     end
end

addhook("attack","_pol")
function _pol(id)
local wpn = (id,"weapontype)
for _, usgn in ipairs(polices) do
        if wpn == 6 then
parse("spawnplayer ... and  nothing
I need help with this
if players (police) attack others players with Five-seven then players spawn in position(1550,1400) and arrest in 10 sec
and 
msg2("©255255000You Has Been Arrested in 10 sec! Dont Break Rules")


i need help with Attack. if players who have usgn in polices list then when is fire of this weapon(five-seven) other player is arrest in 10 sec and if he is dead then spawn in this jail.When time is UP then this player normal spawn
And please!-sorry for my very bad English
Thanks you!
13.08.13 03:42:51 pm
Up
Rainoth
Moderator
Offline Off
The Code >


I don't know if it will work. Try it out. Pretty sure I did everything correctly.
edited 1×, last 13.08.13 04:46:24 pm
13.08.13 04:29:45 pm
Up
Mora_rus
User
Offline Off
I am sure that it works! Because of you I greatly help! And all that you are doing works.
The more you do it best.
Are you really a very good person.
Thank you very much @user Rainoth:
EDIT:
LUA ERROR: sys/lua/jail.lua:29: bad argument #1 to 'player' (number expected, got nil)
13.08.13 04:46:59 pm
Up
Rainoth
Moderator
Offline Off
If it's only my code then I fixed that line. It was your mistake

msg2(msg) was written, not msg(id,msg)
13.08.13 06:10:53 pm
Up
Mora_rus
User
Offline Off
huh?
I don't understand
The translator is not correctly conveys thoughts
In the code :
The more I don't understand ( my skills in scripts 1%/100%)
13.08.13 06:12:53 pm
Up
nobilit
User
Offline Off
Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
polices = {114940}

addhook("say","_say")

function _say(id,message)
     for _, usgn in ipairs(polices) do
          if player(id,'usgn')==usgn then
               msg("©000000255"..player(id,"name").." (Police): "..message)
               return 1
          end
     end
end

addhook("attack","_pol")
function _pol(id)
local wpn = (id,"weapontype)
for _, usgn in ipairs(polices) do
        if wpn == 2 then
parse("spawnplayer ... and  nothing
I need help with this
if players (police) attack others players with Five-seven then players spawn in position(1550,1400) and arrest in 10 sec
and 
msg2("©255255000You Has Been Arrested in 10 sec! Dont Break Rules")


√ i fixed it
13.08.13 06:14:35 pm
Up
Mora_rus
User
Offline Off
no, it`s my code
13.08.13 06:15:45 pm
Up
nobilit
User
Offline Off
srry i'm bad scriper
13.08.13 06:25:00 pm
Up
Rainoth
Moderator
Offline Off
The Code >


Fixed. Tested. Working. It was my mistake because I made myself an argument "s" but used "sour" that I'm used to. Sorry : )
13.08.13 06:26:01 pm
Up
nobilit
User
Offline Off
wow, you are pro thank you very much
13.08.13 06:48:44 pm
Up
Mora_rus
User
Offline Off
Sorry but:
When i hit player with F-S then nothing
When i kill bot with F-S and he re-spawn and he after 10 sec has TP in Jail
and if he spawn in jail (when i kill him) and i say /bot_kill then he spawn normal(no in jail)
13.08.13 06:53:07 pm
Up
Rainoth
Moderator
Offline Off
The script works this way :
• When you hit a player, if you are using 5-7 and you're "polices" it will teleport that player to a location after 10 seconds and write him a message that he's arrested.
• if after 10 seconds he's dead, he'll be spawned in Jail.

I understood that much from your post. It appears you want player to always be in Jail, or what ?
13.08.13 07:05:38 pm
Up
Mora_rus
User
Offline Off
No, It's:
If I hit bot/player from 5-7 it in the same moment appears in prison and he will receive the message " you are under arrest! Do not break the rules "
within 10 seconds player/bot can't leave the prison ( even if he dies and again )
And after 10 seconds, it will again be able to spawn in the ordinary info_ct/info_t
13.08.13 08:18:55 pm
Up
Rainoth
Moderator
Offline Off
Oh ok
Give me some time and I'll make it.
14.08.13 01:41:16 pm
Up
Mora_rus
User
Offline Off
Please no hard,i need learn it :]
14.08.13 02:03:14 pm
Up
Rainoth
Moderator
Offline Off
Ups. I made it but forgot to post. Sorry...

The Code >


It'll keep player in your spot for 10 seconds, he won't be able to walk around freely for 10 seconds because he'll be teleported to that spot for 10 seconds (and after them he will no longer be teleported)
14.08.13 03:21:20 pm
Up
Mora_rus
User
Offline Off
Oh Raining mammoths! i i dont have words! you,you very good person! Really! im, ohhh thanks

P.s-script work 120%
P.P.s-Read PM @user Rainoth:
edited 1×, last 14.08.13 04:25:37 pm
To the start Previous 1 Next To the start