Company Variables

Discussion of Pop Top's last release of RRT.
User avatar
FMCRR
Watchman
Posts: 56
Joined: Wed Nov 05, 2008 12:20 pm
Location: Greenville, OH
Contact:

Company Variables Unread post

Anyone willing to take a moment and try to explain how the variables are used in the game? I have looked at other maps that have them being used but I cannot make heads or tails of them. Maybe include a brief situation of one being used as well...

Thanks
Zig
Home of the Freeport & Muddy Creek Railroad
N Scale, Modern day, Freelance with CSX connection
http://www.freeportmuddycreek.com
User avatar
WPandP
Engineer
Posts: 762
Joined: Tue Sep 11, 2007 5:16 pm
Location: Cincinnati, Ohio
Contact:

Re: Company Variables Unread post

First off, there are different kinds of variables.

Game Variables, when set, are true for the entire game, every player, company, and territory. If you've got an event which you want to affect the entire "world", as it were, then you'd make use of Game Variables.

Company Variables are true just for the railroad company that is referenced. Thus, Company "CSX" may have CV1=1, while Company "UP" can have CV1=0. These are frequently used as win conditions, but if a player starts another company then the new company will have its own set of CV's.

Player Variables are true for a given player, regardless of which company they are running. Thus, Collis Huntington can have PV1=1 while James Hill has PV1=0. When a scenario includes personal net worth as a win condition, they may be making use of PV's.

Territory variables are true for the geographically defined territories, regardless of which companies or players operate in them. They aren't used as much as other variables; I've made use of them as sort of an extension of the Game Variables, since they apply to all players and companies.

