Help with WML for a particular scenario

The place to post your WML questions and answers.

Moderator: Forum Moderators

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.
Post Reply
chak_abhi
Posts: 347
Joined: June 24th, 2010, 3:37 pm

Help with WML for a particular scenario

Post by chak_abhi »

I am new to WML. I have just started creating a campaign. At present it has only 1 scenario.
Here are the scenario and the mains files:
The Scenario--
#text domain wesnoth-Rebellion_in_the_North
[scenario]
id=01_Unexpected_Attack
name=_ "Unexpected Attack"
map_data="{~add-ons/Rebellion_in_the_north/maps/01_Unexpected_Attack.map}"
{turns 30 26 22}
next_scenario=02_Defending_the_Capital

{DAWN}
{MORNING}
{AFTERNOON}
{DUSK}
{FIRST_WATCH}
{SECOND_WATCH}

{INTRO_AND_SCENARIO_MUSIC northerners.ogg}
{EXTRA_SCENARIO_MUSIC loyalists.ogg}
{EXTRA_SCENARIO_MUSIC battle.ogg}

[story]
[part]
story=_"Tallin, a peasant by birth liberated the northlands from the brutal rule of the orcs. He established the Northern Alliance to govern the lands north of the Great River and south of the Longlier and maintain peace and prosperity in the region. Dwarven Doors became the capital of the Alliance.
background=portraits/Tallin.png
scale_background=no
[/part]
[part]
story=_"Humans, dwarves, elves, drakes, and even some tribes of orcs and trolls joined the Alliance. For many years the Alliance did good work. The war ravaged northlands were rebuilt. Dwarven Doors became a great trade centre. Humans from Wesnoth and northern earldoms, dwarves from Knalga and Kal Kartha, Elves from Wesmere and Lintanir forests, and orcs from the far north used to come here to buy and sell their wares.
background=images/Dwarven_Doors4.jpg
[/part]
[part]
story=_"The prosperity of the community of Dwarven Doors aroused much envy from afar. However apart from few isolated uprisings of groups of orcs there was no major trouble in the region. The orcish tribal capital of Rumyr was upgraded to a port for easy trade with the far north and the mermen, and even with far off lands. Lord Protector Howgarth III had ensured safety from the orcs of far north by signing a mutual friendship pact with orcish sovereign Kapou'e.
background=images/Dwarven_Doors1.jpg
[/part]
[part]
story=_"Vikash I succeeded Howgarth III as Lord Protector. He signed a mutual friendhip pact with Adred IV, king of Wesnoth. His rule was marked with peace and tranquility. He selected a young sergeant Krshan as his successor. But in his old age the northlands scented trouble once more. All of a sudden all communications with Krag Kumbh, son of Kapou'e and present orcish sovereign were cut off. Unrest was noted among the orc members of the Alliance also. So Krshan took to oversee all areas under the Alliance one by one, accompanied by his friend Aric.
background=images/Dwarven_Doors3.jpg
[/part]
[part]
show_title=yes
{TO_UNEXPECTED_ATTACK}
[/part]
[/story]

[side]
type="Sergeant"
id="Krshan"
name=_"Krshan"
unrenamable=yes
profile=portraits/krshan.png
side="1"
canrecruit=yes
[modifications]
{TRAIT_RESILIENT}
{TRAIT_INTELLIGENT}
{TRAIT_STRONG}
[/modifications]
controller="human"
{GOLD 150 125 100}
team_name="Alliance"
user_team_name=_"Alliance"
fog="no"
share_view="no"
shroud="no"
share_maps="no"
income="0"
recruit="Peasant, Woodsman"
{FLAG_VARIANT loyalist}

{LOYAL_UNIT 1 (Spearman) 19 26}
{LOYAL_UNIT 1 (Bowman) 20 25}
[/side]

{STARTING_VILLAGES 1 6}

