Issue information

Issue ID
#4827
Status
Fixed
Severity
Fair
Started
Hercules Elf Bot
Mar 20, 2011 15:26
Last Post
Hercules Elf Bot
Jun 9, 2012 21:23
Confirmation
N/A

Hercules Elf Bot - Mar 20, 2011 15:26

Originally posted by [b]theultramage[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=4827

Current state:
  • a command can have its own 'usage' instructions embedded inside its command function
  • @help parses conf/help.txt on each call, and filters by gm level; compares against values embedded in the file, can be out of date
  • #help no longer works the same way, used to load conf/charhelp.txt, now unused and dead (although see r14572, no idea why that even exists)

Proposal:
  • have @help work like man pages - @help <command>
  • loads atcommand.txt, at startup or on first use
  • atcommand.txt contains explanation and usage instructions, for each command individually (easily translatable)
  • @help alone would invoke @help help (and maybe suggest using @commands if your gm level is high enough)
  • @help <command> would display usage for that particular command (if your gm level is high enough)
  • all commands could either return a special value to indicate usage should be printed, or invoke atcommand_help

Unresolved issues:
  • what would the file format for atcommand.txt be?
  • what about aliases? should their docs just say "see <primary name>"? or should we have some sort of aliasing support?


This post has been edited by theultramage: Mar 20 2011, 08:27 AM

Hercules Elf Bot - Jan 13, 2012 20:48

Originally posted by [b]Xantara[/b]
For this, I'd prefer either of the following layouts (preferably the first).
[quote]mi,mobinfo,monsterinfo#
Displays information about a monster.
Usage: {COMMAND} <monster name/id>
#[/quote]

[quote]# mi,mobinfo,monsterinfo
~ Displays information about a monster.
~ Usage: {COMMAND} <monster name/id>[/quote]

And how about the fopen for the gmotd command?

This post has been edited by Xantara on Jan 14, 2012 3:59

Hercules Elf Bot - Jun 1, 2012 14:39

Originally posted by [b]Ind[/b]
epoque or gepard or both fixed this in a recent revision whose number i have no damn idea :D