Restricting event messages to side(s)

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.

Restricting event messages to side(s)

Postby Ironcladkitty » September 3rd, 2017, 12:58 am

Hi!

In a little scenario I'm making, I have 5 sides. Each of these 5 sides starts with its own 'intro', a short briefing/conversation between units.

Unfortunately, I cannot make it so that each side views only its own intro - all 5 intros are shown for all 5 players. How can I enforce the game to show Side 1 (and so on) the intro for Side 1 but do not display the intros for other sides?

I've tried using various filters, but nothing is working so far...
All my love for Wesnoth! (And Dwarf Fortress, and Fire Emblem, and...)
===
~♪♫~ o/,, %o ♂o √o φo ♂o %o ~♫♪~
User avatar
Ironcladkitty
 
Posts: 10
Joined: June 10th, 2014, 6:38 pm

Re: Restricting event messages to side(s)

Postby doofus-01 » September 3rd, 2017, 1:13 am

I don't know if it is possible or not, I've never tried, but [story] and [part] supposedly take filters, so it might be possible if you can determine the viewing side somehow.

What have you tried so far?
BfW 1.12 supported, but active development only for BfW 1.13/1.14: Bad Moon Rising | Trinity | Archaic Era |
| Abandoned: Tales of the Setting Sun
GitHub link for these projects
User avatar
doofus-01
Art Contributor
 
Posts: 3540
Joined: January 6th, 2008, 9:27 pm
Location: USA ...

Re: Restricting event messages to side(s)

Postby ForestDragon » September 3rd, 2017, 5:03 am

I think this should work for you: put this in the 'prestart' event:
Code: Select all
    [color_adjust]
        red=-512
        green=-512
        blue=-512
    [/color_adjust]
then make multiple messages, each with 'side_for=insert your side number here'. this approach will make images show at the bottom, though, instead of on the top.
often helping inferno8 with his add-ons: Era of Magic, and an extremely visually advaned campaign: To Lands Unknown
Creator of Tale of Alan (abandoned) and The Golden Age (my era, also rather abandoned),XP Bank
"Join the code side, we have COOKIES!!!" :)
User avatar
ForestDragon
 
Posts: 1170
Joined: March 6th, 2014, 1:32 pm

Re: Restricting event messages to side(s)

Postby Ironcladkitty » September 3rd, 2017, 8:00 am

D'oh, side_for= is just what I needed. Thanks for help guys!
All my love for Wesnoth! (And Dwarf Fortress, and Fire Emblem, and...)
===
~♪♫~ o/,, %o ♂o √o φo ♂o %o ~♫♪~
User avatar
Ironcladkitty
 
Posts: 10
Joined: June 10th, 2014, 6:38 pm


Return to WML Workshop

Who is online

Users browsing this forum: No registered users and 4 guests