You must be logged in to post messages.
Please login or register

Scenario Design
Moderated by Yeebaagooon, nottud

Hop to:    
loginhomeregisterhelprules
Bottom
Topic Subject: Anyone have any ideas on passing information between scenarios?
« Previous Page  1 2  Next Page »
posted 03 May 2008 08:45 PM EDT (US)   
Hello. I've been thinking for a while about this. If you have a campaign or something, what ways can you use to pass information between different scenarios? For example, I'd like the player to finish one scenario in the campaign, and then start the next scenario with the amount of resources he finished with in the previous map. Can anyone think of a way to do this?

My only idea would be to give the player a code to enter when the next scenario starts, which is in some way mathematically related to the values to input.

Thor Odinson
AoM Scenario and RMS Designer

"The individual has always had to struggle to keep from being overwhelmed by the tribe. If you try it, you will be lonely often, and sometimes frightened. But no price is too high to pay for the privilege of owning yourself."
-Friedrich Nietzsche
Replies:
posted 03 May 2008 09:03 PM EDT (US)     1 / 36  
I recall that someone had a solution for this.

No real ideas of my own though.

Hey I know you!

Without A Doubt, The Most Known Person In The World (Metaphorically Speaking)

Latest Scenario: I Am Bear - The Cinematic (4.4)
A Sequel to the Titans Campaign: Rise of the World Power
posted 03 May 2008 09:42 PM EDT (US)     2 / 36  
2 possible ideas. One involves honesty, and the other inaccuracy.

1)In order to have a code they enter, you could have quite a number of triggers like this:
Trigger 1:
Conditions:
Chat Contains (Code from Player 1)
Effects:
Grant Resources (1000 wood to Player 1)
Disable trigger (Trigger 2)
Disable trigger (Trigger 3)
etc.
fire event (Same trigger for gold)

This would only be accurate to whatever you set it to, and the lower it is set, the more triggers needed.

2)Have a sort of shop set up in which they move their old man to determine the 1,000 100 10 and 1 values for each resource. you would only need 1 shop type thing set up with 10 places. the man would just be deleted when the amount is selected.

I hope either, or both of these suggestions help you.

Released maps: Soccer Battle
Works in Progress: Monkey RPG(Not real name) - Storyline being planned
posted 04 May 2008 03:17 AM EDT (US)     3 / 36  
The best way I know is to use a config but that is advanced.

I believe that it is possible to run some comands on the new scenario from the old one providing it is an effect AFTER the load scenario effect in the same trigger.

The boy with the mad imagination
Prepare for the ultimate duel!
Learn to use all my triggers and what you can do with them. Visit here.
Find out and download the transform trigger here.
Play some minigames I have created outside AOM including some 3D games here.
posted 04 May 2008 03:35 AM EDT (US)     4 / 36  
Maybe just make a big map, and delete units on part of it and set that part to Black map? It would solve a lot of problems.

¨‘°ºO Oº°‘¨_.,-=~+"^'`*`'^"+~=-,._Hygraffo_.,-=~+"^'`*`'^"+~=-,._¨‘°ºO Oº°‘¨
׺°˜`°º×-=»«=-I am a ninja-=»«=-׺°˜`°º×
Home of the quoted
Reaaly I am in a Chinese nuclear sub- JDmino
Meh- Baske
posted 04 May 2008 04:35 AM EDT (US)     5 / 36  
I have put some thought into this myself and if string maniuplation could be introduced into the trigger world, it could be done using a text code. To prevent cheating the code would have to be integrated with the user id, which is another challenge that has not yet been solved...


In all your science of the mind, seeking blind through flesh and bone
Find the blood inside this stone
Well, I know I've never shown what I feel, I've always known
I plan my vengeance on my own - and I was always alone
posted 04 May 2008 06:25 AM EDT (US)     6 / 36  
http://aom.heavengames.com/cgi-bin/forums/display.cgi?action=ct&f=19,26279,,all

All hail invent00r!

I could try to triggerify it... I just didn't see the purpose of string manipulation for triggers yet.
The best way I know is to use a config but that is advanced.
That's the first thing that came to my mind too. You can easily set configs, but how do you get them back? There is some getConfigByID() function, but where do we get the ID?
the user id
Can't we get the map seed somewhere?

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak

[This message has been edited by Mythic_Freak (edited 05-04-2008 @ 06:30 AM).]

posted 04 May 2008 06:55 AM EDT (US)     7 / 36  
Getting a confguration is the biggest problem I have had.

There seems to be no way and I doubt you can do it the visual basic way and use the set commnd as a get command.

The only way of getting a config var is to use the config var.

E.g. set default camera pitch on one map and on the next map use a visible to player trigger. If the pitch has been changed your camera will be looking in a different direction as default.

Remeber to set it back through afterwards.

The boy with the mad imagination
Prepare for the ultimate duel!
Learn to use all my triggers and what you can do with them. Visit here.
Find out and download the transform trigger here.
Play some minigames I have created outside AOM including some 3D games here.
posted 04 May 2008 08:43 AM EDT (US)     8 / 36  
Do console commands actually ever return something? Some say 'spews all key mapping out to the console', but if you use the command, nothing happens. So could you still try to do something like this in a trigger script?

