Templates


World Templates In JKL

Depending on the use of a template there is a few conventions used in their naming.

Order


The order the templates are placed is important.Templates have what we refer to as a Parent and Childs. A parent template generaly would have a "Type=" and be based on none. Though you could say a parent is any template which has another template based on it.A child template is a template that is based on another one.It generaly either adds new adjectives or modifies existing attributes of the parent template.In the editing community templates are refered to as a tpl for short.

Example of proper ordering , templates that are used by other tpls are listed first
Tpl Name      Tpl based on        Adjectives and values
_actor           none              orient=(0.000000/0.000000/0.000000) type=actor collide=1 
walkplayer       _actor            type=player thingflags=0x20000401 light=0.200000 model3d=ky.3do 
someactor        walkplayer         creatething=_actor 

Example of improper ordering , templates that are used by other tpls not are listed in proper order and will not function correctly
Tpl Name      Tpl based on        Adjectives and values
someactor        walkplayer         creatething=_actor
walkplayer       _actor            type=player thingflags=0x20000401 light=0.200000 model3d=ky.3do  
_actor           none              orient=(0.000000/0.000000/0.000000) type=actor collide=1

Types


Templates can be thought of as a tree. They have a root and branches. The root template is always based on "None" When specifying a none template it needs to have a "Type" depending on the templates that will be based on the Root or Parent template. The branches could be thought of as the child templates.

Template Types:
actor         -  droid,enemy,civilian 
cog           -  class cogs
corpse        -  dead things
debris        -  throwable thingse etc
explosion     -  explosions
ghost         -  cameras
item          -  pickup weapons,powerups
particle      -  cloud effects,sparks
player        -  the player
weapon        -  force,weapon characteristics

There are quite a few adjectives that can be used in the template files depending upon the "Type" . Some of these are specific to one type and others are more for general use.

The adjectives are split into several groups. The Types use a mixture of these groups. In the list below you will find the appropriate groups for use with the TYPE.

actor         -  General + Physics + Actor 
cog           -  General + Physics + Path
corpse        -  General + Physics
debris        -  General + Physics
explosion     -  General + Explosion
ghost         -  General +
item          -  General + Item
particle      -  General + Physics + Particle
player        -  General + Physics + Actor
weapon        -  General + Weapon


General Adjectives

aiclass
cog
collide
creatething
light
model3d
move
movesize
orient
particle
puppet
size
soundclass
sprite
thingflags
timer


aiclass General Adjective

Links an Ai file to this template.

Use: aiclass=somefile.ai


cog General Adjective

Specifies the class cog file COG File

Use: cog=somefile.cog


collide General Adjective

Specifies the collide type . Collide Flags

Use: collide=Int


creatething General Adjective

Creates a thing based on named template.

Use: creatething=template When template is created also create this thing.


light General Adjective

Specifies a dynamic light value

Use: light=flex


model3d General Adjective

Specifies the 3do to use for template 3DO File

Use: model3d=somefile.3do


move General Adjective

Specifies the move type.

Use: move=* can be one of : none | path | physics


movesize General Adjective

Specifies an area for collision purposes

Use: movesize=flex


orient General Adjective

Provides an orientation for thing created by template

Use: orient=vector [pitch,roll,yaw] [flex X ,flex Y ,flex Z]


particle General Adjective

Links a particle to the template PAR File

Use: particle=somefile.par


puppet General Adjective

Links a puppet to the template PUP File

Use puppet=somefile.pup


size General Adjective

Specifies how big a area the target will be.

Use: size=flex


soundclass General Adjective

Links a Sound Class to template SND File

Use: soundclass=somefile.snd Can also be "none" to overide a parent template.


sprite General Adjective

Links a Sprite with the template SPR File

Use: sprite=somefile.spr


thingflags General Adjective

Sets specific thingflags. Thing Flags

Use: thingflags=int Note a child template can reset the flags of a parent. Ie: the flags are not cumlative.


timer General Adjective

Makes a timer available for this template.

Use: timer=flex Sets a life span for thing, thing is removed when timer elapses.