Just thought I would try one of the contests. The basic idea of my game is to make money and increase your RAILROAD EMPIRE! I won't tell much now but I may need help later so who knows.
Good luck! This sounds like a great idea, and I look forward to seeing how it evolves.
Thanks! I have some of the user interface done but no gameplay yet Razz , but going well.
EDIT: Realized I had said too much and deleted it. Cool
When building the railroad empire, we should be able to take control of the trust's, and illegally dominate the economy, and then fill the government with people who will ease up on the trust's restrictions, allowing corruption to flourish.
I love corruption. Why else would I mess with save states on my N64 emulator, or add stupid mods to The Sims?

I agree with CHill, an overly realistic game would be great.
I wasn't going for quite that real seeing as it would be very complex, but I suppose I could add corruption if you guys really want it. I am going to stick with my original plan for now (making money legally) but when I finish that and assuming I have time I will gladly put in something about illegally squashing competition and government corruption.
So I'm not entirely sure if I can ask this kind of thing but since it doesn't involve specific code and its a general question I think I should be okay.
Anyways, do you think it is generally better to use pics to draw full-screen graphics or to use sprites, lines, pixels, etc.? I know pics are faster and smaller in the program but they take up 767 bytes and a precious pic slot. I want to make nice graphics for railroad empire but am unsure about the best way to do it.
Personally, I'm not a fan of using the pic variables, so I would go with the sprites, lines, pixels, etc. Also, the coding style will be judged so I think it would play in your favor to use sprites over pics.
That depends of your program. Pics are really nice for a static background, but for more complexity or variety, I would prefer using sprites, lines etc.
Ok, I think I will draw the graphics from within the program. Here is another little update on progress: I have added a "reset stats" feature, and made more progress on the train factory (shop). I have also thought about how the game will work and I think I will try to make it in something not remotely close to real time but slow it down to some degree of realism by putting in delays for upgrades, building time, etc. These delays can be skipped for extra money. I will also make it so that during the actual game, each day takes 12 minutes (one for each hour). I may also make a faster version without delays for the impatient and to make it take less time to judge. Progress is slow right now seeing as I am on vacation but I think I will still get the program done on time.
So here's a little plot for you people that like that.
You are a small businessman who owns a train. You decide to start operating it to make some extra money, and find it successful. You then begin growing your trains and rising to the top of the industry. Finally, you get enough money to buy off the mayor of your city who then will pass laws allowing you to control the city's economy. Now that you have so much more money, you can but off the governor of you state, and you soon become such a big factor of the US economy that the president knows if you go out of business the whole nation will collapse in ruin. You threaten to shut down your business unless he gives you control of the country, which he does. From there, your Railroad Empire conquers the world and you dominate everything for the rest of your life.
Haha, that sounds like a great plot, but a little too close to how the real world works for comfort. I look forward to how you expand that into the game itself. How's the coding coming along?
I just got back from vacation, so I haven't made much progress recently. As for the overly real plot: I wrote it that way because people asked for it and the game probably wouldn't have much plot otherwise. Most of the actual gameplay will be in the first (legal) stage anyway, and the rest is just an ending phase for the player's amusement. After all, it takes a long time to make enough money to buy off the mayor alone! Razz

EDIT: So I worked on it quite a bit today since I wrote that ↑ and finished the railroad factory. I started putting delays for shipping, installing cars, etc. However, I have run into a question which I need to decide on before I continue: Is the accuracy+ease+smaller size of using the TI-84+ timing commands worth the loss of compatibility with the TI-83+?
Never mind. I am using for( loop delays so I can exit them early (skip the delay) at the cost of some cash. Also, I have decided to go with hard-coded sprites using pt-on and line( rather than text sprites because they're faster. They are a bit larger but the slow speed of the text sprites was messing up the mechanics of the delays at the factory.
I am now finally ready to start coding the "day," which is when your trains operate and make money and also when your track and trains begin to need maintenance. After I finish that, I can incorporate the plot, optimize, and finish!
Another update:
The game (without empire expansion) is working. However, I have run into a few problems with the actual gameplay. The code is fine, but my delays are frustratingly long and some prices had to be adjusted. Graphics are coming along (slowly). There are several different directions the game could go from here:
•Leave it how it is and make it a game you would play on a long train ride and read or something during the delays
•Speed it up considerably and/or make it available in multiple speeds
•Add timing commands (game would be only for 84+/SE) to make it possible to leave the game and do something else and then the program would detect whether or not the delay had finished or not when you re-entered and then respond appropriately.
What do y'all think?
I have decided to do the timing commands for the day but not the factory. You can now exit the game during the day and return later and it will remember when you started and act appropriately. The necessary values are stored in finance variables (I used I% and PV over the more commonly used N) rather than real variables so programs you use to pass the time while waiting don't screw it up. Marching band rehearsals are limiting my time greatly so I might not have time to push the graphics as far as I would like to.
I have started what you night call beta testing. The basic gameplay is complete but I need to adjust prices and implement a couple more math things into buying track and cars before I can write the plot and add graphics.
Almost finished with the gameplay but have run into a a math roadblock:

Each train is represented by an imaginary number with the real part being the cars and the imaginary part the condition. I store al of the trains in a complex list. For example, 10+i means 10 cars and "perfect average train condition and 15+10i means 15 cars and "useless" condition. Anything between 1 and 10 for the condition has its own word. Right now, if you buy more cars, they immediately share the condition of the old ones even though they should be perfect because I only change the real part of each number. If the train is in poor condition and you buy cars in perfect condition the average condition should go up, but it doesn't. Here is what I'm trying to do:

Code:
Add the real part to increase the number of cars
Do a weighted average on the condition (the # of cars determines the weight)
To clarify, adding more cars decreases (smaller is better) the condition more.
Having more cars before the purchase makes the condition change less.

I'm kinda stuck.
Kydapoot wrote:

Code:
Add the real part to increase the number of cars
Do a weighted average on the condition (the # of cars determines the weight)
To clarify, adding more cars decreases (smaller is better) the condition more.
Having more cars before the purchase makes the condition change less.

I'm kinda stuck.
If I correctly understood your problem, you're stuck at the formula?

Let's break it down then:
You have a number for the condition, let's say 5. And you have a number for the cars, let's say too 5.
So you have 5 cars each of condition 5, on average.
Visualization:

Code:
5 5 5 5 5

Now, let's add another car, of condition 1.

Code:
5 5 5 5 5 1

Now you just calculate the new average - meaning (5 + 5 + 5 + 5 + 5 + 1) / 6.
This example yields 4.33.

Let's put it in numbers: You took the number of cars times their average condition, plus new condition divided by new number of cars. That is:

Code:
New average condition = (Cars * Old average condition + New car condition) / New number of cars

Assuming A holds our complex number and B holds the condition of the new car:

Code:
real(A)+1+((real(A)*imag(A)+B)/real(1+A))i->C

This should return the updated variable in C.

Note I haven't tested it, but I seriously doubt it has mistakes.
I couldn't get that particular code to work, but you put me in the right direction and I came up with this:

Code:

//Starting complex value is A
//B is the number of cars to add
real(A→R   //Separating the number for clarity and size
imag(A→I   //See aabove, also lets me deal with a real rather than imaginary value
(RI+B)/(R+B→E   //Calculated condition
B+R→R   //Adds new cars
R+Ei→A   //Combines cars and condition back into a complex  number

Thank you!
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 2
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement