Two Objectives

The place to post your WML questions and answers.

Moderator: Forum Moderators

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.
Post Reply
tribes45
Posts: 123
Joined: June 24th, 2010, 12:40 am

Two Objectives

Post by tribes45 »

I've come across an scenario I would like to have two objectives in. I've tried a nested event, but this doesn't act as objectives. Does anyone know how to do this?
What I wanted to do what, you had to kill a enemy leader, and go to a certain hex. The nested event didn't work, so I ask for your help.
Spoiler:
"In peace, sons bury their fathers. In war, fathers bury their sons." -Herodotus
"Two things are infinite, the universe and Human stupidity. Although, I'm not sure about the universe. -Albert Einstein
User avatar
Adamant14
Posts: 968
Joined: April 24th, 2010, 1:14 pm

Re: Two Objectives

Post by Adamant14 »

:hmm:

And what exactly doesn't work?

I play-tested it right now.
I killed Feladoryn, then I moved to x,y=4,20, and Delfaldor came out,
It work's perfect for me.
Author of Antar, Son of Rheor ( SP Campaign) | Development Thread + Feedback Thread + Replays of ASoR
tribes45
Posts: 123
Joined: June 24th, 2010, 12:40 am

Re: Two Objectives

Post by tribes45 »

But then it's supposed to end the level.
"In peace, sons bury their fathers. In war, fathers bury their sons." -Herodotus
"Two things are infinite, the universe and Human stupidity. Although, I'm not sure about the universe. -Albert Einstein
User avatar
Crendgrim
Moderator Emeritus
Posts: 1328
Joined: October 15th, 2010, 10:39 am
Location: Germany

Re: Two Objectives

Post by Crendgrim »

[wiki=DirectActionsWML#.5Bendlevel.5D][endlevel][/wiki]
UMC Story Images — Story images for your campaign!
tribes45
Posts: 123
Joined: June 24th, 2010, 12:40 am

Re: Two Objectives

Post by tribes45 »

Oh silly me, forgot toadd that.
"In peace, sons bury their fathers. In war, fathers bury their sons." -Herodotus
"Two things are infinite, the universe and Human stupidity. Although, I'm not sure about the universe. -Albert Einstein
tribes45
Posts: 123
Joined: June 24th, 2010, 12:40 am

Re: Two Objectives

Post by tribes45 »

It still doesn't take both of those objectives to end the game, they only have to do one.
Help please.
"In peace, sons bury their fathers. In war, fathers bury their sons." -Herodotus
"Two things are infinite, the universe and Human stupidity. Although, I'm not sure about the universe. -Albert Einstein
User avatar
pyrophorus
Posts: 533
Joined: December 1st, 2010, 12:54 pm

Re: Two Objectives

Post by pyrophorus »

Hi,
To do that you can:
- define a variable {VARIABLE cond 0}
- have two distinct events 'die' and 'moveto'
- in each, test the cond variable content:
- if not equals 1, add 1 to it
- if equals to 1 -> endlevel
This way, you must trigger the two events to end the game (I supposed the two events are first_time_only=yes)
HTH,
tribes45
Posts: 123
Joined: June 24th, 2010, 12:40 am

Re: Two Objectives

Post by tribes45 »

pyrophorus wrote:Hi,
To do that you can:
- define a variable {VARIABLE cond 0}
- have two distinct events 'die' and 'moveto'
- in each, test the cond variable content:
- if not equals 1, add 1 to it
- if equals to 1 -> endlevel
This way, you must trigger the two events to end the game (I supposed the two events are first_time_only=yes)
HTH,
This worked, thanks.
"In peace, sons bury their fathers. In war, fathers bury their sons." -Herodotus
"Two things are infinite, the universe and Human stupidity. Although, I'm not sure about the universe. -Albert Einstein
Post Reply