string downkeys = uiDumpKeyMappings();

Or just some int/float?

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak
posted 04 May 2008 08:48 AM EDT (US)     9 / 36  
Hmm. So using XS string manipulation, I could temporarily store data in the player's name or some global variable like that, and then I could use substring and toNumber functions to convert it back to numbers, I see that.

My question is, how do you put the data into the player's name? I was aware of the {PlayerName(1)} function to get their name, but not of any way to set it. And this change carries over between scenarios?

How many characters can the player's name hold? How exactly would I get the numbers into it? Once I extracted the float from the player's name, is this some way to convert it back to a quest var? I'm still not sure how this would look in triggers.

Thor Odinson
AoM Scenario and RMS Designer

"The individual has always had to struggle to keep from being overwhelmed by the tribe. If you try it, you will be lonely often, and sometimes frightened. But no price is too high to pay for the privilege of owning yourself."
-Friedrich Nietzsche

[This message has been edited by Thor Odinson (edited 05-04-2008 @ 08:50 AM).]

posted 04 May 2008 09:06 AM EDT (US)     10 / 36  
Who said anything about storing it in the players name? You could just grab all the info you need, put it in a string, use configSet("my_scenario_config_1", myString) and then get to the next scenario. The problem is that there is no solid way to retrieve it once in the next scenario (you can see it in the console though.)

So we need to find a way to get it, e.g. by setting a value we want to store to a config used by the game like the min/max zoom. With some tr/console commands you can find out the camera position and thay way get the value back. But as you can see that's not a very convenient way.

Why didn't ES just make a getConfigByName()! -_-" Or just a function to get the config ID by name.

This code returns the player GUID for me, sounds kinda unique:
configGetByID(30)
But I don't know if the config IDs are the same for everyone, so someone else try too please?

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak

[This message has been edited by Mythic_Freak (edited 05-04-2008 @ 09:11 AM).]

posted 04 May 2008 09:27 AM EDT (US)     11 / 36  
Hi Mythic_Freak. I got playerGUID too. A string of numbers and letters which sort of looks like a CD key or a hash code or something.

Thor Odinson
AoM Scenario and RMS Designer

"The individual has always had to struggle to keep from being overwhelmed by the tribe. If you try it, you will be lonely often, and sometimes frightened. But no price is too high to pay for the privilege of owning yourself."
-Friedrich Nietzsche
posted 04 May 2008 11:00 AM EDT (US)     12 / 36  
I think it could be done with triggers...

maiby something like
check file "C:\blabla\blublu\config.txt
in that file would be something like
f=value=1000
Then the Trigger would have some thing liek this
Set [ressource]food=f
At the end, it would change, like:
If f>[ressource]food
set f=value=[ressource]food
or f<[ressource]food
set f=value=[ressource]food
The possibility of cheating is still there, but well, there could also be a second copy HIDDEN, and at the beginn it cheks if they are the same file. If not, 999 will be spammed and a message appears: "YOU FKED CHEATER YOU SUCK HAHAHAHAHAHAHAHA!(JUST OWNED)"

EDIT:

I took a look on the Triggers, and took some parts of each trigger and received this here:
- <Effect name="$$22383$$Textfile CHECK">
<Param name="Textfile" dispName="$$22384$$Textfile" varType="Textfile">default</Param>
<Command>trTextCheckFN("%Textfile%");</Command>
<Command>trPlayerRessource(, "%Food%", %f%, %1%);</Command>
<Command>trPlayerRessource(, "%Gold%", %g%, %1%);</Command>
<Command>trPlayerRessource(, "%Wood%", %w%, %1%);</Command>
</Effect>

KingUndergroundKing
_____________________________________________________________________
-my house is your house and your house is mine-
| YouTube1 | DeviantArt | 2 Girls 2 | Steam | YouTube2 |
_____________________________________________________________________

[This message has been edited by gamerrici (edited 05-04-2008 @ 11:26 AM).]

posted 04 May 2008 11:22 AM EDT (US)     13 / 36  
Oh I think I know how. Use the save and load camera commands. Then during the next scenario you have the load camera command. Use visible to player to distinguis.

I am talking about camera cuts here.

The boy with the mad imagination
Prepare for the ultimate duel!
Learn to use all my triggers and what you can do with them. Visit here.
Find out and download the transform trigger here.
Play some minigames I have created outside AOM including some 3D games here.
posted 04 May 2008 11:28 AM EDT (US)     14 / 36  
<Effect name="$$22383$$Textfile CHECK"> 
<Param name="Textfile" dispName="$$22384$$Textfile" varType="Textfile">default</Param>
<Command>trTextCheckFN("%Textfile%");</Command>
<Command>trPlayerGrantResources(, "%1%", "%Food%", "%f%",);</Command>
<Command>trPlayerGrantResources(, "%1%" "%Gold%", "%g%",);</Command>
<Command>trPlayerGrantResources(, "&1%" "%Wood%", "%w%",);</Command>
</Effect>
nottud, do you think this works?