[side]
type="Orcish warrior"
id="Tan Brok"
name=_"Tan Brok"
side="2"
canrecruit=yes
{GOLD 60 80 100}
recruit="orcish warrior, orcish archer, wolf rider"
team_name="Orcs"
user_team_name=_"Orcs"
income="0"
[ai]
passive_leader=yes
grouping=offensive
recruitment_pattern=scout,fighter,archer
{ATTACK_DEPTH 2 3 4}
[/ai]
[/side]

{STARTING_VILLAGES 2 6}

[event]
name=prestart

[unit]
type=horseman
id=Aric
name=_"Aric"
unrenamable=yes
profile=portraits/aric.png
side=1
x=18
y=24
[modifications]
{TRAIT_LOYAL}
{TRAIT_QUICK}
[/modifications]
{IS_HERO}
[/unit]

[objectives]
side=1
[objective]
description=_"Defeat Tan Brok"
condition=win
[/objective]
[objective]
description=_"Death of Krshan"
condition=lose
[/objective]
[objective]
description=_"Death of Aric"
condition=lose
[/objective]
[objective]
description=_"Turns run out"
condition=lose
[/objective]
note={EARLY_FINISH_BONUS_NOTE}+{NEW_GOLD_CARRYOVER_NOTE_40}
[/objectives]
[/event]

[event]
name=start
[message]
speaker=narrator
message=_"Krshan and Aric were touring a village in the south west of the Alliance territory, when they saw a band of orcs to their north."
[/message]
[message]
speaker="Krshan"
message=_"Hail Tan Brok! How do you fare?
[/message]
[message]
speaker="Tan Brok"
message=_"Listen grunts. The human is talking to me as though he is our friend! Enough of pleasantaries, now its time to fight."
[/message]
[message]
speaker="Krshan"
message=_"You are unnecessarily being arrogant. But you aren't serious, are you? You are a trusted member of our Alliance."
[/message]
[message]
speaker="Tan Brok"
message=_"To hell with your alliance. True orcs don't ally with human worms or stinking midgets or dirty tree shaggers! We will now plunder this village and take the booty to our master."
[/message]
[message]
speaker="Krshan"
message=_"How strange! He had visited our capital less than a month ago! Now what to do? I haven't got any soldiers with me!"
[/message]
[message]
speaker="Aric"
message="Are you afraid? You have your loyal soldiers, including me! And the peasants here are always willing to help you! Let us teach these orcs a lesson for betraying the Alliance!"
[/message]
[message]
speaker="Krshan"
message="Right you are Aric. Onward men! Lets get these rebels!
[/message]
[/event]

[event]
name=turn 15
[message]
speaker="Krshan"
message=_"Quickly men. We have to report to the capital as early as possible."
[/message]
[/event]

[event]
name=last breath
[filter]
id="Tan Brok"
[/filter]
[message]
speaker=unit
message=_"I may die, but there are hundreds coming after me. You and your Alliance are doomed. You are no match for the might of my master."
[/message]
[message]
speaker="Krshan"
message=_"What does he mean?...my master...?
[/message]
[message]
speaker="Aric"
message=_"I fear there is much trouble in store for us. Lets go to our capital quickly and tell Lord Vikash about this."
[/message]
[endlevel]
result=victory
bonus=yes
{NEW_GOLD_CARRYOVER 40}
[/endlevel]

[event]
name=time over
[message]
speaker="Krshan"
message=_"More orcs have arrived. Now there is no way out."
[/message]
[/event]
[/scenario]
And the mains file--
#textdomain wesnoth-Rebellion_in_the_North
[textdomain]
name="wesnoth-Rebellion_in_the_North"
[/textdomain]

# wmlscope: set export=no
[campaign]
id=Rebellion_in_the_North
rank=100
icon="units/human-loyalists/marshal-leading.png"
image="data/add-ons/Rebellion_in_the_North/images/campaign_image.png"
name= _ "Rebellion in the North"
abbrev= _ "RitN"
define="CAMPAIGN_REBELLION_IN_THE_NORTH"
first_scenario="01_Unexpected_Attack"
difficulties=EASY,NORMAL,DIFFICULT
difficulty_descriptions={MENU_IMG_TXT2

"units/human-loyalists/sergeant.png~RC(magenta>red)" _"Sergeant" _"(Easy)"} +
";*" + {MENU_IMG_TXT2 "units/human-loyalists/lieutenant.png~RC(magenta>red)"

_"Lieutenant" _"(Normal)"} + ";" + {MENU_IMG_TXT2

"units/human-loyalists/general.png~RC(magenta>red)" _"General" _"(Difficult)"}
description= _"A great orcish uprising tends to destabilise the Northlands. As the

