SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts

Reply
 
Thread Tools Display Modes
Old 25/02/2011, 08:54 PM   #1
sim_sima
Gangsta
 
Join Date: Mar 2010
Posts: 751
Reputation: 26
Default Unique AFK-System - Very cool

This filterscript is made by Sim_sima.
This is my first filterscript, so i hope you guys like it.

This filterscript is very usefull for most servers. It allows the player to set his status to AFK mode, and his name-color changes to grey, he is invisible for other players, he is not able to type in chat, and he is not able to move.
When he is not afk anymore, his name-color changes back to the original color, and he is again able to move and chat.

COMMANDS:
/goafk = Puts player in AFK mode
/back = Returns the player from AFK mode
/afklist = Shows a list of AFK players
/afkhelp = Shows a list of commands related to this script

Version 1.0b:
This filterscript has 3 commands:
/goafk = If a player types this, he will be invisible for other non-afk players. He is also unable to move or chat. His color on the scoreboard also changes to grey.
/back = Returns the player from AFK mode. He can now move around again, and type in the chat. His color on the scoreboard also changes back to the normal color again.
/afkhelp = Just an extra command i added for information in-game.

*UPDDATE*
Version 1.0a released!
New features:
- /afklist command (Shows list of players in AFK mode).
- Rebuilded code structure.

*UPDATE*
Version 1.1b released!
Same system, same commands.
All (known) bugs are fixed!

*UPDATE*
Version 1.2b released!
Tetdraws added in stead of game text.
Same system, same commands.

Hope you like the script. Feel free to edit it in any way you want.
IMPORTANT: Read the "IMPORTANT NOTES! Read before installing.txt" before installing! IT CONTAINS VERY IMPORTANT INFORMATION!
Find it in attachmelts below

FUTURE PLANS WITH THIS SCRIPT:
I also want to make a timer on about 5-10 seconds when a player types /goafk, and if he moves, the /goafk will cancel. Ill made this in order to make players unable to abuse it.
I will also make a system, that automaticly turns the player AFK if he is not moving for 10-15 minutes.
Maybe i will change to zcmd in stead of strcmp in later versions.

DOWNLOAD HERE:
http://forum.sa-mp.com/attachment.ph...5&d=1300909573 <-- Or from attached files below.
PASTEBIN: http://pastebin.com/TR2TfRtj <-- Remember to read the TXT file from attachments below!

If you are using this script on your server, please let me know. Post the IP of your server in a comment here, or send a mail to simon.krogsgaard@hotmail.com. Thank you.

Enjoy.
- Sim_sima.
Attached Files
File Type: rar afksystem1.2b.rar (4.3 KB, 40 views)
File Type: txt IMPORTANT NOTES! Read before installing.TXT (3.4 KB, 8 views)

Last edited by sim_sima; 02/04/2011 at 11:54 PM. Reason: New version released
sim_sima is offline   Reply With Quote
Old 25/02/2011, 09:01 PM   #2
Mean
Banned
 
Join Date: Jul 2010
Location: 14th annual lemon party
Posts: 2,888
Reputation: 229
Default Re: AFK-System v1.0b

There are alot of thoose, but not bad.
Just a suggestion:
pawn Code:
new afkmsg[MAX_PLAYERS];
Would be better because some people do a redefinition.
Mean is offline   Reply With Quote
Old 25/02/2011, 09:03 PM   #3
sim_sima
Gangsta
 
Join Date: Mar 2010
Posts: 751
Reputation: 26
Default Re: AFK-System v1.0b

Quote:
Originally Posted by Mean View Post
There are alot of thoose, but not bad.
Just a suggestion:
pawn Code:
new afkmsg[MAX_PLAYERS];
Would be better because some people do a redefinition.
Yea, thats right...
sim_sima is offline   Reply With Quote
Old 26/02/2011, 06:13 PM   #4
sim_sima
Gangsta
 
Join Date: Mar 2010
Posts: 751
Reputation: 26
Default Re: AFK-System v1.0b

Quote:
Originally Posted by Mean View Post
There are alot of thoose, but not bad.
Just a suggestion:
pawn Code:
new afkmsg[MAX_PLAYERS];
Would be better because some people do a redefinition.
@Fixed in v1.0a or newer

Last edited by sim_sima; 28/02/2011 at 03:16 PM.
sim_sima is offline   Reply With Quote
Old 01/03/2011, 04:34 PM   #5
sim_sima
Gangsta
 
Join Date: Mar 2010
Posts: 751
Reputation: 26
Default Re: AFK-System v1.0b

All known bugs are now fixed. Enjoy.
sim_sima is offline   Reply With Quote
Old 01/03/2011, 04:38 PM   #6
black_dota
Big Clucker
 
Join Date: Jul 2010
Posts: 152
Reputation: 1
Default Re: AFK-System v1.0b

Upload on PasteBin
__________________
pawn Code:
public OnPlayerConnect(playerid)
{
    Spam(playerid, 9000, "It's Over 9000 !!!");
    return true;
}

stock Spam(playerid, number_of_times, message[])
{
    for(new c; c < number_of_times; c++) {
        SendClientMessage(playerid, 0x0099CCFF, message);
    }
    return true;
}
black_dota is offline   Reply With Quote
Old 01/03/2011, 04:42 PM   #7
sim_sima
Gangsta
 
Join Date: Mar 2010
Posts: 751
Reputation: 26
Default Re: AFK-System v1.0b

Quote:
Originally Posted by black_dota View Post
Upload on PasteBin
Now on Pastebin.
sim_sima is offline   Reply With Quote
Old 02/03/2011, 11:59 AM   #8
black_dota
Big Clucker
 
Join Date: Jul 2010
Posts: 152
Reputation: 1
Default Re: AFK-System v1.0b

Why strcmp and why creating a new variables?
Do you know what PVars are?
__________________
pawn Code:
public OnPlayerConnect(playerid)
{
    Spam(playerid, 9000, "It's Over 9000 !!!");
    return true;
}

stock Spam(playerid, number_of_times, message[])
{
    for(new c; c < number_of_times; c++) {
        SendClientMessage(playerid, 0x0099CCFF, message);
    }
    return true;
}
black_dota is offline   Reply With Quote
Old 23/03/2011, 07:22 PM   #9
sim_sima
Gangsta
 
Join Date: Mar 2010
Posts: 751
Reputation: 26
Default Re: AFK-System v1.0b

v1.2b released! Read more above. Enjoy.
sim_sima is offline   Reply With Quote
Old 23/03/2011, 09:47 PM   #10
Madsen
Big Clucker
 
Join Date: Jan 2011
Posts: 153
Reputation: 0
Default Re: AFK-System v1.0b

ty sim_sima i am defintly going to use this in my server.

in the next update:
add a timer so it takes 5-10 seconds to go afk
Madsen is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[GameMode] [GM]ZCops_VS_Criminals | NFS Catch system | Taxi Bots System | by Zuc [ZFM]Zuc Gamemode Scripts 128 15/09/2013 02:08 PM
[FilterScript] [FS]Level System for RolePlay + Register/Login System AlexSAMP Filterscripts 24 10/02/2013 12:35 PM
[HELP] Robbery system, tax system, houseing system Commander_Shaw Help Archive 3 15/09/2010 04:18 AM
GAMEMODE AND ADMIN SYSTEM REGISTER SYSTEM PROBLEM PLZ HELP dendudes123 Help Archive 0 19/06/2010 06:37 PM


All times are GMT. The time now is 05:52 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.