[FilterScript] [FS] S.A.S [UPDATED v1.2]
#1

Simple Away System v1.2 (SAS)
_________________________________________________

Summary
Well .. quite simply .. it's a simple away system. Used on your server, it allows players to let other players know when they are going AFK. With some advanced features for Administrators, this script should be all you need. The script is in beta and will be updated to include more advanced features as the build continues. Please report any bugs as explained below.

_________________________________________________

Commands and Explanations
/away - When used it will freeze the player and send a message to other player letting them know this player is going AFK. It will also add the player to the away list.

/back - Will unfreeze the player, send a message to other players letting them know the player is back, and will remove them from the away list.

/awaylist - When used, will list all players by name and ID, that are currently away.

/deny [ID] - When used by an RCON Administrator, it will disallow the selected player to use the /away command (useful for people who abuse it for example).

/allow [ID] - Reverses the effects of /deny.

/toggleaway - When used by an RCON Administrator, this will toggle the use of /away on and off. However, players are still able to use /back otherwise it would cause bugs for players who are /away at the time this command is used.

_________________________________________________

New in v1.1
/denied - For Administrators, shows a list of all players currently being denied.

/resetaway [ID] - For Administrators, resets a players away status.

AFK status is automatically reset when a player uses mainchat.

When a player uses /away, a 3D label will appear above his/her head to let other players know they are AFK.

_________________________________________________

Awesome! Where do I get it?!
Well I was hoping you'd say that.

Version 1.0 downloads

- Pastebin

- SendSpace

- PlayLSX Mirror


Version 1.1 downloads

- Pastebin

- SendSpace

- PlayLSX Mirror


Version 1.2 downloads Latest!

- Pastebin

- SendSpace

- PlayLSX Mirror

_________________________________________________

I've found a bug!
Please report all bugs (no matter how trivial) to our bug tracker

- Report a bug

Thanks, look out for updates, and enjoy!

_________________________________________________

Changelog
v1.0
Code:
** Initial release.
v1.1
Code:
* Added /denied for admins to view players that are being denied from using the /away command.
* Added /resetaway for admins, when used, the selected player ID will be brought out of AFK.
* Added 3D Text Labels to players whom are AFK.
* Stopped players (admins exempt) using commands other than /back when /away.
* AFK status is now automatically reset when a player types in mainchat.
v1.2
Code:
* Fixed some missing code in /denied - Now only works for Admins.
_________________________________________________

This script is not to be modified in any way without my permission, no credits are to be removed.
Reply
#2

Great job mate, keep up the good Work.

-©un3o.
Reply
#3

I dont have teh knowledge to make it^^
Reply
#4

Quote:
Originally Posted by ♣ ©ⓤⓝⓔⓞ ♣
Great job mate, keep up the good Work.

-©un3o.
Thanks! :P

Quote:
Originally Posted by patchkinson
I dont have teh knowledge to make it^^
Hey cmon now, what'd I say? Practice makes perfect.
Reply
#5

USUK
Reply
#6

MARKUS?!
Reply
#7

Script and topic, updated to v1.1. Please note, the 3D Text Labels have not been tested properly since I have no live server atm. (localhost only) So please, if you do find bugs, report them!

- Regards.
Reply
#8

As a suggestion, insert a feature that forces the player to stand still, not get hurt, not speak, and not perform commands for an allotted time before becoming 'AFK' This removes your abuse issue. For more server control, allow this allotted time to be modified live in-game. 30 would be 30 seconds, 0 for instant 'AFK' mode, etc.
Reply
#9

Thanks for your suggestion So .. you mean, have the player not be able to do anything for say 30 seconds, after that 30 seconds he/she would be able to do everything again? Or have I misunderstood?
Reply
#10

I mean once the player types the command, the AFK effect doesn't take place until 30 seconds are up, and if the players moves, gets hit, shoots, types a command, or whatever, then the AFK doesn't take affect. It would only require 1 timer (per player)

pawn Code:
SetTimerEx("OnPlayerAFK",30000,0,"i",playerid);

public OnPlayerAFK(playerid)
{
  new Float:x,Float:y,Float:z,Float:hp;
  GetPlayerHealth(playerid,hp);
  if((pAFKX[playerid]!=x)||(pAFKY[playerid]!=y)||(pAFKZ[playerid]!=z)||(pAFKHP[playerid]!=hp))return SendClientMessage(playerid,0xFF0000FF,"Your AFK has been interupted prematurely, try not to move!");
  //Code
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)