future Lord Protector of the Northern Alliance can you crush the rebellion and establish

peace again?

" + _"(Intermediate level, 30 scenarios.)"
image="data/add-ons/Rebellion_in_the_North/images/campaign_image.png"


[about]
images =

"story/Dwarven_Doors.jpg,story/Dwarven_Doors2.jpg,story/Dwarven_Doors3.jpg,story/Dwarven_

Doors4.jpg,story/Tallin.png,story/Barag_Gor.jpg,story/Borstep.jpg/,story/Tirigaz.jpg,stor

y/Senne.jpg,story/Dorset.png"
[/about]

[about]
title = _ "Campaign Design"
[entry]
name = "Abhishek Chakrabarti(chak_abhi)"
[/entry]
[/about]

[/campaign]

#ifdef CAMPAIGN_REBELLION_IN_THE_NORTH
[binary_path]
path=data/add-ons/Rebellion_in_the_North
[/binary_path]

{~add-ons/Rebellion_in_the_North/scenarios}
#endif


However during loading the following error comes:
Missing closing tag for tag campaign at ~add-ons/Rebellion_in_the_North/_main.cfg,value "at core/macros/utils.cfg:386 included from core/_main.cfg:6 included from_main.cfg:5 included from ~add-ons/Rebellion_in_the_North/_main.cfg:18

What does this mean?How can I fix it?

Another question--how can I assign starting villages to each team?What does the numbers indicate?
Ceres
Forum Regular
Posts: 620
Joined: September 18th, 2010, 7:56 pm
Location: Germany

Re: Help with WML for a particular scenario

Post by Ceres »

It might have nothing to do with the error, but you forgot to terminate the last-breath-event for Tan Brok. And all story strings are unterminated also. Same at some others, you'd better check all messages again.

About your question: first number is the side for the villages, the oher one the radius around the start position, where villages are captured. If you only want to set single villages, use

Code: Select all

[side]
  ...
  [village]
    x=...
    y=...
  [/village]
[/side]
For other village macros, look up in data/core/macros/side-utils.cfg.
chak_abhi
Posts: 347
Joined: June 24th, 2010, 3:37 pm

Re: Help with WML for a particular scenario

Post by chak_abhi »

Ceres wrote:It might have nothing to do with the error, but you forgot to terminate the last-breath-event for Tan Brok. And all story strings are unterminated also. Same at some others, you'd better check all messages again.

Thanks for the help. However when I try to load now it gives the same message followed by a message "Unknown scenario: 01_Unexpected_Attack. I can't find out where the problem is--the "mains" file or the scenario file.
User avatar
Pentarctagon
Project Manager
Posts: 5528
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: Help with WML for a particular scenario

Post by Pentarctagon »

for future reference, you should use the

Code: Select all

 tags instead of the [quote] tags when posting code.
99 little bugs in the code, 99 little bugs
take one down, patch it around
-2,147,483,648 little bugs in the code
User avatar
Elvish_Hunter
Posts: 1575
Joined: September 4th, 2009, 2:39 pm
Location: Lintanir Forest...

Re: Help with WML for a particular scenario

Post by Elvish_Hunter »

A thing that I noticed are your

Code: Select all

difficulties=EASY,NORMAL,DIFFICULT
You should replace it with

Code: Select all

difficulties=EASY,NORMAL,HARD
otherwise several macros, like TURNS, GOLD, INCOME won't work correctly: they expect to have difficult levels named exactly in this way.
Also, you can remove

Code: Select all

[about]
images =

"story/Dwarven_Doors.jpg,story/Dwarven_Doors2.jpg,story/Dwarven_Doors3.jpg,story/Dwarven_

