Random Campaign 1.5.0 for Wesnoth 1.17/1.18 Beta

Discussion and development of scenarios and campaigns for the game.

Moderator: Forum Moderators

Ardnell
Posts: 1
Joined: July 9th, 2013, 11:23 am

Re: Random Campaign 1.0.0 for Wesnoth 1.10

Post by Ardnell »

Hey

First post. Not sure if this is the right place for this but I'll give it a shot.

I'm having some trouble with the Random Campaign. Whenever I or the AI plays Khalifate faction, none of the units are able to move. If I create a default Local Game and pick Khalifate, they can move just fine. In lieu of a fix for this, I wish I could just play the Random Campaign without any random chance of Khalifate. Is there any way I can fix this or create a workaround?

BTW I love your random maps. Keep up the good work!
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.0.0 for Wesnoth 1.10

Post by SigurdFireDragon »

Welcome to the forums. :)

Yes, this was the right place to post.

I found the problem you described & it's fixable. I should have a updated version with a proper fix out later this week.

A quick workaround would be to open the file
userdata/data/add-ons/Random_Campaign/utils_sp/_sides.cfg
go to line 181 and replace 'Khalifate' with one of the other faction names listed on that line (whichever one you wouldn't mind facing twice)

Thanks :)
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.0.1 for Wesnoth 1.10

Post by SigurdFireDragon »

Version 1.0.1 is up. :)

Bug with Khalifate unable to move in sp version fixed.

Thanks again for the report, Ardnell. :)
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.1.0 for Wesnoth 1.11/12

Post by SigurdFireDragon »

Version 1.1.0 for Wesnoth 1.11/12 is up. :D
Requires Wesnoth 1.11.10 or greater

Lots of changes:

Description for Wesnoth 1.11/12
A one player multiplayer campaign.
Select an era, choose your faction, and lead it to victory against random factions over a series of random maps. For the standard experience, choose the Random Campaign Default era.
(Intermediate level, 7 scenarios.)

The campaign is balanced for being played with 'use map settings', though any setting on the Configure Game screen can be changed, and will take effect throughout the campaign.

The following unit advancement defines are enabled in this campaign: Ancient Lich, Armageddon Drake, Dwarvish Arcanister, & Orcish High Warlord.

Any Default or Age of Heroes style era can be selected. If an Age of Heroes style era is selected, the campaign will start at scenario 4. It's recommended to use normal eras (i.e. eras that are just collections of factions). If the era contains events or other game play mechanics, unexpected results or incompatibilities may occur.

Modifications may or may not work with this add-on, use at own risk. However, there is special cross-functionality with Custom Campaign. Upon finishing Random Campaign, your army will be saved for use in Custom Campaign, even if you don't have it. If the Custom Campaign modification is used when starting Random Campaign, it will allow you to select one of your armies for the campaign.

Requires BfW 1.11.10 or greater. Requires the latest versions of 'Era of Legends' & 'Ultimate Random Maps' to be installed.

For those familiar with the 1.10 version, here is a summary of the changes.
1. The SP version moved to MP, ate the 1-player 4 scenario version, and incorporated new features.
2. The update recruit that occurred in scenario 6 was removed for consistency & simplification.
3. Leaders no longer get the heroic trait, instead they get powerful (+20% to all attacks) & intelligent. If they only have 4mp, they get quick as well. This was done to make factions play more in line with mp use by eliminating the possibility of 7mp leaders, while still giving the leaders something special, because it is a campaign.
4. Selecting a side color will take effect throughout the campaign, and will also give the computer side a predetermined color to contrast the player’s chose color (i.e. red & blue, green & purple, black & white, etc.)
5. The start menu that was present in the 1.10 SP version has been removed. Everything but leader naming is now done through the standard multiplayer create game dialogs.
6. Leaders are automatically given a random name if applicable, otherwise no name. The name can be changed during the scenario.
7. Fixed a bug that would occasionally deliver empty dialog.
8. The added RC Default & Heroes eras implement the SP campaign ability to select the Dwarvish Runsmith line as a leader.
9. The 3-player 4 scenario version was dropped. Reasons:
a. I currently don't want to spend the time to update & incorporate it with the 1-player version.
b. I'm not convinced anyone actually used it.
c. It's hard to support a feature I've never used.
d. It may return in the future.

The full svn changlog omitted, because it’s a rambling mess. :P

