English Timer

4 replies
Goto Page
To the start Previous 1 Next To the start
01.04.17 10:39:13 pm
Up
Mami Tomoe
User
Offline Off
Hi! I need help

This is a function
Code:
1
2
3
4
5
function unmute(pl)
     local pl=tonumber(pl)
     rp_muted[pl]=false
     rp_msg2(pl,rgbcolor.green,"["..script_name.."]: "..rgbcolor.yellow.."You are no longer muted.")
end


This is a timer
Code:
1
2
3
4
5
6
7
8
9
10
11
12
if time==1 then
                                        time=60000
                                   elseif time==2 then
                                        time=120000
                                   elseif time==3 then
                                        time=180000
                                   elseif time==4 then
                                        time=240000
                                   elseif time==5 then
                                        time=300000
                                   end
                                   timer(time,"unmute",pl)


When I call the timer with a !mute <id> 1 (for 1 minute) it should go to milliseconds so its 60000 but I waited a lot (a lot) minutes and I still not unmuted?? Why I not unmuted?

Please help me!!
01.04.17 11:25:54 pm
Up
RedizGaming
GAME BANNED
Offline Off
you can try to do not use same var "time - time"

Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
for id = 1,32 do
     times[id] = 0
end

if time == 1 then
     times[id] = 60000
elseif time == 2 then
     times[id] = 120000
elseif time == 3 then
     times[id] = 180000
elseif time == 4 then
     times[id] = 240000
elseif time == 5 then
     times[id] = 300000
end
timer(times[id],"unmute",pl)


something like this ?
Never use HACKS/CHEATS , see my status. I used hack 2 times , 1 year ago... i get game banned for be a stupid guy
01.04.17 11:50:33 pm
Up
Mami Tomoe
User
Offline Off
This can't be it it has to be something else because I used something like that before

mstime and time
02.04.17 03:15:28 am
Up
Bowlinghead
User
Offline Off
Do sth like this:
Code:
1
2
3
4
5
6
addhook("serveraction","myAc")
function myAc(id,b)
     if b==1 then
          unmute(2)
     end
end

Or similiar to save some time.

Does the unmute function work properly?

And you could save some code by writing:
Code:
1
time = (60000 * time)



You use the rp_msg2 function like this:
rp_msg2(pl, color, text)
I dont know if this comma is intended!
Share time limited free games here
02.04.17 08:18:52 am
Up
Mami Tomoe
User
Offline Off
More >


NVM I just use my own timer using second hook
edited 3×, last 02.04.17 09:13:34 am
To the start Previous 1 Next To the start