Doors4.jpg,story/Tallin.png,story/Barag_Gor.jpg,story/Borstep.jpg/,story/Tirigaz.jpg,stor

y/Senne.jpg,story/Dorset.png"
[/about]
according to http://wiki.wesnoth.org/CampaignWML, images in [about] is not supported.
Current maintainer of these add-ons, all on 1.16:
The Sojournings of Grog, Children of Dragons, A Rough Life, Wesnoth Lua Pack, The White Troll (co-author)
chak_abhi
Posts: 347
Joined: June 24th, 2010, 3:37 pm

Re: Help with WML for a particular scenario

Post by chak_abhi »

Elvish_Hunter wrote:A thing that I noticed are your

Code: Select all

difficulties=EASY,NORMAL,DIFFICULT
You should replace it with

Code: Select all

difficulties=EASY,NORMAL,HARD
otherwise several macros, like TURNS, GOLD, INCOME won't work correctly: they expect to have difficult levels named exactly in this way.
Also, you can remove

Code: Select all

[about]
images =

"story/Dwarven_Doors.jpg,story/Dwarven_Doors2.jpg,story/Dwarven_Doors3.jpg,story/Dwarven_

Doors4.jpg,story/Tallin.png,story/Barag_Gor.jpg,story/Borstep.jpg/,story/Tirigaz.jpg,stor

y/Senne.jpg,story/Dorset.png"
[/about]
according to http://wiki.wesnoth.org/CampaignWML, images in [about] is not supported.
I have modified accordingly. Yet the same message comes!
User avatar
zookeeper
WML Wizard
Posts: 9742
Joined: September 11th, 2004, 10:40 pm
Location: Finland

Re: Help with WML for a particular scenario

Post by zookeeper »

You could start by fixing all the unclosed quotes.
chak_abhi
Posts: 347
Joined: June 24th, 2010, 3:37 pm

Re: Help with WML for a particular scenario

Post by chak_abhi »

I have closed the unclosed quotes. Now the scenario file looks like:

Code: Select all

