Specifying locations of binary files

Discussion and development of scenarios and campaigns for the game.

Moderator: Forum Moderators

Post Reply
Dave
Founding Developer
Posts: 7071
Joined: August 17th, 2003, 5:07 am
Location: Seattle
Contact:

Specifying locations of binary files

Post by Dave »

In order to allow campaign developers to provide entire campaigns that go under a single directory, I've added a new feature to WML which allows specification of a path to look for binary files.

At the top level, you can add a tag as follows:

Code: Select all

[binary_path]
path=data/mycampaign/binary
[/binary_path]
Then, whenever Wesnoth loads images, it will look in the directories

[wesnoth-path]/data/mycampaign/binary/images/
$HOME/.wesnoth/data/mycampaign/binary/images/ (or equivalent on non-Unix systems)

Likewise, when looking for sound effects, it will look in the directories

[wesnoth-path]/data/mycampaign/binary/sounds/
$HOME/.wesnoth/data/mycampaign/binary/sounds/ (or equivalent on non-Unix systems)

This should enable campaign makers to package their entire campaign below one directory.

David
“At Gambling, the deadly sin is to mistake bad play for bad luck.” -- Ian Fleming
jzaun
Posts: 45
Joined: October 24th, 2003, 7:06 pm
Location: Waikiki, HI
Contact:

Post by jzaun »

Very nice, thank you!
jzaun
-- Justin Zaun (jzaun)
User avatar
Jetrel
Posts: 7242
Joined: February 23rd, 2004, 3:36 am
Location: Midwest US

Post by Jetrel »

:shock: surprisingly simple.

I assume you mean this goes in the primary campaign.cfg file, or simply in the campaign directory?
Post Reply