Select event selectivity

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.

Select event selectivity

Postby Choicerer » December 11th, 2017, 7:14 pm

Is there ANY way to make a label/printed text/lua message fired from inside a select event visible to all players in multiplayer? I've tried firing another custom event from within the select event, doesn't work.
Creator of The Better Names Mod - viewtopic.php?f=15&t=47658
Curse of Satan Claus - viewtopic.php?f=15&t=47692
Randomized Isar's Cross Map Pack - viewtopic.php?f=15&t=46767
And the Mushroom Isar Map Pack.
Choicerer
 
Posts: 75
Joined: April 29th, 2017, 11:37 pm

Re: Select event selectivity

Postby Ravana » December 11th, 2017, 7:18 pm

Entire purpose of select event is to do unsynced changes. So if you want something synced happen, you have no reason to use select in the first place.
User avatar
Ravana
Moderator
 
Posts: 1512
Joined: January 29th, 2012, 12:49 am
Location: Estonia

Re: Select event selectivity

Postby Choicerer » December 11th, 2017, 7:21 pm

Hmm. Well, it so happens that I do. I want to display a message to all players in the game if a player accesses an info menu while it's their turn. The menu is accessed by clicking a unit. What about wesnoth.show_dialog? I've already had problems with that showing up for everyone if a player selected a right-click menu custom option.
Creator of The Better Names Mod - viewtopic.php?f=15&t=47658
Curse of Satan Claus - viewtopic.php?f=15&t=47692
Randomized Isar's Cross Map Pack - viewtopic.php?f=15&t=46767
And the Mushroom Isar Map Pack.
Choicerer
 
Posts: 75
Joined: April 29th, 2017, 11:37 pm

Re: Select event selectivity

Postby Ravana » December 11th, 2017, 7:23 pm

Menu option should need delay or redraw call.
User avatar
Ravana
Moderator
 
Posts: 1512
Joined: January 29th, 2012, 12:49 am
Location: Estonia

Re: Select event selectivity

Postby Choicerer » December 11th, 2017, 7:27 pm

I'm not sure I understand... You mean that about the second problem?
Creator of The Better Names Mod - viewtopic.php?f=15&t=47658
Curse of Satan Claus - viewtopic.php?f=15&t=47692
Randomized Isar's Cross Map Pack - viewtopic.php?f=15&t=46767
And the Mushroom Isar Map Pack.
Choicerer
 
Posts: 75
Joined: April 29th, 2017, 11:37 pm

Re: Select event selectivity

Postby Ravana » December 11th, 2017, 7:35 pm

Yes.
User avatar
Ravana
Moderator
 
Posts: 1512
Joined: January 29th, 2012, 12:49 am
Location: Estonia

Re: Select event selectivity

Postby Choicerer » December 11th, 2017, 7:41 pm

Ok. And the lua wesnoth.show_dialog function would fail to show the dialog to all players as well if fired from a select event?
Creator of The Better Names Mod - viewtopic.php?f=15&t=47658
Curse of Satan Claus - viewtopic.php?f=15&t=47692
Randomized Isar's Cross Map Pack - viewtopic.php?f=15&t=46767
And the Mushroom Isar Map Pack.
Choicerer
 
Posts: 75
Joined: April 29th, 2017, 11:37 pm

Re: Select event selectivity

Postby Ravana » December 11th, 2017, 7:52 pm

Yes, select is unsynced.
User avatar
Ravana
Moderator
 
Posts: 1512
Joined: January 29th, 2012, 12:49 am
Location: Estonia

Re: Select event selectivity

Postby Choicerer » December 11th, 2017, 7:54 pm

Okay, thank you!
Creator of The Better Names Mod - viewtopic.php?f=15&t=47658
Curse of Satan Claus - viewtopic.php?f=15&t=47692
Randomized Isar's Cross Map Pack - viewtopic.php?f=15&t=46767
And the Mushroom Isar Map Pack.
Choicerer
 
Posts: 75
Joined: April 29th, 2017, 11:37 pm


Return to WML Workshop

Who is online

Users browsing this forum: beetlenaut, Enderlook, holius and 3 guests