#text domain wesnoth-Rebellion_in_the_North
[scenario]
    id=01_Unexpected_Attack
    name=_ "Unexpected Attack"
    map_data="{~add-ons/Rebellion_in_the_north/maps/01_Unexpected_Attack.map}"
    {turns 30 26 22}
    next_scenario=02_Defending_the_Capital

    {DAWN}
    {MORNING}
    {AFTERNOON}
    {DUSK}
    {FIRST_WATCH}
    {SECOND_WATCH}

    {INTRO_AND_SCENARIO_MUSIC northerners.ogg}
    {EXTRA_SCENARIO_MUSIC loyalists.ogg}
    {EXTRA_SCENARIO_MUSIC battle.ogg}

    [story]
        [part]
            story=_"Tallin, a peasant by birth liberated the northlands from the brutal rule of the orcs. He established the Northern Alliance to govern the lands north of the Great River and south of the Longlier and maintain peace and prosperity in the region. Dwarven Doors became the capital of the Alliance."
        background=portraits/Tallin.png
        scale_background=no
        [/part]
        [part]
            story=_"Humans, dwarves, elves, drakes, and even some tribes of orcs and trolls joined the Alliance. For many years the Alliance did good work. The war ravaged northlands were rebuilt. Dwarven Doors became a great trade centre. Humans from Wesnoth and northern earldoms, dwarves from Knalga and Kal Kartha, Elves from Wesmere and Lintanir forests, and orcs from the far north used to come here to buy and sell their wares."
        background=story/Dwarven_Doors4.jpg
        [/part]
        [part]
            story=_"The prosperity of the community of Dwarven Doors aroused much envy from afar. However apart from few isolated uprisings of groups of orcs there was no major trouble in the region. The orcish tribal capital of Rumyr was upgraded to a port for easy trade with the far north and the mermen, and even with far off lands. Lord Protector Howgarth III had ensured safety from the orcs of far north by signing a mutual friendship pact with orcish sovereign Kapou'e."
        background=story/Dwarven_Doors1.jpg
        [/part]
        [part]
            story=_"Vikash I succeeded Howgarth III as Lord Protector. He signed a mutual friendhip pact with Adred IV, king of Wesnoth. His rule was marked with peace and tranquility. He selected a young sergeant Krshan as his successor. But in his old age the northlands scented trouble once more. All of a sudden all communications with Krag Kumbh, son of Kapou'e and present orcish sovereign were cut off. Unrest was noted among the orc members of the Alliance also. So Krshan took to oversee all areas under the Alliance one by one, accompanied by his friend Aric."
        background=story/Dwarven_Doors3.jpg
        [/part]
        [part]
            show_title=yes
            {TO_UNEXPECTED_ATTACK}
        [/part]
    [/story]

    [side]
    type="Sergeant"
    id="Krshan"
    name=_"Krshan"
    unrenamable=yes
    profile=portraits/krshan.png
    side="1"
    canrecruit=yes
    [modifications]
        {TRAIT_RESILIENT}
        {TRAIT_INTELLIGENT}
        {TRAIT_STRONG}
    [/modifications]
    controller=human
    {GOLD 150 125 100}
    team_name=Alliance
    user_team_name=_"Alliance"
    fog="no"
    share_view="no"
    shroud="no"
    share_maps="no"
    income="0"
    recruit="Peasant, Woodsman"
     {FLAG_VARIANT loyalist}

    {LOYAL_UNIT 1 (Spearman) 19 26}
    {LOYAL_UNIT 1 (Bowman) 20 25}
    [/side]

    {STARTING_VILLAGES 1 6}

    [side]
    type="Orcish warrior"
    id="Tan Brok"
    name=_"Tan Brok"
    side="2"
    canrecruit=yes
    {GOLD 60 80 100}
    recruit="orcish warrior, orcish archer, wolf rider"
    team_name=Orcs
    user_team_name=_"Orcs"
    income="0"
    [ai]
        passive_leader=yes
        grouping=offensive
        recruitment_pattern=scout,fighter,archer
        {ATTACK_DEPTH 2 3 4}
    [/ai]
    [/side]

    {STARTING_VILLAGES 2 6}    
    
    [event]
        name=prestart

        [unit]
        type=horseman
        id=Aric
        name=_"Aric"
        unrenamable=yes
        profile=portraits/aric.png
        side=1
        x=18
        y=24
        [modifications]
            {TRAIT_LOYAL}
            {TRAIT_QUICK}
        [/modifications]
        {IS_HERO}
        [/unit]

        [objectives]
            side=1
            [objective]
                description=_"Defeat Tan Brok"
                condition=win
            [/objective]
            [objective]
                description=_"Death of Krshan"
                condition=lose
            [/objective]
            [objective]
                description=_"Death of Aric"
                condition=lose
            [/objective]
            [objective]
                description=_"Turns run out"
                condition=lose
            [/objective]
            note={EARLY_FINISH_BONUS_NOTE}+{NEW_GOLD_CARRYOVER_NOTE_40}
        [/objectives]
    [/event]

    [event]
        name=start
        [message]
            speaker=narrator
            message=_"Krshan and Aric were touring a village in the south west of the Alliance territory, when they saw a band of orcs to their north."
        [/message]
        [message]
            speaker="Krshan"
            message=_"Hail Tan Brok! How do you fare?"
        [/message]
        [message]
            speaker="Tan Brok"
            message=_"Listen grunts. The human is talking to me as though he is our friend! Enough of pleasantaries, now its time to fight."
        [/message]
        [message]
            speaker="Krshan"
            message=_"You are unnecessarily being arrogant. But you aren't serious, are you? You are a trusted member of our Alliance."
        [/message]
        [message]
            speaker="Tan Brok"
            message=_"To hell with your alliance. True orcs don't ally with human worms or stinking midgets or dirty tree shaggers! We will now plunder this village and take the booty to our master."
        [/message]
        [message]
            speaker="Krshan"
            message=_"How strange! He had visited our capital less than a month ago! Now what to do? I haven't got any soldiers with me!"
        [/message]
        [message]
            speaker="Aric"
            message="Are you afraid? You have your loyal soldiers, including me! And the peasants here are always willing to help you! Let us teach these orcs a lesson for betraying the Alliance!"
        [/message]
        [message]
            speaker="Krshan"
            message="Right you are Aric. Onward men! Lets get these rebels!"
        [/message]
    [/event]
 
    [event]
        name=turn 15
        [message]
            speaker="Krshan"
            message=_"Quickly men. We have to report to the capital as early as possible."
        [/message]
    [/event]

    [event]
        name=last breath
        [filter]
            id="Tan Brok"
        [/filter]
        [message]
            speaker=unit
            message=_"I may die, but there are hundreds coming after me. You and your Alliance are doomed. You are no match for the might of my master."
        [/message]
        [message]
            speaker="Krshan"
            message=_"What does he mean?...my master...?"
        [/message]
        [message]
            speaker="Aric"
            message=_"I fear there is much trouble in store for us. Lets go to our capital quickly and tell Lord Vikash about this."
        [/message]
        [endlevel]
            result=victory
            bonus=yes
            {NEW_GOLD_CARRYOVER 40}
        [/endlevel]
    [/event]

    [event]
        name=time over
        [message]
            speaker="Krshan"
            message=_"More orcs have arrived. Now there is no way out."
        [/message]
    [/event]