It helps to think through what kinds of things you will need to track as variables, then figure out which kinds of variables you need to use. In one of my scenarios, I had a series of choices for the player to make, regarding which kinds of engines they wanted to make use of. Some of these choices were just one-off choices, handled in a single event - i.e. Choose engine A or B. However, other choices I wanted to have a cumulative effect (i.e. if you choose engine A, then you won't have access to engine C later), and to make this happen I needed to record the choice that was made. In the event in which the player chooses between engine A and engine B, then, I made one of the effects of this choice be to set a variable to one value or another; let's say that for choice A, CV1 gets set to 1, and for choice B, CV1 gets set to 2. Then, when I write the choice event for engines C and D, if I only want this event to come up if the player chose B previously, then I could make one of its test conditions be that CV1 must be = 2. This way, if a player chooses A then the choice between C and D won't fire for them.

Think of variables like a bunch of post-it notes; they remember things during the course of the game. You just have to tell them what to remember. There are things that Company "CSX" needs to remember that "UP" does not, and vice-versa, so these kinds of things need to be Company Variables; similarly for PV's and TV's.

Is that enough to get you started?
=Winchester, Paston & Portsmouth=
====== We Provide Pride! ======
User avatar
Canadian Viking
Brakeman
Posts: 171
Joined: Thu May 17, 2007 11:46 am
Location: Alberta, Canada

Re: Company Variables Unread post

Nice introductory post to the subject, WP&P.

This is off topic, but I want to congratulate you on making Engineer! :salute: Must have happened a few days ago. Gives me a good reason to hoist a root beer in your honor. (0!!0)
User avatar
WPandP
Engineer
Posts: 762
Joined: Tue Sep 11, 2007 5:16 pm
Location: Cincinnati, Ohio
Contact:

Re: Company Variables Unread post

Wow, I wasn't even looking!
*!*!*!

Guess I'm an engineer now. I feel so... different...

Thanks for the congrats - I appreciate it! (0!!0)
=Winchester, Paston & Portsmouth=
====== We Provide Pride! ======
User avatar
FMCRR
Watchman
Posts: 56
Joined: Wed Nov 05, 2008 12:20 pm
Location: Greenville, OH
Contact:

Re: Company Variables Unread post

Uhhhh.....Oh Boy....Looks like I need to study more LOL Thank You WP&P for the explanation, it's clear as mud now !hairpull! I will continue to look at other maps and try to nail this whole concept down. I understand what you were saying about a choice between A & B and if choice A is made then later on there could be another spot to make either another choice (that would not be there is choice B would have been made) or have access to something that again you would not have had with the other choice. I guess part of my confusion is how to make them happen in the events screen. Hence a serious lack of understanding when on that one screen. Using the actual variables in the Event screen and using them correctly seems to be my dilema.
Thanks for making it a bit more understandable......

Zig
Home of the Freeport & Muddy Creek Railroad
N Scale, Modern day, Freelance with CSX connection
http://www.freeportmuddycreek.com
User avatar
WPandP
Engineer
Posts: 762
Joined: Tue Sep 11, 2007 5:16 pm
Location: Cincinnati, Ohio
Contact:

Re: Company Variables Unread post

I think it's possible to craft a whole scenario without ever using the variables; they aren't critical to fully understand. You'd be limited to the kinds of things that events can test for by default, such as Company Cash or Territory 1 connected to Territory 2, all those triggers that show up on the list when you start scripting an event. Those all represent things that the computer keeps track of by default, i.e. they are "event variables".

The benefit of using the Game Variables (and their siblings) is that these are user-defined, and so they can keep track of anything you want. Some people design their scenarios to have win conditions that are based on the earning of points. The game doesn't naturally assign points to various actions, so this is all done via user-defined variables.

My example, of a series of engine choices, is just one of many possible examples of what can be done. My point is that, without making use of the variables, I could script Event #1 to allow you to choose between A and B, and the effect of A is to make Engine A available, while the effect of B is to make Engine B available. These effects are evaluated and take place immediately. Nothing carries over, without the variables. Thus, Event #2 which offers the choice between C and D will just fire off when it does, without regard to my earlier choices.

Because I only want to have to choose between C and D if I earlier made the choice in favor of B, I need something to remember what choice was made. I do that by adding an effect to each of the choices in Event #1. That is, the effects of A are to make Engine A available as well as to set Company Variable 1 = 1. The effects of choice B are to make Engine B available and to set CV1=2.

Now, in Event #2, I can add the Condition that CV1=2; if it is any other value, then the event will not happen.

You can do this for all kinds of events, making it so that some events only happen if you've done some other thing earlier. This makes for a more interesting strategic games, as each decision might have far-reaching effects. However, as I stated at the outset, you can just use the ready-made conditions and effects without making use of variables, and just live with Events that test for present conditions only.
=Winchester, Paston & Portsmouth=
====== We Provide Pride! ======
User avatar
FMCRR
Watchman
Posts: 56
Joined: Wed Nov 05, 2008 12:20 pm
Location: Greenville, OH
Contact:

Re: Company Variables Unread post

OK that is sounding like something starting to make sense. I guess in my case I just need to keep playing on the event screen. I have no probs making, coloring, populating, setting industries and all that so far, my trouble comes at the event page LOL. Getting events to be scripted correctly so that they do fire and have the correct effect to take place. I still have a couple that for some reason ( yes I know it's just my not knowing WTH I am doing) I cannot get to trigger right and I am sure its just in the settings.

Looking on your website, how is the progression of the layout coming? Mine has been in the works for 11 years, started in N scale and after a brief stint converting to HO have since went back to N. So needless to say my layout has been reworked 3 times in 11 years ^**lylgh Always a work in progress. Have given thought to hooking up with a few of the guys up here with Dayton N trak and building a module but like I dont have time to even work on finishing the home layout LOL. Very good looking Module BTW. Ok enough for now, I'm worse than a woman (so the wife says) when it comes to talking Trains LOL

Thanks again for the info I'll keep working on it, my hopeful end result will be a map of my FMCRR which is a wood, grain and paper layout...

Zig
Home of the Freeport & Muddy Creek Railroad
N Scale, Modern day, Freelance with CSX connection
http://www.freeportmuddycreek.com
Post Reply