Valeria MP Adventure

Discussion and development of scenarios and campaigns for the game.

Moderator: Forum Moderators

Post Reply
User avatar
LordAwsomeness
Posts: 203
Joined: August 12th, 2013, 2:20 pm
Location: U.S.A.

Valeria MP Adventure

Post by LordAwsomeness »

Greetings! I was going to hold off on creating this thread until I was in the alpha stages of my scenario since it has not even been uploaded yet, however I have been asking questions on a lot of different threads and I wish to centralize more of my efforts into one place.

Valeria is my attempt at an adventure map for 3 players. The map is set to be a huge (like 160x120 huge, and I am planning on expanding it a tad further) free-roam map (similar to The Brotherhood of light) with a bottleneck style of pathing to guide players in general directions once they have chosen a route, but ultimately leaving it up to the players to make their own choices. The scenario is being developed to be played with Bob's RPG Era, however I am considering alternative ideas since Bob's RPG Era has yet to be updated to 1.14.

The scenario will (and already does) feature many puzzles to be discovered and solved as well as a hopefully in-depth storyline. Currently this is all still in development, and I am qeustioning how to encourage players to stick together (since it is open, it lacks parameters to force players to stay as a squad).

Please give any insight that you have! Thanks! :D
- Been playing Wesnoth since 2004 and the 1.0.x versions.
- Creator of Undead Invasion MP Scenario Pack.
- Creator of Valeria MP Adventure
- Creator of LA_RPG ERA
Konrad2
Forum Moderator
Posts: 3340
Joined: November 24th, 2010, 6:30 pm

Re: Valeria MP Adventure

Post by Konrad2 »

How about making the activation/solving of the puzzles or triggering of events at all dependent on having all players at/around the location. Like, if not everyone is there you only get a message that somethings might be here, but you can only investigate if everyone is there.
User avatar
LordAwsomeness
Posts: 203
Joined: August 12th, 2013, 2:20 pm
Location: U.S.A.

Re: Valeria MP Adventure

Post by LordAwsomeness »

How would you even be able to set up a filter for that? I rarely use filter_location syntax. I just never researched it.
- Been playing Wesnoth since 2004 and the 1.0.x versions.
- Creator of Undead Invasion MP Scenario Pack.
- Creator of Valeria MP Adventure
- Creator of LA_RPG ERA
User avatar
LordAwsomeness
Posts: 203
Joined: August 12th, 2013, 2:20 pm
Location: U.S.A.

Re: Valeria MP Adventure

Post by LordAwsomeness »

I'm sure this is wrong, but would it look something like:

Code: Select all

[event]
	name=moveto
	
[if]
[have_unit]
	[filter]
		x,y=(INSERT X),(INSERT Y)
		side=1,2,3
		canrecruit=yes
	[/filter]
[/have_unit]

[and]
[have_unit]
	[filter]
		x,y=(INSERT X),(INSERT Y)
		side=1,2,3
		canrecruit=yes
		[filter_adjacent_location]
			count=4
		[/filter_adjacent_location]
	[/filter]
[have_unit]
[/and]

[then]
(WML)
[/then]
[/if]

[/event]

- Been playing Wesnoth since 2004 and the 1.0.x versions.
- Creator of Undead Invasion MP Scenario Pack.
- Creator of Valeria MP Adventure
- Creator of LA_RPG ERA
Konrad2
Forum Moderator
Posts: 3340
Joined: November 24th, 2010, 6:30 pm

Re: Valeria MP Adventure

Post by Konrad2 »

Sorry, I'm not well versed in matters of code. :D I can at most supply ideas as to what the code should do.

EDIT:
Maybe it's possible to check for a unit ID?
User avatar
LordAwsomeness
Posts: 203
Joined: August 12th, 2013, 2:20 pm
Location: U.S.A.

Re: Valeria MP Adventure

Post by LordAwsomeness »

I could substitute the canrecruit=yes for the id, however I'm sure the actual issue will be with the have_unit or something being out of place. I'll look more into it once I have fleshed out more of the gameplay. Right now I'm more interested on finishing the map :doh:
- Been playing Wesnoth since 2004 and the 1.0.x versions.
- Creator of Undead Invasion MP Scenario Pack.
- Creator of Valeria MP Adventure
- Creator of LA_RPG ERA
User avatar
LordAwsomeness
Posts: 203
Joined: August 12th, 2013, 2:20 pm
Location: U.S.A.

Re: Valeria MP Adventure

Post by LordAwsomeness »

As of right now though, I am having huge issues with achieving getting this to work:

Code: Select all


#define VALERIA_STARTING_ANIMATION SIDE
[event]
name=start
{VARIABLE start_finished no}


	[store_unit]
		[filter]
			side={SIDE}
			canrecruit=yes
		[/filter]
		variable=hero_spawn[{SIDE}]
	[/store_unit]
	
	[store_starting_location]
		[filter]
			side={SIDE}
			canrecruit=yes
		[/filter]
		variable=hero_location[{SIDE}]
	[/store_starting_location]

{VARIABLE hero[{SIDE}]_x_loc $hero_location[{SIDE}].x}
{VARIABLE hero[{SIDE}]_y_loc $hero_location[{SIDE}].y}

[hide_unit]
#		x,y=$hero_spawn[{SIDE}].x,$hero_spawn[{SIDE}].y
		side={SIDE}
		canrecruit=yes
[/hide_unit]