[/scenario]    
    
    
      
And the main file looks like:

Code: Select all

#textdomain wesnoth-Rebellion_in_the_North
[textdomain]
    name="Rebellion_in_the_North"
    path="data/add-ons/Rebellion_in_the_North/Translations"
[/textdomain]

# wmlscope: set export=no
[campaign]
    id=Rebellion_in_the_North
    rank=100
    icon="units/human-loyalists/marshal-leading.png"
    image="data/add-ons/Rebellion_in_the_North/images/campaign_image.png"
    name= _ "Rebellion in the North"
    abbrev= _ "RitN"
    define=CAMPAIGN_REBELLION_IN_THE_NORTH
    first_scenario="01_Unexpected_Attack"
    difficulties=EASY,NORMAL,HARD
    difficulty_descriptions={MENU_IMG_TXT2 "units/human-loyalists/sergeant.png~RC(magenta>red)" _"Sergeant" _"(Easy)"} +
    ";" + {MENU_IMG_TXT2 "units/human-loyalists/lieutenant.png~RC(magenta>red)" _"Lieutenant" _"(Normal)"} + ";" + {MENU_IMG_TXT2 "units/human-loyalists/general.png~RC(magenta>red)" _"General" _"(Hard)"}
    description= _"A great orcish uprising tends to destabilise the Northlands. As the future Lord Protector of the Northern Alliance can you crush the rebellion and establish peace again?

" + _"(Intermediate level, 30 scenarios.)"
    image="data/add-ons/Rebellion_in_the_North/images/campaign_image.png"
    

    

    [about]
        title = _ "Campaign Design"
        [entry]
            name = "Abhishek Chakrabarti(chak_abhi)"
        [/entry]
    [/about]
        
[/campaign]

#ifdef REBELLION_IN_THE_NORTH
[binary_path]
    path=data/add-ons/Rebellion_in_the_North
[/binary_path]

{~add-ons/Rebellion_in_the_North/scenarios}
#endif


Still an error message comes--Unknown scenario:'01_Unexpected_Attack
I haven't yet found any mistakes which may lead to this situation.
User avatar
zookeeper
WML Wizard
Posts: 9742
Joined: September 11th, 2004, 10:40 pm
Location: Finland

Re: Help with WML for a particular scenario

Post by zookeeper »

define=CAMPAIGN_REBELLION_IN_THE_NORTH
#ifdef REBELLION_IN_THE_NORTH
Few things amaze me as much as how often people manage to do that. There's no reason whatsoever for it yet it's apparently done all the time.
Anonymissimus
Inactive Developer
Posts: 2461
Joined: August 15th, 2008, 8:46 pm
Location: Germany

Re: Help with WML for a particular scenario

Post by Anonymissimus »

