stopping resources from floating over the terrain (rts + world dom)
by Jeff Yaskus · in RTS Starter Kit · 01/20/2010 (1:22 am) · 0 replies
While playing around with this I noticed the stone and gold resources appear to float over the terrain.
Since they are auto - generated, I make a quick fix to place them at ground level.
Around line ~70, add these (2) if statements ... now the ore it at ground level.
\server\scripts\resources\resourceGeneration.cs
Since they are auto - generated, I make a quick fix to place them at ground level.
Around line ~70, add these (2) if statements ... now the ore it at ground level.
\server\scripts\resources\resourceGeneration.cs
if((%rd % 2) == 0)
{
%z = getWord(getTerrainLevel(%i SPC %j SPC 500, 1), 2);
if (%type $= "Gold") // add this to lower gold
%z -= 5; //
if (%type $= "Stone")// add this to lower stone
%z -= 5; //
%resource = new StaticShape()About the author
Long time gamer, hacker and programmer. With dreams of making video games -