fxSquareFoliageReplicator
by Jon Jorajuria · 08/17/2006 (12:11 pm) · 7 comments
Download Code File
There are different ways to create square foliage replication and this resource could be combined with the current fxFoliageReplicator tool. Due to the interest of time we created a seperate fxSquareFoliageReplicator. This code enhancement created by Shawn Simas and myself, builds on the original foliage replication code developed by Melvyn May.
This enhancement allows the user to create a square area for foliage replication. It has been tested on both TGE 1.4 and TLK 1.4. Just add the fxSquareFoliageReplicator.cc and fxSquareFoliageReplicator.h files to your sdk/engine/game/fx directory and make the following changes:
In simBase.h under namespace sim, just below DeclareNamedSet(fxReplicatorSet) add:
In simBase.cc under namespace sim, just below ImplementNamedSet(fxFoliageSet) add:
In simManager.cc under function void init(), just below InstantiateNamedSet(fxFoliageSet); add:
In guiTreeViewCtrl.cc find
and just below it add:
In guiTreeViewCtrl.h under enum Icons, just below fxFoliageReplicator, add:
Compile and you are done with the source.
On to scripting:
Open example/creator/editor/objectBuilderGui.gui, below function ObjectBuilderGui::buildfxFoliageReplicator(%this) add:
Open example/creator/editor/EditorGui.cs, below %Environment_Item[10] = "fxFoliageReplicator"; add:
Open example/common/client/missionDownload.cs, below StartFoliageReplication(); add:
Make sure to delete you *.dso files and then launch the game. You will now have a square foliage replicator.
There are different ways to create square foliage replication and this resource could be combined with the current fxFoliageReplicator tool. Due to the interest of time we created a seperate fxSquareFoliageReplicator. This code enhancement created by Shawn Simas and myself, builds on the original foliage replication code developed by Melvyn May.
This enhancement allows the user to create a square area for foliage replication. It has been tested on both TGE 1.4 and TLK 1.4. Just add the fxSquareFoliageReplicator.cc and fxSquareFoliageReplicator.h files to your sdk/engine/game/fx directory and make the following changes:
In simBase.h under namespace sim, just below DeclareNamedSet(fxReplicatorSet) add:
DeclareNamedSet(fxSquareFoliageSet)
In simBase.cc under namespace sim, just below ImplementNamedSet(fxFoliageSet) add:
ImplementNamedSet(fxSquareFoliageSet)
In simManager.cc under function void init(), just below InstantiateNamedSet(fxFoliageSet); add:
InstantiateNamedSet(fxSquareFoliageSet);
In guiTreeViewCtrl.cc find
else if (!dStrcmp(iconString, "fxFoliageReplicator"))
icon = fxFoliageReplicator;and just below it add:
else if (!dStrcmp(iconString, "fxSquareFoliageReplicator"))
icon = fxFoliageReplicator;In guiTreeViewCtrl.h under enum Icons, just below fxFoliageReplicator, add:
fxSquareFoliageReplicator,
Compile and you are done with the source.
On to scripting:
Open example/creator/editor/objectBuilderGui.gui, below function ObjectBuilderGui::buildfxFoliageReplicator(%this) add:
function ObjectBuilderGui::buildfxSquareFoliageReplicator(%this)
{
%this.className = "fxSquareFoliageReplicator";
%this.process();
}Open example/creator/editor/EditorGui.cs, below %Environment_Item[10] = "fxFoliageReplicator"; add:
%Environment_Item[11] = "fxSquareFoliageReplicator";**note you will have to change the numerical order of the items.
Open example/common/client/missionDownload.cs, below StartFoliageReplication(); add:
StartSquareFoliageReplication();
Make sure to delete you *.dso files and then launch the game. You will now have a square foliage replicator.
About the author
#2
%Environment_Item[11] = "fxSquareFoliageReplicator";
to
%Environment_Item[16] = "fxSquareFoliageReplicator";
because of the lighting pack.
10/31/2006 (10:05 pm)
Nice, very simple to implement went into TGA 1.5 only had to change %Environment_Item[11] = "fxSquareFoliageReplicator";
to
%Environment_Item[16] = "fxSquareFoliageReplicator";
because of the lighting pack.
#3
10/26/2007 (5:07 am)
Anybody ported this to TGEA already?
#4
it shows on the menu and will ask for the object name and then nothing ... any ideas ?
10/26/2007 (5:38 am)
newbie here, followed instructions above and tried to get this working in TGE 1.52it shows on the menu and will ask for the object name and then nothing ... any ideas ?
#5
11/10/2007 (12:16 pm)
hello - anyone a little help here ?????
#6
Make sure that you add the fxSquareFoliageReplicator.cc & fxSquareFoliageReplicator.h files to your visual studio project under game/fx. Right click on fx and choose "add existing item"
Skitz
12/07/2007 (4:38 am)
Hi Kevin,Make sure that you add the fxSquareFoliageReplicator.cc & fxSquareFoliageReplicator.h files to your visual studio project under game/fx. Right click on fx and choose "add existing item"
Skitz
#7
thanks again for the direction
kevin
12/10/2007 (2:09 pm)
thank you very much for responding, i wiped out torque and started over and FINALLY got it working - have no idea what it was but had to be me thanks again for the direction
kevin

Torque Owner Ben Sparks - Warspawn
StarOrdered Games