Algorithms or methods to produce events or behavior that is random in nature.

learn more… | top users | synonyms

5
votes
3answers
345 views

Generating random values, keep trying till value within bounds are generated

Sorry for the strange topic name, couldn´t think of a good way to describe it. I´m basically trying to achieve the following: I'm placing items randomly on the screen, but these items shouldn't be ...
12
votes
6answers
2k views

Weighted Random Distribution

I am currently contributing to a particle system for our game and developing some emitter shapes. My uniform random distribution along a line or along a rectangular area works fine - no problem. But ...
22
votes
4answers
1k views

Randomly generated story

I'm developing a game at the moment and I had an idea where the game's story line would randomly generate as the player progressed and their actions would affect the story. Would this be a bad idea ...
21
votes
5answers
1k views

How do I avoid “too” lucky / unlucky streaks in random number generation?

I'm currently dealing with a multiplayer combat system where the damage dealt by the players is always multiplied by a random factor between 0.8 and 1.2. In theory, a truly random RNG may eventually ...
8
votes
3answers
1k views

Pathfinding with multiple random paths in a Tower Defense game

I thought about random pathfinding for my Tower Defense game. A* would not work for my puposes, because I specifically need random pathfinding. Imagine a map with routes, a starting point and a ...
7
votes
3answers
3k views

Random enemy placement on a 2d grid

I want to place my items and enemies randomly (or as randomly as possible). At the moment I use XNA's Random class to generate a number between 800 for X and 600 for Y. It feels like enemies spawn ...
5
votes
1answer
866 views

Random generation of interesting puzzle levels?

I'm making a Sokoban-like game i.e. there's a grid that has some crates on it you can push and you have to get the crates on crosses to win the level (although I'm going to add some extra elements to ...
10
votes
4answers
2k views

Procedural terrains in 3D: what has been done ? Are there common algo and/or theories about it? [closed]

Besides programming, modeling an environment takes a great deal of time. I don't know about the work time involved, for example, in a WoW dungeon level, or other beautiful city-like, future ...
10
votes
3answers
2k views

Algorithm for determining random events

I'm struggling with coming up with an elegant solution to generating random events in the game that I'm working on. Say there are 4 classes of events that can happen, with varying events in those ...
9
votes
3answers
998 views

Reduce the number of edges of a graph, keeping it connected

I'm designing a game with random generated dungeons. I'd like to view this as a connected, undirected graph in which nodes are rooms and edges are doors or corridors. Then I choose a "side" node as ...
4
votes
1answer
358 views

Deterministic random number sequence

I have an array of lights that I need to sample from randomly, but deterministically so that all the lights are sampled. Currently I use random numbers to pick a light, and then put processed lights ...
10
votes
4answers
814 views

How do I make NPC pathfinding look believable?

Is there an "academic" way to have NPC walking randomly on a map, but having a believable comportment ? The obvious scenario is a armed guard who is walking around a basement to secure it. It's quite ...
1
vote
2answers
584 views

Random Ghost Behavior in PacMan Clone Not Random?

I'm currently programming a PacMan clone as my first ever game with the XNA Game Studio before eventually going to DirectX. As a first ever game, lots of things have given me great headaches, ...
0
votes
1answer
226 views

Combine n Gaussian Probability Sets in a limited float range

I've got a fixed solution space defined by a minimum and maximum float which has no divisible slice. You then have 0..N Gaussian distribution probability sets which I need to combine. In the end I ...
38
votes
3answers
13k views

How to generate random level from a seed? [closed]

How would I go about using a random seed to generate a game level? The same seed should always generate the exact same level. For this example it would be a Worms style level. So each level would ...
10
votes
8answers
1k views

Best solution for “level string”?

I have a game that generates a random level map at the start of the level. I want to implement some way to save and load the level. I was thinking maybe XML would be a good option for saving all the ...
3
votes
6answers
5k views

Tools for generating random world maps? [closed]

Looking for a tool that will randomly generate an image of a world map.
25
votes
6answers
1k views

Have any video game designs used non-uniform random numbers in interesting ways?

A variety of video games use uniformly distributed numbers to decide the outcome of an event, such as a "50% chance to hit" almost always means to check if a random floating point number from 0-1 is ...
42
votes
14answers
2k views

How to generate a universe? [closed]

If I wanted to generate a universe/galaxy like that of Elite or Spore, what would be some good programming reference materials and algorithms to take into account?