how to add help sections/topics with [help] tag?

The place to post your WML questions and answers.

Moderators: Forum Moderators, Developers

Forum rules
  • Please use [code] BBCode tags in your posts for embedding WML snippets.
  • To keep your code readable so that others can easily help you, make sure to indent it following our conventions.
lea
Posts: 146
Joined: October 1st, 2016, 7:25 pm

how to add help sections/topics with [help] tag?

Post by lea » October 3rd, 2016, 2:06 pm

Hello,

tried adding help topics with this code in _main.cfg (at top level, not nested in other tags):

Code: Select all

[+help]
    [toplevel]
        sections=Traits altered
    [/toplevel]
    [section]
        id=Traits altered
        topics=tough
    [/section]
    [topic]
        id=tough
        title=Tough
        text="Units with trait Tough get 20% more hitpoints."
    [/topic]
[/help]
it seems to have no effect (nothing was added to Wesnoth's help after running it with my otherwise working "era"). Tried with both [+help] and [help].
Tried in Wesnoth versions 1.12.6 and 1.10.7
And Ageless Era for v1.10.x contains similar [help] node that also does not work...

What am I doing wrong?

I need help with help :)
Last edited by lea on October 4th, 2016, 6:52 am, edited 1 time in total.
author of: Altered Era/Ruleset (on add-ons servers for BfW 1.14, 1.12 and 1.10 )

User avatar
ForestDragon
Posts: 1496
Joined: March 6th, 2014, 1:32 pm

Re: how to add help sections/topics with [help] tag?

Post by ForestDragon » October 3rd, 2016, 2:32 pm

quick tip:topics like this belongs in the WML Workshop forum, which is meant specifically for things like this
Co-creator of Era of Magic
Creator of Tale of Alan (1.12 abandoned),The Golden Age (1.12/1.13, abandoned),XP Bank (1.14),Alliances Mod(1.14), with a large add-on in development
"Real life is like a hyper-realistic VR game, but with permadeath and boring gameplay"

User avatar
Ravana
Moderator
Posts: 1887
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: how to add help sections/topics with [help] tag?

Post by Ravana » October 3rd, 2016, 2:36 pm

Oh. I didnt know ageless had this.

And yes, moved.

lea
Posts: 146
Joined: October 1st, 2016, 7:25 pm

Re: how to add help sections/topics with [help] tag?

Post by lea » October 4th, 2016, 6:56 am

Ravana wrote:Oh. I didnt know ageless had this.
it is in text/help.cfg file in Ageless Era for Wesnoth 1.10.x, includes topic for "obedient" trait and nothing else.
Ravana wrote:And yes, moved.
Thanks
author of: Altered Era/Ruleset (on add-ons servers for BfW 1.14, 1.12 and 1.10 )

User avatar
The_Gnat
Posts: 1708
Joined: October 10th, 2016, 3:06 am
Contact:

Re: how to add help sections/topics with [help] tag?

Post by The_Gnat » November 17th, 2016, 12:12 am

Yeah i have been having the same problem in my addon the 5 lords reign era! Where should i put my [help] tags, I've tried putting it inside a util file but it doesn't load there so i was wondering if anyone can give examples of working [help] topics that are loaded from addons? The HelpWML page on the wesnoth website tells all the things you can put into a [help] tag but not where you put it :P

EDIT: also is there a way to create a link to a help topic from a message? So that players are easily able to find the pages I created?

User avatar
Samonella
Posts: 359
Joined: January 8th, 2016, 5:41 pm
Location: USA

Re: how to add help sections/topics with [help] tag?

Post by Samonella » January 25th, 2017, 3:36 am

Well, em, I'm having this same problem. If no one has answered, does that mean no one knows the answer? Is it possible that [help] was never meant to be used in add-ons?

The only example of a functional [help] tag I can find is the one in mainline wesnoth... it's included directly from the mainline _main.cfg file, and since doing that in add-ons doesn't work, that example isn't much help. (hee hee no pun intended)

This quote seemed to be an answer:
this wiki page wrote:All tags [in a _main file] save for [campaign] and [textdomain] must be enclosed in an #ifdef preprocessor conditional - including those substituted through inclusion
But [help] still doesn't work when I put it in an #ifdef MULTIPLAYER.
The last few months have been nothing but one big, painful reminder that TIMTLTW.

Creator of Armory Mod, The Rising Underworld, and Voyage of a Drake: an RPG

User avatar
skelegonsans
Posts: 16
Joined: December 11th, 2016, 1:18 am
Location: Miguel Pereira, Rio de Janeiro, Brazil

Re: how to add help sections/topics with [help] tag?

Post by skelegonsans » January 28th, 2017, 10:49 am

I always wanted to know it too!
I took a(nother xD) look at the help.cfg file but i didnt understand much...
Maybe nobody knows how to do it?...

But hey, y'all said that you put the [help] at _main file right? Well i only saw {core/help.cfg} at _main file, which means that maybe you have to create a help file and then point it with the _main file.
I will try it...
Papyrus: "SO, SANS, WHEN IS THE HUMAN COMING?? I WANNA LOOK MY SUNDAY BEST... OR AT LEAST MY TUESDAY PRETTY-GOOD."
Sans: "don't you only have one outfit?"
Papyrus: "YEAH, BUT I COULD STYLE MY HAIR!"
Big Undertale/FNaF fan, creator/mantainer of More Units addon.

User avatar
skelegonsans
Posts: 16
Joined: December 11th, 2016, 1:18 am
Location: Miguel Pereira, Rio de Janeiro, Brazil

Re: how to add help sections/topics with [help] tag?

