How to fill a region with asteroids [Solved]
Posted: Sun Oct 16, 2011 1:45 pm
Tutorial for filling a region with asteroids:
The Steps:
Varible with number
local kNumAstLrg = 320(How many asteroids you want in the region)
Set up MemoryPoolSize
SetMemoryPoolSize("Asteroid", kNumAstLrg)
SetMemoryPoolSize("TreeGridStack", 650 )--kNumAstLrg*2.75)
Fill the region with asteroids
FillAsteroidRegion("Regionname", "Objectname", Number of Asteroids, Idk but I think it's the moving direction.);
FillAsteroidRegion("Ast_02", "spa_prop_jagged_asteroid_large", kNumAstLrg, 3.0,1.0,1.0, 0.0,-1.0,-1.0);
Create a region with the name Ast_02 in the ZeroEditor(you can call your region whatever you want. You just need to change it in the ZeroEditor too.)
It can look like this(Just a part of the LUA!):
Don't forget to save!
Last not least you need to add the object name of the odf into the ABC.req
It's important because this object is not placed in the ZeroEditor otherwise no astroids will be loaded.
You can also try crazy things like other objects.
So but in this case:
Don't forget to save!
Done and it works!
Edit:
Now it does work.
I solved the problem with adding a class object into the req.
The Steps:
Varible with number
local kNumAstLrg = 320(How many asteroids you want in the region)
Set up MemoryPoolSize
SetMemoryPoolSize("Asteroid", kNumAstLrg)
SetMemoryPoolSize("TreeGridStack", 650 )--kNumAstLrg*2.75)
Fill the region with asteroids
FillAsteroidRegion("Regionname", "Objectname", Number of Asteroids, Idk but I think it's the moving direction.);
FillAsteroidRegion("Ast_02", "spa_prop_jagged_asteroid_large", kNumAstLrg, 3.0,1.0,1.0, 0.0,-1.0,-1.0);
Create a region with the name Ast_02 in the ZeroEditor(you can call your region whatever you want. You just need to change it in the ZeroEditor too.)
It can look like this(Just a part of the LUA!):
Hidden/Spoiler:
Last not least you need to add the object name of the odf into the ABC.req
It's important because this object is not placed in the ZeroEditor otherwise no astroids will be loaded.
You can also try crazy things like other objects.
So but in this case:
Code: Select all
REQN
{
"class"
"spa_prop_jagged_asteroid_large"
}
Done and it works!
Edit:
Now it does work.
I solved the problem with adding a class object into the req.