open world game?

I would like to know if its possible to make a open world game with unity. I mean like will it lag too much or can unity handle a big world with lots of creatures etc? Also approximately how many vertices can unity handle before it will lag on my computer? I have a 2.8 ghz dual core processor, 4 gb ram, 1gb video card.

That depends on too many other factors, such as what kind of lighting and shaders you’re using, among other things. So there’s no real way to answer that.

That doesn’t mean a whole lot; it depends on what processor that actually is.

That means even less…what kind of card it is and what sort of processing power it has is what primarily affects the speed, not the amount of VRAM.

Anyway, yes, Unity can handle an open world game, if you program it appropriately.

–Eric

It is very possible to make an open world game, I’m making one right now. It won’t lag at all if you have the settings right.

ok the factor that its possible to make a open world game was the most important. Btw I have intel core 2 duo e7500 processor (it turned out to be 2.93 ghz) and ATI HD 5770 video card

Your computer specs as the developer is irelevant really. You would want to try and find out what your players specs are. I think that an average RAM is about 2gb.

But from previous experience with open game worlds is that one of the key things is to keep your models low poly. Make your textures detailed and this can help cover up the fact that they are low poly. I would look at Playstation 2 graphics. If you look at these closely there are actually very few polys and they are all highly textured. With some lightmaps or unity lighting shaders these could look great and run smoothly.

arent all the responses here perhaps irrelevant with regards to specs? his question is whether unity will support open world games. specs are irrelevant perhaps because that applies to all games not just open world.

you all seem to assume that the entire world is being loaded in memory which is just silly.

perhaps:

  • does unity allow for streaming of very large worlds with automatic scenary partitioning and loading. and no i dont mean octree/bsp support for view culling because that is a given for any 3d game.

  • ideally only the area of interest should be ā€œloadedā€ at any one time, as the player moves from zone to zone there should be an otherwise ā€œseamlessā€ loading of adjacent worlds to the player. think ā€œflight simulatorā€, ā€œfarcryā€, ā€œcrysisā€, ā€œoblivionā€, ā€œfallout 3ā€ and so on.

can someone verify that?

cheers,
MickyD
http://mickyd.wordpress.com

1 Like

Theoretically yes (i.e. see Unity - Scripting API: Application.LoadLevelAdditiveAsync), however I’m not sure if anyone has actually done it successfully in an actual game.

that looks very promising! thanks johnnya

if you are using unitypro, I think ā€œOcclusion Cullingā€ will be helpfull too

http://unity3d.com/support/documentation/Manual/Occlusion%20Culling.html

1 Like

hi.
I’m trying to figure out this LoadLevelAdditiveAsync
I added this script to a trigger object, here’s the simple version:

function OnTriggerEnter (Level1Trigger : Collider)
{
var async : AsyncOperation = Application.LoadLevelAdditiveAsync (ā€œLevelNameā€);
//(whether I add the yield here or not… doesn’t seem to make a difference at this stage)
}

what happens is that… it loads the level fine… but then the function keeps loading endlessly.
how do i make the trigger a boolean or something :smile: so that it doesn’t keep triggering, I only want to load the level once :smile:
the only thing that worked until now is killing the trigger immediately after the ā€˜var async’… but that’s dumb :slight_smile:
I will actually need to script something that will take into account if the level has been loaded or not, and unload it as well when the player exits, and wait for a while so that the player can’t keep loading and unloading every second if he/she is at the edge of the triggering area.
can anyone help me with this?
thanks so much :smile:
vm

…help… :frowning:

mkay, to reply to my own question… maybe someone … someday… :slight_smile: could use this info

here’s the code that makes the levels load and unload additively, async
works nicely, although with a slight hickup (pause), but veeeeery slight, I’m sure that the gamer won’t even notice (haven’t tested with a large level… but since the loading is done in the background… I presume the very small hickup is not caused by the size of the level. I could be wrong, of course :slight_smile: … you could load more, smaller levels, in that case, since they get discarded anyway once the player exits the trigger)
anyway, the code for loading is simple. for unloading tough, there is no function because the loading function instances objects into the current level… and doesn’t keep track of them. you simply have to kill them. and the easiest way to do that is by parenting all the content of your level under one empty game object (why is this so fabulously slow btw??), you tag it with the name of the level, and you apply the following script to a trigger in the main level:

public var LevelName = "NameOfYourLevel";



function OnTriggerEnter (other : Collider) 

{

     if (other.gameObject.CompareTag ("Player"))

    {

    	// Load the level.

    	var async : AsyncOperation = Application.LoadLevelAdditiveAsync (LevelName);

    	yield async;

   		Debug.Log ("Loading complete");

    }

}



function OnTriggerExit(other : Collider) 

{

	 if (other.gameObject.CompareTag ("Player"))

	 {

	 	//Unload the level.

	 	var KillLevel =  GameObject.FindWithTag (LevelName);

	 	Destroy (KillLevel);

	 }

}

last thought I’m having here… it’s really a shame that this function only exists in UnityPro :frowning:
I hope I’ll find a way around this, but loading levels normally is not an option, the hickup is huge, no matter how small the level is, even a cube will create a hickup. I also tried streaming geometry from disk with UniLOD. you get a hickup even when streaming a cube :slight_smile: so… no way.
so right now I’m trying to figure out how to spawn things based on player proximity or triggers… it does mean that I have to load all the assets at game start… :frowning: which, for an open world game… is a bit of a challenge :smile:

1 Like