Thanks to the dev team for the various new features in 1.11/12 that made some of the new aspects of this add-on possible, and for their continuing work on Wesnoth. :)
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
Battlecruiser_Venca
Posts: 196
Joined: June 3rd, 2009, 11:37 am
Contact:

Re: Random Campaign 1.1.0 for Wesnoth 1.11/12

Post by Battlecruiser_Venca »

Got a crashing bug. As UMC shouldn't crash wesnoth, reported here: https://gna.org/bugs/index.php?21865
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.1.0 for Wesnoth 1.11/12

Post by SigurdFireDragon »

A bug I should have mentioned:

https://gna.org/bugs/index.php?21865 is related to https://gna.org/bugs/index.php?20895

note the comment on #20895 from Sun 02 Feb 2014 03:22:17 AM UTC, comment #7:

Start of Scenario saves for Random Campaign do not work because of it.
I recommend making manual saves at turn 1 or setting auto-save parameters high enough (over 30 turns, and not deleting them on completion of the level.)

EDIT:
Also note that using Menu->Back To Turn can cause problems, be sure to load through the Multiplayer dialog as the message suggests.

2ND EDIT:
Version 1.1.1 uploaded.
This version adds the following text to add-on server & campaign descriptions:
"Important Note: Due to a bug, 'Scenario Start' saves for this campaign are broken. It is recommend to make a manual saves on each map, or set 'maximum auto-saves' high enough with 'delete auto-saves at the end of scenarios' turned off."
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
AI
Developer
Posts: 2396
Joined: January 31st, 2008, 8:38 pm

Re: Random Campaign 1.1.0 for Wesnoth 1.11/12

Post by AI »

The wescamp script (which extracts the translatable strings from your campaign, as you've set translatable to true in your PBL file), gives the following output:

Code: Select all

[WARNING 2014-04-11 13:09:48,097]
init-build-sys.sh in add-on Random_Campaign:
expected closed node 'u' got 'lua' at ./Random_Campaign/utils_sp/_sides.cfg:207 at /home/ai/bin/wmlxgettext line 179, <FILE> line 207.
non-empty node stack at end of ./Random_Campaign/utils_sp/_sides.cfg at /home/ai/bin/wmlxgettext line 203, <FILE> line 370.
WML seems invalid for ./Random_Campaign/utils_sp/_sides.cfg, node info extraction forfeited past the error point at /home/ai/bin/wmlxgettext line 210.
expected closed node 'i' got 'lua' at ./Random_Campaign/utils_mp/_sides_mp.cfg:69 at /home/ai/bin/wmlxgettext line 179, <FILE> line 69.
non-empty node stack at end of ./Random_Campaign/utils_mp/_sides_mp.cfg at /home/ai/bin/wmlxgettext line 203, <FILE> line 655.
WML seems invalid for ./Random_Campaign/utils_mp/_sides_mp.cfg, node info extraction forfeited past the error point at /home/ai/bin/wmlxgettext line 210.
Both are due to embedded lua code, which wmlxgettext doesn' t handle very well. (it has a lua mode for .lua files, but it's unable to switch between modes in a single file)
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.1.1 for Wesnoth 1.11/12

Post by SigurdFireDragon »

AI wrote:Both are due to embedded lua code, which wmlxgettext doesn' t handle very well. (it has a lua mode for .lua files, but it's unable to switch between modes in a single file)
Does that mean any embedded lua, or just lua marked for translation with '_' ?
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
AI
Developer
Posts: 2396
Joined: January 31st, 2008, 8:38 pm

Re: Random Campaign 1.1.1 for Wesnoth 1.11/12

Post by AI »

Well, the issue is that lua uses [] characters for very different purposes than WML does. If there are no translatable strings in the lua though, and no translatable strings in the WML following the lua, the errors are mostly cosmetic. (I will still complain to you though ;))
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.1.2 for Wesnoth 1.11/12

Post by SigurdFireDragon »

Version 1.1.2 is up

This is just a code cleanup & adding/making it more translation friendly update.
Hopefully this should satisfy wmlxgettext.
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
AI
Developer
Posts: 2396
Joined: January 31st, 2008, 8:38 pm

Re: Random Campaign 1.1.2 for Wesnoth 1.11/12

Post by AI »

Looks fixed:

Code: Select all

[INFO] New version of addon 'Random_Campaign' uploaded.
[INFO] Checking if build system for add-on Random_Campaign needs to be updated
[INFO] Build system for add-on Random_Campaign is up-to-date
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.2.0 for Wesnoth 1.11/12

