For a game simulation, I'd rely a lot on a pseudo-random number generator. If it's obfuscated enough, players will never know and it's close enough to reality that it largely doesn't matter.
I'd assign a random initial "true value" for each item and have it fluctuate with a sinusoidal pattern or something with varying periods and amplitude. A categorical fluctuation and one overarching fluctuation would help. So globally, prices could be going up, but the fubar industry isn't as hot, while the specific fubar maker is in a rut and actually losing money.
Categories could be industries, regions, everyone with a name that's similar to a big company, or whatever fits into your game.
You could sprinkle in newsworthy events at random times for specific companies, categories, or global events. Spikes, crashes, small increases/decreases for the next 5 years, and so on.
But that's all the "true value". Which is largely irrelevant for stocks. So I'd have a number of agents that followed a set of policies for buying and selling with their own cash flow and profit. If the player, or one of the agents, wants to buy or sell, he has to make an offer that an agent agrees to. Someone inevitably goes bust and another is spawned.
One agent would be sane, rational, and well informed with a ludicrous pocketbook. He knows what the true value is and buys or sells when the price is good after a significant delay. He's supposed to be the general public and keeps things from getting too weird.
The rest would follow a policy, analyzing patterns trying to guess the true value and future trends.
One would buy whenever he saw a prolonged period of growth. Selling when it flat-lined.
One would never sell unless he made a buck.
One would try the classic pump and dump scheme.
And so on. I think this is the point where you would apply QuantLib and the other answers about mathematical finances.