Jump to content
Shikazu

[Atcommand]afk

Recommended Posts

The plugin is working but has no timeout and you can sit wherever you want.

 

It is being reworked, when i have found out how to access the config's from a plugin.

 

Here it is: https://github.com/shikazu/hpm-plugins/blob/master/src/plugins/afk.c

 

just compile it, add it to your plugins.conf and type @afk ingame :)

 

A little screenshot how it looks ingame, since you can't see it (afk logs you out, but you are still sitting there :D)

 

~Shikazu

post-1071-0-01092800-1370217250_thumb.jpg

Edited by Shikazu

Share this post


Link to post
Share on other sites
ACMD(afk){	sd->state.autotrade = 1;	sd->state.monster_ignore = 1;	pc_setsit(sd);	skill->sit(sd,1);	clif->sitting(&sd->bl);	clif->changelook(&sd->bl,LOOK_HEAD_TOP,471);	clif->specialeffect(&sd->bl, 234,AREA);	clif->authfail_fd(fd, 15);	 return 0;}

return 0; should be return 1; or it will display @afk failed. :)

Edited by quesoph

Share this post


Link to post
Share on other sites

I've added "afk" to the /conf/plugins.conf, added the afk.c to src/plugins/, recompiled and started the server, and when used in-game, says the command doesn't exist. Am I missing something..?

Share this post


Link to post
Share on other sites

I've added "afk" to the /conf/plugins.conf, added the afk.c to src/plugins/, recompiled and started the server, and when used in-game, says the command doesn't exist. Am I missing something..?

Hi sir, I would just like to ask you if you could check your map server if it loaded the plugin correctly

Share this post


Link to post
Share on other sites

I would like to mention that this command can cause some griefers on your server, since there are no checks if this command is allowed in whatever way.

 

A big problem could be that ppl start to mob huuuuge mobs and then type in @afk and are ignored by the monsters. If the monsters are aggressive, ppl in the near will be attacked immediately..

 

This is only one thing, there could be a lot of more :o

 

EDIT:// return is fixed in git! Thank you guys!

 

~Shikazu

Share this post


Link to post
Share on other sites

I would like to mention that this command can cause some griefers on your server, since there are no checks if this command is allowed in whatever way.

 

A big problem could be that ppl start to mob huuuuge mobs and then type in @afk and are ignored by the monsters. If the monsters are aggressive, ppl in the near will be attacked immediately..

 

This is only one thing, there could be a lot of more :o

 

EDIT:// return is fixed in git! Thank you guys!

 

~Shikazu

sir Shikazu did you find out how to add settings on conf file like a timer for afk?

Share this post


Link to post
Share on other sites

No yet, because i have not that much time for that, but i can check it out later, if you want me to do so.

 

~Shikazu

Share this post


Link to post
Share on other sites

Hello Sir Shikazu, i already compiled the @afk plugin on my server using Visual Studio. It's working.

 

I migrated / uploaded my server to my VPS, recompiled it and the server is running and @afk seems not working, says unknown command.

 

groups.conf

afk: true

 

Edit:

 

My VPS is under unix distribution.

Edited by simplynice

Share this post


Link to post
Share on other sites

Did you compile plugins on linux? You have to type "make plugins" in order to compile them. (Windows Compiled wont work on *nix)

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.