Post by SigurdFireDragon »

Version 1.2.0 for BfW 1.11/12 is up. :D
Requires BfW 1.11.15 or greater.

Changes:
Added Start gold % & Base income % option sliders for the campaign. These adjustments will take place in every scenario of the campaign for each side. Along with standard multiplayer sliders/options., they complete the set to make the campaign play bigger or smaller as desired.
allow_difficulty_change=no, due to how campaign gold & income sliders work.
Defeat no longer shows the map if fog or shroud is enabled for the campaign.
Gold carryover behavior specified in each scenario's objectives
Last scenario stated in it's objectives.
Carryover report suppressed in last scenario to match convention.
Enemy faction is now chosen in previous scenario when the map is chosen.
Team names are now 'Player' and 'Enemy' on the status table.
Version:/Author: in description to better match convention.
Lots of cleanup of the code for simplification, readability, debugging, & convention.

These changes mean that campaigns started with the previous version of Random Campaign will not be compatible. If you need the previous version (1.1.2), it's attached below.

Thanks AI, for all the info about translations.
Attachments
Random_Campaign 1.1.2.zip
(1.93 MiB) Downloaded 368 times
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.2.1 for Wesnoth 1.11/12

Post by SigurdFireDragon »

Version 1.2.1 is up. Requires BfW 1.11.15 or greater.
I intend for this to be the last significant update in the 1.11/1.12 BfW series. For real. :P

Versions of Random Campaign prior to 1.2.1 will not work on BfW 1.11.17 and above.
Saves made with Random Campaign versions 1.2.0 and below won’t work with 1.2.1.
If you updated to 1.2.1 and need to finish a previous campaign, version 1.2.0 is attached below.

New features:
Added a new map set & the ability to select between the two map sets for the campaign.
The two sets are:
Random – The standard set of 9 random maps taken from Ultimate Random Maps (Previously the only set available.)
Fixed – All of the 2 player maps in mainline, with the following exceptions:
Dark Forecast omitted because it’s a survival scenario, and too small a map.
Due to their larger size, Arcanclave Citadel, Cynsaun Battlefield, & Fallenstar Lake are only available in the Fixed map pool when turns is set to unlimited at the start of the campaign.
Also, Difficulty Level changing has been re-enabled.

Bugfixes:
Fixed an error in difficulty gold progression on Nightmare level 3.
Retooled how scenario gold & income is set. (With BfW 1.11.17 there will be no player visible changes, scenario start table slightly inaccurate on lower BfW versions.)
Greatly simplified the scenario code.
Attachments
Random_Campaign 1.2.0.zip
(1.92 MiB) Downloaded 343 times
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
SigurdFireDragon
Developer
Posts: 545
Joined: January 12th, 2011, 2:18 am
Location: Pennsylvania, USA

Re: Random Campaign 1.2.2 for Wesnoth 1.11/12

Post by SigurdFireDragon »

Version 1.2.2 is up.

Bugfix:
Workaround for a minor bug introduced in BfW 1.11.17 when using the randomly generated map set that would cause it to be highly likely that the player's recruit list would get recruits from other factions added to it in a campaign setting. (I'll report it on gna! eventually.)

Change:
Leaders no longer get the intelligent trait, as that would allow leaders to level too easily when using XP settings less than 100%. (ie, 70% like an mp match.)
Co-Author of Winds of Fate
My Add-ons: Random Campaign, Custom Campaign, Ultimate Random Maps, Era of Legends, Gui Debug Tools
Erfworld: The comic that lead me to find Wesnoth.
User avatar
Enchanteur
Posts: 72
Joined: September 28th, 2009, 11:05 am

Re: Random Campaign 1.2.2 for Wesnoth 1.11/12

Post by Enchanteur »

Hello, I tried the mod.
I can play and generate maps.
But loading time is quite long.
I saved my game turn 1 as explained above.
When I load the saved game, there is a bug.
Game say "ON_DIFFICULTY4" is missing.

I really like the idea of a random campaign. But as wishlist, is there a way to choose more era, and set the number of scenarios ? Let's say it could be funny to play a random campaign of 20 scenarios.
Cheers.

EDIT : the loading bug happens only when loading a save from the inside game.
But it's possible to load a game without bug in starting multiplayer screen !
French Player. For now, I'm working on creation of abilitys and units with WML. My goal is to make an enhanced version of Elves, playable with standard campains. HERE : http://forums.wesnoth.org/viewtopic.php ... 58&start=0
Post Reply