#{VARIABLE_OP hero[{SIDE}]_x_loc add -1}
#{VARIABLE_OP hero[{SIDE}]_y_loc add -1}

	{TELEPORT_TILE $hero_location[{SIDE}].x $hero_location[{SIDE}].y 1 2}


#{TELEPORT_UNIT () X Y}

[unit]
type=Fencer
x,y=$hero_spawn[{SIDE}].x,$hero_spawn[{SIDE}].y
side={SIDE}
id=player_spawn[{SIDE}]
[/unit]

	[delay]
		time=2000
	[/delay]
	
[kill]
side={SIDE}
id=player_spawn[{SIDE}]
type=Fencer
animate=yes
[/kill]

	{TELEPORT_TILE 1 2 $hero_location[{SIDE}].x $hero_location[{SIDE}].y}


[unhide_unit]
#		x,y=$hero_spawn.x,$hero_spawn.y
		side={SIDE}
		canrecruit=yes
[/unhide_unit]

[/event]
#enddef
It was supposed to be very simple, and I am not sure where the problem keeps arising; but the variables seem to not be creating. Since it is in a 'event' syntax, it was supposed to be dropped down in the scenario top-level with 0 issues. It works to a certain point, but whenever I try to use the {TELEPORT... I run into issues. Nothing game breaking. The macro just stops working and the game carries on. Some lua error gets displayed in the debug text. If Anybody has a fix, please let me know. This was supposed to be a 1 hour venture at most; but I've been hung up on it for 5 or 6 hours now and I'm losing my mind over it... (And yes I recognize that I have several things under the #, most of those are the areas I am finding issues with or like the 'hide_unit'-'unhide_unit' I have just not implemented yet...
Last edited by LordAwsomeness on May 7th, 2018, 2:16 am, edited 3 times in total.
- Been playing Wesnoth since 2004 and the 1.0.x versions.
- Creator of Undead Invasion MP Scenario Pack.
- Creator of Valeria MP Adventure
- Creator of LA_RPG ERA
User avatar
LordAwsomeness
Posts: 203
Joined: August 12th, 2013, 2:20 pm
Location: U.S.A.

Re: Valeria MP Adventure

Post by LordAwsomeness »

I even tried a much simpler form of it, and yet it was even worse!!! The unit will not even spawn! I am boggled by this. I have no idea why this isn't working... It should be so simple...

Code: Select all

#define VALERIA_STARTING_ANIMATION SIDE X1 Y1 X2 Y2
[event]
name=start

[hide_unit]
	x,y={X1},{Y1}
	side={SIDE}
	canrecruit=yes
[/hide_unit]

#	{TELEPORT_TILE {X1} {Y1} {X2} {Y2}}
{TELEPORT_UNIT (side={SIDE} canrecruit=yes) {X2} {Y2}}

[unit]
type=Fencer
x,y={X1},{Y1}
side={SIDE}
id=player_spawn[{SIDE}]
[/unit]

	[delay]
		time=2000
	[/delay]
	
[kill]
side={SIDE}
id=player_spawn[{SIDE}]
#type=Fencer
animate=yes
[/kill]

#	{TELEPORT_TILE {X2} {Y2} {X1} {Y1}}
{TELEPORT_UNIT (side={SIDE} canrecruit=yes) {X1} {Y1}}

[unhide_unit]
	x,y={X1},{Y1}
	side={SIDE}
	canrecruit=yes
[/unhide_unit]
[/event]
#enddef
- Been playing Wesnoth since 2004 and the 1.0.x versions.
- Creator of Undead Invasion MP Scenario Pack.
- Creator of Valeria MP Adventure
- Creator of LA_RPG ERA
Konrad2
Forum Moderator
Posts: 3340
Joined: November 24th, 2010, 6:30 pm

Re: Valeria MP Adventure

Post by Konrad2 »

Look, some advice for you.
Avoid double posts. Edit your posts instead.
And use the WML workshop to ask questions about WML. The poeple using that part of the forum know what they are doing unlinke me and you.
enclave
Posts: 936
Joined: December 15th, 2007, 8:52 am

Re: Valeria MP Adventure

Post by enclave »

LordAwsomeness wrote: May 7th, 2018, 2:12 am As of right now though, I am having huge issues with achieving getting this to work:

Code: Select all

{VARIABLE hero[{SIDE}]_x_loc $hero_location[{SIDE}].x}
{VARIABLE hero[{SIDE}]_y_loc $hero_location[{SIDE}].y}
#{VARIABLE_OP hero[{SIDE}]_x_loc add -1}
#{VARIABLE_OP hero[{SIDE}]_y_loc add -1}
To start with I would try to edit this... I would be surprized if this is working correct the way it is... and I wonder if it doesnt give you any errors..
hero[{SIDE}]_y_loc
this looks very not normal to me... it is a mix of an array and a variable?
Try change it to either array hero[{SIDE}].y_loc
Or a variable hero_{SIDE}_y_loc
If this didn't help then I will have more ideas, because I see other suspects inside the code... :)
Also best way to do if something doesn't work is to add [message] message=$hero[{SIDE}]_y_loc [/message] so you will see with your own eyes if your variables are working properly and have the values that you want them to have...
Another good way apart from message is to type a command while in game
:debug
and then
:inspect
Inside the inspect you will be able to see all your variables and check if they match your idea of what they should be.

Good luck;)
Post Reply