CreateBlob

From King Arthur's Gold Wiki
Revision as of 19:24, 12 August 2012 by Shadlington (Talk | contribs)

Jump to: navigation, search

CreateBlob will create a blob with the given name (not particularly important, I think?) and the given path to a config file defining the blob. It will return a reference to the blob.


There are two variants, one of which will also accept a team number and position vector.

CBlob@ CreateBlob( const string &factoryName, const string &configFilename )

Example from Entities/Characters/Scripts/ArcherLogic.as: CBlob@ arrow = CreateBlob( "genericitem", "Entities/Items/Arrow.cfg" );


CBlob@ CreateBlob( const string &factoryName, const string &configFilename, u16 team, Vec2f Position )

Example from Entities/Workshops/WorkshopTasks.as: CBlob @shopBlob = CreateBlob( "genericblock", "Entities/Workshops/Base/WorkshopWAR.cfg", 0, this.getBlob().getPosition() );