Post by skelegonsans » January 28th, 2017, 11:23 am

...yep it does not work...
No matter what u do at _main, it wont read the help.cfg.
What the heck makes the core help.cfg file work??
Papyrus: "SO, SANS, WHEN IS THE HUMAN COMING?? I WANNA LOOK MY SUNDAY BEST... OR AT LEAST MY TUESDAY PRETTY-GOOD."
Sans: "don't you only have one outfit?"
Papyrus: "YEAH, BUT I COULD STYLE MY HAIR!"
Big Undertale/FNaF fan, creator/mantainer of More Units addon.

lea
Posts: 146
Joined: October 1st, 2016, 7:25 pm

Re: how to add help sections/topics with [help] tag?

Post by lea » January 28th, 2017, 11:26 am

skelegonsans wrote:What the heck makes the core help.cfg file work??
maybe the fact that it is core file? ;) (just an assumption)
author of: Altered Era/Ruleset (on add-ons servers for BfW 1.14, 1.12 and 1.10 )

User avatar
zookeeper
WML Wizard
Posts: 9739
Joined: September 11th, 2004, 10:40 pm
Location: Finland

Re: how to add help sections/topics with [help] tag?

Post by zookeeper » January 28th, 2017, 12:44 pm

skelegonsans wrote:What the heck makes the core help.cfg file work??
Probably the game only considers the first [help] tag it comes across.

User avatar
skelegonsans
Posts: 16
Joined: December 11th, 2016, 1:18 am
Location: Miguel Pereira, Rio de Janeiro, Brazil

Re: how to add help sections/topics with [help] tag?

Post by skelegonsans » January 28th, 2017, 9:24 pm

I would edit the core help.cfg file to test if thats true but i dont like messing around with core files even if i know what im doing. Last time i had to reinstall wesnoth... (ok i was noob back then but it was a bit traumatic xD)
Papyrus: "SO, SANS, WHEN IS THE HUMAN COMING?? I WANNA LOOK MY SUNDAY BEST... OR AT LEAST MY TUESDAY PRETTY-GOOD."
Sans: "don't you only have one outfit?"
Papyrus: "YEAH, BUT I COULD STYLE MY HAIR!"
Big Undertale/FNaF fan, creator/mantainer of More Units addon.

lea
Posts: 146
Joined: October 1st, 2016, 7:25 pm

Re: how to add help sections/topics with [help] tag?

Post by lea » January 29th, 2017, 6:46 am

skelegonsans wrote:I would edit the core help.cfg file to test if thats true but i dont like messing around with core files even if i know what im doing. Last time i had to reinstall wesnoth... (ok i was noob back then but it was a bit traumatic xD)
if you are on windows (or "Lindows" - linux with wine) then there may be no need for reinstallation:
http://portableapps.com/apps/games/wesnoth_portable
(their *.paf.exe installer is really slightly glorified self-extracting archive)
I did not try it myself because managed to find a satisfactory workaround for my mod so it is "low priority" for me for now
author of: Altered Era/Ruleset (on add-ons servers for BfW 1.14, 1.12 and 1.10 )

User avatar
nuorc
Forum Regular
Posts: 569
Joined: September 3rd, 2009, 2:25 pm
Location: Barag Gor

Re: how to add help sections/topics with [help] tag?

Post by nuorc » January 29th, 2017, 5:36 pm

Reading this thread I was baffled that nobody is able to give an answer.

As the LotI stuff shows up in help I asked Dugi to just tell you, but his reply amounted pretty much to 'I don't know and the help never does what I want'.

Seriously: could this help thing be solved in the current development cycle?
I have a cunning plan.

gfgtdf
Developer
Posts: 1110
Joined: February 10th, 2013, 2:25 pm

Re: how to add help sections/topics with [help] tag?

Post by gfgtdf » January 29th, 2017, 7:59 pm

Iirc there were multiple feature request to add custom help pages on our bugtracker.
The main problems were:
1) we are planning to posrt the help dialog to gui2, and we think its easier to do that first before addin the feature.
2) The help pages use some alternive and old markup syntax, we dont want to require wml devs to learn multiple markup syntaxes so we want to change that first before addin this feature. Im particular we we think its unnesary work to change the interface etc when we one day decive to update that markup syntaxes.


EDIT: i also think that the [+tag] syntax only works within one addon meaning it can never change tags defined in another addon or in wesnoth core wml.
Scenario with Robots SP scenario (1.11/1.12), allows you to build your units with components, PYR No preperation turn 1.12 mp-mod that allows you to select your units immideately after the game begins.

User avatar
skelegonsans
Posts: 16
Joined: December 11th, 2016, 1:18 am
Location: Miguel Pereira, Rio de Janeiro, Brazil

Re: how to add help sections/topics with [help] tag?

Post by skelegonsans » February 2nd, 2017, 3:55 pm

nuorc wrote:Reading this thread I was baffled that nobody is able to give an answer.

As the LotI stuff shows up in help I asked Dugi to just tell you, but his reply amounted pretty much to 'I don't know and the help never does what I want'.

Seriously: could this help thing be solved in the current development cycle?
Yeah, I'm also very surprised that nobody seems to know. I actually thought that many people knew how to do it...
Papyrus: "SO, SANS, WHEN IS THE HUMAN COMING?? I WANNA LOOK MY SUNDAY BEST... OR AT LEAST MY TUESDAY PRETTY-GOOD."
Sans: "don't you only have one outfit?"
Papyrus: "YEAH, BUT I COULD STYLE MY HAIR!"
Big Undertale/FNaF fan, creator/mantainer of More Units addon.

Post Reply