krah
Sep 30th, 2000, 02:02 PM
Is it any different from just an algorithm in code form, like a program? What makes them unique as in "The Unreal Engine" and "The Jedi Knight Engine"? Also if you can think of any other little details and facts about them I would like to know (just about everything) then please include those too...
Fox
Sep 30th, 2000, 08:22 PM
Sure, for example there are other collision methods, other buffering methods (Unreal uses Portals, BSP and so on...), other engines... 3D isn't = 3D, some engines just show the game from above (as GTA), other are 1st person as Unreal, sometimes you see the player (Tomb Raider) or there are not really 3D worlds (Jump 'n' Runs as Pandemonium or Goemon64...) or you need to see a big landscape (Black & White). Also the collisions and stuff, maybe you need to deform the map or just move objects around. And the physics engine, you don't always need gravitation...
There are many differences ;)
krah
Oct 1st, 2000, 12:50 AM
So what you're saying is that an engine is just a program that's fit for a game based on how it is viewed and played?
HarryW
Oct 1st, 2000, 01:12 AM
As far as I can tell, bearing in mind that I haven't really programmed games much, an engine is essentially an object model with a set of functions. So for instance you might have player object, with an onHit() function and a gameWorld object with a players collection or whatever. It's like an abstraction from the source code.
I'm sure Fox can explain it better :)
Fox
Oct 1st, 2000, 04:53 AM
You may define the engine as the program which runs your data ;) You give it level maps, player models, special effects (plugins ;)), sound files and such stuff and the engine makes the work... moving objects, playing sounds, collide things, react on the player input, draw the game (render)...
An engine can be seen as ehm.. an engine of a car... Without it you won't get very far. But there's a big difference in engines. An engine is just a piece (a big piece usually I might add...) of code that handles something. Databases are usually also "driven" by an engine, just as Windows is. Although in Windows we don't call it an engine, but the "Core" or "Kernel".
A 3D-Engine is the piece of code that handles all the calculations needed for the 3D enviroment to move, rotate, explode and so on. Also it usually handles effects like lighting, water, fire and glass.
An AI-Engine (Artificial Intelligence) usually handles the "intelligence" of all characters in a game. That is: Running away from big-guns, shooting you when you're out of ammo or running you over when you get out of your car. The "enemy" must be "intelligent" to know when to do what to make it more difficult for you.
Following is a "recipe" for an game-engine featured in Outcast. Not the newest game, but a good description of what a "Game-Engine" does:
RECIPE FOR GAIA
Faster graphics, more polygons,music that will shake your dead great grandfather's teeth!!!
The industry has strived for 25 years to make game players slobber at the newest, fastest, shiniest thing on the market at the expense of one essential ingredient of gameplay: Artificial Intelligence. Come on, aren't you tired of wandering into a battle sequence and seeing your "incredible AI" opponent standing around with his gun up his nose, waiting for you to fire that first shot? Well, we are.
To redress this issue of believable AI, we've created a new engine capable of breathing life into our characters. GAIA, or (Game Artificial Intelligence with Agents) allows the game designers to infuse real life behaviors, called agents, into each character. These agents represent actions like "Want to eat" and "Flee for your life." Each character can see and hear their surroundings and they use the input from their senses to call up the appropriate response to a situation.
For example, peaceful character George has just seen or heard a bullet whiz past his head. Since George is peaceful, he has no attack agent to react to this stimulus in an aggressive way so he heads for the hills, screaming and waving his arms. Now if peaceful character Bob sees George running buy screaming, he may very well decide that's a good thing to do and run off screaming himself. But if aggressive character Billy sees or hears people screaming or the bullet shot, his aggressive agents will tell him to go and investigate. If Billy sees the cause of the panic, he'll attack.
Now, those actions alone are not unheard of in games today. Keep going, dear reader, it gets sweeter. Now, to the agents we add memory. Remember George and Bob, our screaming sissies? Well, they will be very hesitant to head back to the area that the fear stimulus started. Not only that, if they saw who started their panic run, they'll be very unhappy to see that person again. Over time, they will forget, but the more severe the panic, the longer they will stay unhappy. So if Cutter launches an explosive charge into a peaceful priest's lap, everyone who witnesses it will be mighty unhappy with him for a long time. But wait, there's more! The agents of each character try to interact with the agents of other characters besides yourself.
Since each person needs essentials of food, water and sleep, they must interact with others who can help them achieve their current desires. So if George is hungry, he must find Bob who sells food. If Bob has no food, George must find another character that can help him satisfy this urge.
So how does this help you finish the game, you ask? Simple. Let's say Billy is guarding a house. You want to get into this house but don't have enough ammo to finish the bugger off. Billy is looking often for someone in the distance. You see the water merchant and his cart are approaching and you act fast. You fire your last shot into the air right by the water cart merchant, sending him screaming off into the city. You head back to your hiding spot and watch as George's thirst overrides his duty and he heads for the water cart instead of waiting for it to come to him. Now's your chance! You bolt into the house and find...well, I won't spoil it for you.
Next, GAIA also allows for a management of resources in the game. The enemies need provisions to stay at full Cutter-stomping strength. If you find a way to stop the flow of food to their main camps, you'll face less and less enemies along the way. They'll be the stronger, more resilient ones, but two strong guys are usually easier than 12 weak guys are. Ignore the flow of resources and you'll be in for a longer, tougher game. Finally, we've created a global relationship between Cutter and the characters. Spend your days running around setting fire to the locals and no one will sell you anything. Help old characters across the street or donate money to charity to get on their good side. Once on their good list, the locals will approach and warn you if an enemy patrol is coming around the corner. Handy if you're down on your health. And since some of the characters hold the key to your success, literally, you'll need to be careful what you say and do. But take heed those who "mistakenly" unleash 40 rounds of ammo into crowded market streets, your journey towards the dark side can always be turned around by doing good deeds. Take all these ingredients, mix well together and you'll come out with a tasty new experience for the game players of the world.
For added sweetness, toss in a few realistically acting animals. How many games have you played where you've been able to ditch a hungry carnivore by running past a nice, fat herbivore? And once the public has eaten up this recipe for gameplay, our easy-to-export engine will be able to add spice to all our future games with different flavors being added constantly to the menu.
There is no doubt that the sophisticated simulation of behavior constitutes the "new frontier" in video games. Whereas great care is taken to provide current games with superb scenarios and high-quality sound and graphics, the simulation of behavior which is at the same time convincing, coherent and interesting often leaves a lot to be desired. While the complexity and the diversity of the problems make this task difficult, the benefits to be gained are immense : the creation of a real, living universe.
GAIA is an acronym that stands for Game's Artificial Intelligence with Agents. It's a set of C++ functions (library) that provides the necessary services for programming sophisticated behavior. The technology used for developing this set of functions is based on the most recent research in Distributed Artificial Intelligence (DAI), a new and promissing line of thinking in the controversial area of simulated intelligence. According to this line of thinking, intelligence is represented as a distributed activity over a set of small, autonomous interacting entities called agents. Simplified, an agent possesses (at least) one skill and knows several means (or plans) to realize it. The agent has a partial view of his environment, the means to act according to this environment, as well as a way of communicating with other agents. The advantage of this approach lies in the interaction between the agents, which is in fact the interaction between different tasks. Primarily, these agents can coordinate themselves (in order to realise a complex task) or compete with each other (to take in effect the priority of tasks).
The dynamics of these exchanges has revealed under experimentation, that certain properties emerge, which are in fact the ability of the agent societies to achieve a task that has not strictly been programmed in advance (Eg : imagine a robot controlled by two agents. One is capable of advancing towards a wall, the other to move away from it. If these two agents are in competition with each other, one can "assist" in the emergence of the property "To follow a wall"). This approach has been adapted by us to simulate behavior. In GAIA, each behavior is represented by a set of interacting agents. Each agent is responsible for a small part of the global behavior of the character. The flexibility of this approach eliminates the pitfall of a restrictive definition of behavior : each behavior is described case by case, by adding several agents which are part of the behavior that one wishes to describe. To facilitate this process, GAIA supports inheritance between behavior. This allows a simplified description by progressive refinement (Ex : the behavior of a guard is the "enriched" behavior of a human being).
Likewise, the system is capable of managing solutions for different tasks simultaneously, which takes into account the parallelism inherent of certain tasks (Ex : shooting while moving).
I hope this helps you!
krah
Oct 1st, 2000, 10:37 PM
Yeah, now I get it. Very nice example Rob, I love the GAIA guy's ideas, but what sucks is that games don't work that well to date, do they? Thanks for the help guys.