EDIT:

changed that ressource thing to grant ressource

EDIT2:

corrected error

EDIT3:

Can anyone please tell me why it doesn't appear in the Editor?

KingUndergroundKing
_____________________________________________________________________
-my house is your house and your house is mine-
| YouTube1 | DeviantArt | 2 Girls 2 | Steam | YouTube2 |
_____________________________________________________________________

[This message has been edited by gamerrici (edited 05-04-2008 @ 11:44 AM).]

posted 04 May 2008 01:10 PM EDT (US)     15 / 36  
If it doesn't appear you have a syntax error.

Also remove the wierd symbols infront of the name.

The boy with the mad imagination
Prepare for the ultimate duel!
Learn to use all my triggers and what you can do with them. Visit here.
Find out and download the transform trigger here.
Play some minigames I have created outside AOM including some 3D games here.
posted 04 May 2008 01:24 PM EDT (US)     16 / 36  
<Effect name="$$22383$$Textfile CHECK"> 
<Param name="Textfile" dispName="$$22384$$Textfile" varType="Textfile">default</Param>
<Command>trTextCheckFN("%Textfile%");</Command>
<Command>trPlayerGrantResources(, "%1%", "%Food%", "%f%",);</Command>
<Command>trPlayerGrantResources(, "%1%" "%Gold%", "%g%",);</Command>
<Command>trPlayerGrantResources(, "&1%" "%Wood%", "%w%",);</Command>
</Effect>
Uh? That doesn't make alot of sense...
trTextCheckFN("%Textfile%");
I've never seen that command before, how does it work?

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak
posted 04 May 2008 01:27 PM EDT (US)     17 / 36  
That is called "improvement"

KingUndergroundKing
_____________________________________________________________________
-my house is your house and your house is mine-
| YouTube1 | DeviantArt | 2 Girls 2 | Steam | YouTube2 |
_____________________________________________________________________
posted 04 May 2008 01:37 PM EDT (US)     18 / 36  
Eh? I really don't get it...

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak
posted 04 May 2008 01:48 PM EDT (US)     19 / 36  
That was just for testing something, if the Trigger is for example able to chek files.

KingUndergroundKing
_____________________________________________________________________
-my house is your house and your house is mine-
| YouTube1 | DeviantArt | 2 Girls 2 | Steam | YouTube2 |
_____________________________________________________________________
posted 04 May 2008 01:51 PM EDT (US)     20 / 36  
I see.. well, that would solve a whole lot of problems (and invent00r would have his persistent vars for his learning AI), but as far as I know it's not possible.

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak
posted 04 May 2008 02:11 PM EDT (US)     21 / 36  
If we find out, how the game saves and loads Savegames, we could incluede a sort of script or so...

Go Go Gadget-Searcher!

KingUndergroundKing
_____________________________________________________________________
-my house is your house and your house is mine-
| YouTube1 | DeviantArt | 2 Girls 2 | Steam | YouTube2 |
_____________________________________________________________________
posted 04 May 2008 03:04 PM EDT (US)     22 / 36  
It is possible to save scenarios on multiplayer interestingly enough but so far found no way to load them however I can load random maps but it infortunately cancels the previous game and switches to singleplayer.

The boy with the mad imagination
Prepare for the ultimate duel!
Learn to use all my triggers and what you can do with them. Visit here.
Find out and download the transform trigger here.
Play some minigames I have created outside AOM including some 3D games here.
posted 04 May 2008 03:23 PM EDT (US)     23 / 36  
probably you've got to load them online if you didn't.


EDIT:

maiby this can help:

http://img148.imageshack.us/img148/5361/unbenanntrq0.png

Download UltraEdit 3.2 and open a savegame.

KingUndergroundKing
_____________________________________________________________________
-my house is your house and your house is mine-
| YouTube1 | DeviantArt | 2 Girls 2 | Steam | YouTube2 |
_____________________________________________________________________

[This message has been edited by gamerrici (edited 05-04-2008 @ 03:38 PM).]

posted 04 May 2008 04:29 PM EDT (US)     24 / 36  
4 floppy disks °_°

Euhm, how is that jibberish supposed to help?

If we knew what it was we were doing, it would not be called research, would it? - Einstein, A.
Master XS - AoM Code Reference - Trigger Loader - Trigger Requests - Chess

Wow, I never thought that I would actually know something before nottud did... it's actually not all that satisfying ~ Steak
posted 04 May 2008 06:50 PM EDT (US)     25 / 36  
Can you convert saved games with AoMED?

oh you can wait for what I can give
you know what I am so you know how I live
try to look proud but you’re not in the slightest
its happening now and it’s always been like this.
« Previous Page  1 2  Next Page »
Age of Mythology Heaven » Forums » Scenario Design » Anyone have any ideas on passing information between scenarios?
Top
You must be logged in to post messages.
Please login or register
Hop to:    
Age of Mythology Heaven | HeavenGames