zookeeper wrote:
define=CAMPAIGN_REBELLION_IN_THE_NORTH
#ifdef REBELLION_IN_THE_NORTH
Few things amaze me as much as how often people manage to do that. There's no reason whatsoever for it yet it's apparently done all the time.
I think it's because people who do that learn wml as their very first "programming language", not knowing if then else clauses, so they don't assume it needs to match, or are simply too sloppy.
projects (BfW 1.12):
A Simple Campaign: campaign draft for wml startersPlan Your Advancements: mp mod
The Earth's Gut: sp campaignSettlers of Wesnoth: mp scenarioWesnoth Lua Pack: lua tags and utils
updated to 1.8 and handed over: A Gryphon's Tale: sp campaign
chak_abhi
Posts: 347
Joined: June 24th, 2010, 3:37 pm

Re: Help with WML for a particular scenario

Post by chak_abhi »

zookeeper wrote:
define=CAMPAIGN_REBELLION_IN_THE_NORTH
#ifdef REBELLION_IN_THE_NORTH
Few things amaze me as much as how often people manage to do that. There's no reason whatsoever for it yet it's apparently done all the time.
Thanks for pointing this,it has been corrected. But still the same error message of "Unknown scenario" comes.
As a desperate resort I had even considered uploading my campaign as it is now on this forum so that a genuinely helpful person may correct it, but have decided against it as it may not be permitted, and I have already been rebuked by the forum moderators once in this forum itself!

The directory is "E:\Battle for Wesnoth\userdata\data\add-ons\Rebellion_in_the_North". It contains folders "scenarios", "images", "maps" & "Translations"(empty) and file "_main". The "maps" folder has the file "01_Unexpected_Attack.map". The "images" folder has sub folders "portraits", "story" and file "campaign_image".Thats all about it.
I am sure there is someone in the Wesnoth community who can help me out.
User avatar
zookeeper
WML Wizard
Posts: 9742
Joined: September 11th, 2004, 10:40 pm
Location: Finland

Re: Help with WML for a particular scenario

Post by zookeeper »

chak_abhi wrote:As a desperate resort I had even considered uploading my campaign as it is now on this forum so that a genuinely helpful person may correct it, but have decided against it as it may not be permitted, and I have already been rebuked by the forum moderators once in this forum itself!
What? :annoyed:

No, that's exactly what you need to do if you want anyone to help you.
Max
Posts: 1449
Joined: April 13th, 2008, 12:41 am

Re: Help with WML for a particular scenario

Post by Max »

the problem is you still got some bugs in your scenario file, but wesnoth only shows them the first time you launch your campaign. all you get afterwards is the "unknown scenario" message. Unfortunately hitting F5 doesn't help. You need to delete the cache folder or resave your scenario file.
chak_abhi
Posts: 347
Joined: June 24th, 2010, 3:37 pm

Re: Help with WML for a particular scenario

Post by chak_abhi »

zookeeper wrote:
chak_abhi wrote:As a desperate resort I had even considered uploading my campaign as it is now on this forum so that a genuinely helpful person may correct it, but have decided against it as it may not be permitted, and I have already been rebuked by the forum moderators once in this forum itself!
What? :annoyed:

No, that's exactly what you need to do if you want anyone to help you.
Well, if its so then here it is. Hope for the best that someone can solve my problems in an efficient manner.
Attachments
Rebellion_in_the_North.gz.zip
(908.5 KiB) Downloaded 380 times
Ceres
Forum Regular
Posts: 620
Joined: September 18th, 2010, 7:56 pm
Location: Germany

Re: Help with WML for a particular scenario

Post by Ceres »

You have a spelling mistake in your map path:

Code: Select all

~add-ons/Rebellion_in_the_north/maps/01_Unexpected_Attack.map
should be

Code: Select all

~add-ons/Rebellion_in_the_North/maps/01_Unexpected_Attack.map
This causes the 'macro ... is missing at ...' error.

Edit: This, and the (almost unoticable) fact, that in your map name is a whitespace. Remove it, and it should work fine.
Last edited by Ceres on December 23rd, 2010, 5:23 pm, edited 1 time in total.
Post Reply