Huge cleanup. Add initial code for the revamped material definition system.
This commit is contained in:
parent
73c762e875
commit
a463498f60
192 changed files with 1260 additions and 514 deletions
|
@ -3,3 +3,4 @@ CC=fteqcc
|
||||||
all:
|
all:
|
||||||
cd client && $(MAKE)
|
cd client && $(MAKE)
|
||||||
cd server && $(MAKE)
|
cd server && $(MAKE)
|
||||||
|
cd menu && $(MAKE)
|
||||||
|
|
4
base/src/menu/Makefile
Normal file
4
base/src/menu/Makefile
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
CC=fteqcc
|
||||||
|
|
||||||
|
all:
|
||||||
|
$(CC) progs.src
|
9
base/src/menu/progs.src
Normal file
9
base/src/menu/progs.src
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
#pragma target fte_5768
|
||||||
|
#pragma progs_dat "../../menu.dat"
|
||||||
|
#define MENU
|
||||||
|
#define GAME_DIR "base"
|
||||||
|
|
||||||
|
#includelist
|
||||||
|
../../../src/menu-vgui/includes.src
|
||||||
|
#endlist
|
||||||
|
|
|
@ -23,6 +23,7 @@ class item_pickup:NSRenderableEntity
|
||||||
int id;
|
int id;
|
||||||
void(void) item_pickup;
|
void(void) item_pickup;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(entity) Touch;
|
virtual void(entity) Touch;
|
||||||
virtual void(int i) SetItem;
|
virtual void(int i) SetItem;
|
||||||
virtual void(void) Respawn;
|
virtual void(void) Respawn;
|
||||||
|
|
|
@ -93,12 +93,14 @@ item_pickup::Respawn(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
item_pickup::item_pickup(void)
|
item_pickup::Spawned(void)
|
||||||
{
|
{
|
||||||
#ifdef WASTES
|
#ifdef WASTES
|
||||||
Sound_Precache("item_weapon.pickup");
|
Sound_Precache("item_weapon.pickup");
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
super::NSRenderableEntity();
|
|
||||||
Respawn();
|
void
|
||||||
|
item_pickup::item_pickup(void)
|
||||||
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,6 +36,7 @@
|
||||||
!!cvardf r_skipNormal
|
!!cvardf r_skipNormal
|
||||||
!!cvardf r_skipEnvmap
|
!!cvardf r_skipEnvmap
|
||||||
!!cvardf r_skipLightmap
|
!!cvardf r_skipLightmap
|
||||||
|
!!cvardf r_skipDetail
|
||||||
|
|
||||||
#include "sys/defs.h"
|
#include "sys/defs.h"
|
||||||
|
|
||||||
|
@ -232,9 +233,11 @@ varying vec3 norm;
|
||||||
alpha = 1.0;
|
alpha = 1.0;
|
||||||
|
|
||||||
|
|
||||||
|
#if r_skipDetail == 0
|
||||||
#if defined(UPPERLOWER)
|
#if defined(UPPERLOWER)
|
||||||
diffuse_f.rgb *= (texture2D(s_upper, tex_c * 4.0).rgb + 0.5);
|
diffuse_f.rgb *= (texture2D(s_upper, tex_c * 4.0).rgb + 0.5);
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
gl_FragColor = vec4(fog3(diffuse_f.rgb), alpha);
|
gl_FragColor = vec4(fog3(diffuse_f.rgb), alpha);
|
||||||
}
|
}
|
||||||
|
|
|
@ -173,7 +173,7 @@ varying vec3 lightvector;
|
||||||
diff.rgb *= vc.a;
|
diff.rgb *= vc.a;
|
||||||
|
|
||||||
#if defined(UPPERLOWER)
|
#if defined(UPPERLOWER)
|
||||||
diff.rgb *= texture2D(s_upper, tex_c * 4.0).rgb;
|
diff.rgb *= (texture2D(s_upper, tex_c * 4.0).rgb + 0.5);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
gl_FragColor = vec4(fog3additive(diff), vc.a);
|
gl_FragColor = vec4(fog3additive(diff), vc.a);
|
||||||
|
|
|
@ -159,7 +159,7 @@ varying vec2 lm1, lm2, lm3;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(UPPERLOWER)
|
#if defined(UPPERLOWER)
|
||||||
output_f.rgb *= texture2D(s_upper, tex_c * 4.0).rgb;
|
output_f.rgb *= (texture2D(s_upper, tex_c * 4.0).rgb + 0.5);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
gl_FragColor = fog4( vec4( output_f.rgb, 1.0 ) );
|
gl_FragColor = fog4( vec4( output_f.rgb, 1.0 ) );
|
||||||
|
|
|
@ -160,7 +160,7 @@ varying vec2 lm1, lm2, lm3;
|
||||||
|
|
||||||
|
|
||||||
#if defined(UPPERLOWER)
|
#if defined(UPPERLOWER)
|
||||||
diffuse_f.rgb *= texture2D(s_upper, tex_c * 4.0).rgb;
|
diffuse_f.rgb *= (texture2D(s_upper, tex_c * 4.0).rgb + 0.5);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
gl_FragColor = vec4(fog3(diffuse_f), 1.0);
|
gl_FragColor = vec4(fog3(diffuse_f), 1.0);
|
||||||
|
|
|
@ -164,7 +164,7 @@ varying vec2 lm1, lm2, lm3;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(UPPERLOWER)
|
#if defined(UPPERLOWER)
|
||||||
diffuse_f.rgb *= texture2D(s_upper, tex_c * 4.0).rgb;
|
diffuse_f.rgb *= (texture2D(s_upper, tex_c * 4.0).rgb + 0.5);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
gl_FragColor = vec4(fog3(diffuse_f), 1.0);
|
gl_FragColor = vec4(fog3(diffuse_f), 1.0);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
color "255 255 255"
|
color "255 255 255"
|
||||||
alpha 255
|
alpha 255
|
||||||
size 12
|
size 12
|
||||||
path fonts/Tahoma.ttf
|
path gfx/shell/cabin.ttf
|
||||||
|
|
|
@ -1,2 +1,3 @@
|
||||||
COLOR=90 106 80
|
COLOR=28 40 56
|
||||||
|
FG_COLOR=255 255 255
|
||||||
ALPHA=255
|
ALPHA=255
|
||||||
|
|
BIN
platform/menu_fonts.pk3dir/gfx/shell/cabin.ttf
Normal file
BIN
platform/menu_fonts.pk3dir/gfx/shell/cabin.ttf
Normal file
Binary file not shown.
11
platform/vmap_tex.pk3dir/textures/common/clipplayersnow.mat
Normal file
11
platform/vmap_tex.pk3dir/textures/common/clipplayersnow.mat
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
// Vera Visions Material
|
||||||
|
{
|
||||||
|
qer_editorImage "textures/common/clipwood.tga"
|
||||||
|
qer_trans 0.50
|
||||||
|
surfaceParm nodraw
|
||||||
|
surfaceParm trans
|
||||||
|
surfaceParm playerclip
|
||||||
|
surfaceParm nolightmap
|
||||||
|
surfaceParm snow
|
||||||
|
nomipmaps
|
||||||
|
}
|
|
@ -66,6 +66,7 @@ CSQC_Init(float apilevel, string enginename, float engineversion)
|
||||||
Sentences_Init();
|
Sentences_Init();
|
||||||
Decals_Init();
|
Decals_Init();
|
||||||
Way_Init();
|
Way_Init();
|
||||||
|
Materials_Init();
|
||||||
|
|
||||||
/* let the menu know we're a multi or a singleplayer game */
|
/* let the menu know we're a multi or a singleplayer game */
|
||||||
if (serverkeyfloat("sv_playerslots") == 1)
|
if (serverkeyfloat("sv_playerslots") == 1)
|
||||||
|
@ -696,6 +697,11 @@ CSQC_WorldLoaded(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for (entity a = world; (a = findfloat(a, ::isCSQC, TRUE));) {
|
||||||
|
NSEntity ent = (NSEntity)a;
|
||||||
|
ent.Respawn();
|
||||||
|
}
|
||||||
|
|
||||||
print("Client world initialized.\n");
|
print("Client world initialized.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
void
|
void
|
||||||
Shake_Update(player pl)
|
Shake_Update(NSClientPlayer pl)
|
||||||
{
|
{
|
||||||
if (pSeat->m_flShakeDuration > 0.0) {
|
if (pSeat->m_flShakeDuration > 0.0) {
|
||||||
vector vecShake = [0,0,0];
|
vector vecShake = [0,0,0];
|
||||||
|
|
|
@ -69,7 +69,6 @@ void
|
||||||
env_cubemap::env_cubemap(void)
|
env_cubemap::env_cubemap(void)
|
||||||
{
|
{
|
||||||
m_iSize = 32;
|
m_iSize = 32;
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -45,8 +45,10 @@ class env_glow:NSEntity /* change to renderablentity? */
|
||||||
|
|
||||||
void(void) env_glow;
|
void(void) env_glow;
|
||||||
|
|
||||||
virtual float() predraw;
|
virtual void(void) Spawned;
|
||||||
virtual void() postdraw;
|
virtual void(void) Respawn;
|
||||||
|
virtual float(void) predraw;
|
||||||
|
virtual void(void) postdraw;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
virtual void(void) RendererRestarted;
|
virtual void(void) RendererRestarted;
|
||||||
};
|
};
|
||||||
|
@ -202,6 +204,20 @@ env_glow::SpawnKey(string strField, string strKey)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_glow::Respawn(void)
|
||||||
|
{
|
||||||
|
SetSize([0,0,0], [0,0,0]);
|
||||||
|
SetOrigin(GetSpawnOrigin());
|
||||||
|
effects &= ~EF_NOSHADOW;
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_glow::Spawned(void)
|
||||||
|
{
|
||||||
|
RendererRestarted();
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_glow::env_glow(void)
|
env_glow::env_glow(void)
|
||||||
{
|
{
|
||||||
|
@ -209,10 +225,4 @@ env_glow::env_glow(void)
|
||||||
m_flMaxAlpha = 1.0f;
|
m_flMaxAlpha = 1.0f;
|
||||||
m_vecColor = [1,1,1];
|
m_vecColor = [1,1,1];
|
||||||
drawmask = MASK_GLOWS;
|
drawmask = MASK_GLOWS;
|
||||||
setsize(this, [0,0,0], [0,0,0]);
|
|
||||||
effects &= ~EF_NOSHADOW;
|
|
||||||
Init();
|
|
||||||
|
|
||||||
RendererRestarted();
|
|
||||||
setorigin(this, origin);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -76,5 +76,4 @@ env_laser::ReceiveEntity(float flNew, float flChanged)
|
||||||
void
|
void
|
||||||
env_laser::env_laser(void)
|
env_laser::env_laser(void)
|
||||||
{
|
{
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,8 @@ class env_particle:NSEntity
|
||||||
string m_strTarget;
|
string m_strTarget;
|
||||||
|
|
||||||
void(void) env_particle;
|
void(void) env_particle;
|
||||||
|
|
||||||
|
virtual void(void) Respawn;
|
||||||
virtual void(void) customphysics;
|
virtual void(void) customphysics;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
@ -96,10 +98,13 @@ void env_particle::SpawnKey(string strField, string strKey)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_particle::Respawn(void)
|
||||||
|
{
|
||||||
|
SetOrigin(GetSpawnOrigin());
|
||||||
|
SetSize([0,0,0], [0,0,0]);
|
||||||
|
}
|
||||||
|
|
||||||
void env_particle::env_particle(void)
|
void env_particle::env_particle(void)
|
||||||
{
|
{
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
Init();
|
|
||||||
setorigin(this, origin);
|
|
||||||
setsize(this, [0,0,0], [0,0,0]);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -71,6 +71,7 @@ class env_sound:NSEntity
|
||||||
|
|
||||||
void(void) env_sound;
|
void(void) env_sound;
|
||||||
|
|
||||||
|
virtual void(void) Respawn;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -99,12 +100,15 @@ env_sound::SpawnKey(string strField, string strKey)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_sound::Respawn(void)
|
||||||
|
{
|
||||||
|
SetSize([0,0,0], [0,0,0]);
|
||||||
|
SetOrigin(GetSpawnOrigin());
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_sound::env_sound(void)
|
env_sound::env_sound(void)
|
||||||
{
|
{
|
||||||
m_iRadius = 256;
|
m_iRadius = 256;
|
||||||
Init();
|
|
||||||
|
|
||||||
setsize(this, [0,0,0], [0,0,0]);
|
|
||||||
setorigin(this, origin);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,6 +38,7 @@ class env_soundscape:NSEntity
|
||||||
|
|
||||||
void(void) env_soundscape;
|
void(void) env_soundscape;
|
||||||
|
|
||||||
|
virtual void(void) Respawn;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -65,15 +66,19 @@ env_soundscape::SpawnKey(string strField, string strKey)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_soundscape::Respawn(void)
|
||||||
|
{
|
||||||
|
SetSize([0,0,0], [0,0,0]);
|
||||||
|
SetOrigin(GetSpawnOrigin());
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_soundscape::env_soundscape(void)
|
env_soundscape::env_soundscape(void)
|
||||||
{
|
{
|
||||||
g_scapes+=1;
|
g_scapes+=1;
|
||||||
m_iID = g_scapes;
|
m_iID = g_scapes;
|
||||||
m_iRadius = 1024;
|
m_iRadius = 1024;
|
||||||
setsize(this, [0,0,0], [0,0,0]);
|
|
||||||
Init();
|
|
||||||
setorigin(this, origin);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -23,7 +23,6 @@ class env_sprite:NSRenderableEntity
|
||||||
|
|
||||||
virtual float(void) predraw;
|
virtual float(void) predraw;
|
||||||
virtual void(void) Init;
|
virtual void(void) Init;
|
||||||
virtual void(void) Initialized;
|
|
||||||
virtual void(float,float) ReceiveEntity;
|
virtual void(float,float) ReceiveEntity;
|
||||||
virtual void(void) think;
|
virtual void(void) think;
|
||||||
};
|
};
|
||||||
|
@ -113,10 +112,6 @@ env_sprite::Init(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
void
|
void
|
||||||
env_sprite::Initialized(void)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
void
|
|
||||||
env_sprite::env_sprite(void)
|
env_sprite::env_sprite(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,8 +51,8 @@ class env_sun:NSEntity
|
||||||
int m_iUseAngles;
|
int m_iUseAngles;
|
||||||
|
|
||||||
void(void) env_sun;
|
void(void) env_sun;
|
||||||
virtual void(void) Init;
|
|
||||||
virtual void(void) Initialized;
|
virtual void(void) Spawned;
|
||||||
virtual void(void) postdraw;
|
virtual void(void) postdraw;
|
||||||
virtual float(void) predraw;
|
virtual float(void) predraw;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
|
@ -127,16 +127,11 @@ env_sun::postdraw(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_sun::Init(void)
|
env_sun::Spawned(void)
|
||||||
{
|
{
|
||||||
super::Init();
|
super::Spawned();
|
||||||
setorigin(this, origin);
|
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
setorigin(this, origin);
|
||||||
env_sun::Initialized(void)
|
|
||||||
{
|
|
||||||
makevectors(m_vecLensPos);
|
makevectors(m_vecLensPos);
|
||||||
m_vecLensPos = vectoangles(v_forward);
|
m_vecLensPos = vectoangles(v_forward);
|
||||||
localcmd(sprintf("r_shadows_throwdirection %v\n", v_forward));
|
localcmd(sprintf("r_shadows_throwdirection %v\n", v_forward));
|
||||||
|
@ -163,10 +158,6 @@ env_sun::SpawnKey(string strField, string strKey)
|
||||||
void
|
void
|
||||||
env_sun::env_sun(void)
|
env_sun::env_sun(void)
|
||||||
{
|
{
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
setsize(this, [0,0,0], [0,0,0]);
|
|
||||||
setorigin(this, origin);
|
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -41,7 +41,7 @@ class func_dustcloud:NSEntity
|
||||||
float m_flLifetimeMax;
|
float m_flLifetimeMax;
|
||||||
|
|
||||||
void(void) func_dustcloud;
|
void(void) func_dustcloud;
|
||||||
virtual void(void) Init;
|
virtual void(void) Spawned;
|
||||||
virtual float() predraw;
|
virtual float() predraw;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
@ -139,9 +139,9 @@ func_dustcloud::predraw(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_dustcloud::Init(void)
|
func_dustcloud::Spawned(void)
|
||||||
{
|
{
|
||||||
super::Init();
|
super::Spawned();
|
||||||
|
|
||||||
precache_model(model);
|
precache_model(model);
|
||||||
setmodel(this, model);
|
setmodel(this, model);
|
||||||
|
@ -194,6 +194,4 @@ func_dustcloud::func_dustcloud(void)
|
||||||
m_vecColor = [1,1,1];
|
m_vecColor = [1,1,1];
|
||||||
*/
|
*/
|
||||||
solid = SOLID_NOT;
|
solid = SOLID_NOT;
|
||||||
|
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,8 @@ class func_dustmotes:NSEntity
|
||||||
float m_flNexTime;
|
float m_flNexTime;
|
||||||
|
|
||||||
void(void) func_dustmotes;
|
void(void) func_dustmotes;
|
||||||
virtual void(void) Init;
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual float() predraw;
|
virtual float() predraw;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
@ -66,15 +67,15 @@ func_dustmotes::predraw(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_dustmotes::Init(void)
|
func_dustmotes::Spawned(void)
|
||||||
{
|
{
|
||||||
super::Init();
|
super::Spawned();
|
||||||
|
|
||||||
precache_model(model);
|
precache_model(model);
|
||||||
setmodel(this, model);
|
setmodel(this, model);
|
||||||
setorigin(this, origin);
|
setorigin(this, origin);
|
||||||
movetype = MOVETYPE_NONE;
|
movetype = MOVETYPE_NONE;
|
||||||
drawmask = MASK_ENGINE;
|
m_iCount = vlen(size) / 10;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -94,6 +95,4 @@ void
|
||||||
func_dustmotes::func_dustmotes(void)
|
func_dustmotes::func_dustmotes(void)
|
||||||
{
|
{
|
||||||
solid = SOLID_NOT;
|
solid = SOLID_NOT;
|
||||||
Init();
|
|
||||||
m_iCount = vlen(size) / 10;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,7 +36,8 @@ class func_lod:NSRenderableEntity
|
||||||
int m_iDisappearDist;
|
int m_iDisappearDist;
|
||||||
|
|
||||||
void(void) func_lod;
|
void(void) func_lod;
|
||||||
virtual void(void) Init;
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual float() predraw;
|
virtual float() predraw;
|
||||||
virtual void(string,string) SpawnKey;
|
virtual void(string,string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
@ -91,9 +92,9 @@ func_lod::SpawnKey(string strField, string strKey)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_lod::Init(void)
|
func_lod::Spawned(void)
|
||||||
{
|
{
|
||||||
super::Init();
|
super::Spawned();
|
||||||
|
|
||||||
precache_model(model);
|
precache_model(model);
|
||||||
setmodel(this, model);
|
setmodel(this, model);
|
||||||
|
@ -107,5 +108,4 @@ func_lod::func_lod(void)
|
||||||
{
|
{
|
||||||
m_iDisappearDist = 2000;
|
m_iDisappearDist = 2000;
|
||||||
solid = SOLID_BSP;
|
solid = SOLID_BSP;
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,7 +45,7 @@ class func_smokevolume:NSEntity
|
||||||
float m_flMaxDrawDistance;
|
float m_flMaxDrawDistance;
|
||||||
|
|
||||||
void(void) func_smokevolume;
|
void(void) func_smokevolume;
|
||||||
virtual void(void) Init;
|
virtual void(void) Spawned;
|
||||||
virtual float() predraw;
|
virtual float() predraw;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
@ -157,15 +157,14 @@ func_smokevolume::predraw(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_smokevolume::Init(void)
|
func_smokevolume::Spawned(void)
|
||||||
{
|
{
|
||||||
super::Init();
|
super::Spawned();
|
||||||
|
|
||||||
precache_model(model);
|
precache_model(model);
|
||||||
setmodel(this, model);
|
setmodel(this, model);
|
||||||
setorigin(this, origin);
|
setorigin(this, origin);
|
||||||
movetype = MOVETYPE_NONE;
|
movetype = MOVETYPE_NONE;
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
|
|
||||||
if (m_iCount == -1)
|
if (m_iCount == -1)
|
||||||
m_iCount = (int)(vlen(size) / 100);
|
m_iCount = (int)(vlen(size) / 100);
|
||||||
|
@ -211,6 +210,4 @@ func_smokevolume::func_smokevolume(void)
|
||||||
m_vecColor1 = m_vecColor2 = [0,0,0];
|
m_vecColor1 = m_vecColor2 = [0,0,0];
|
||||||
|
|
||||||
solid = SOLID_NOT;
|
solid = SOLID_NOT;
|
||||||
|
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,5 +16,10 @@
|
||||||
|
|
||||||
class info_notnull:NSEntity
|
class info_notnull:NSEntity
|
||||||
{
|
{
|
||||||
|
void(void) info_notnull;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
void
|
||||||
|
info_notnull::info_notnull(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
|
@ -55,12 +55,8 @@ infodecal::SpawnKey(string strField, string strKey)
|
||||||
void
|
void
|
||||||
infodecal::infodecal(void)
|
infodecal::infodecal(void)
|
||||||
{
|
{
|
||||||
Init();
|
|
||||||
|
|
||||||
if (targetname) {
|
if (targetname) {
|
||||||
remove(this);
|
remove(this);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,22 +53,14 @@ class light_environment:NSEntity
|
||||||
{
|
{
|
||||||
void(void) light_environment;
|
void(void) light_environment;
|
||||||
|
|
||||||
virtual void(void) Init;
|
virtual void(void) Respawn;
|
||||||
virtual void(void) Initialized;
|
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
};
|
};
|
||||||
|
|
||||||
void
|
void
|
||||||
light_environment::Init(void)
|
light_environment::Respawn(void)
|
||||||
{
|
{
|
||||||
super::Init();
|
|
||||||
setorigin(this, origin);
|
setorigin(this, origin);
|
||||||
drawmask = MASK_ENGINE;
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
|
||||||
light_environment::Initialized(void)
|
|
||||||
{
|
|
||||||
makevectors(g_vecSunDir);
|
makevectors(g_vecSunDir);
|
||||||
cvar_set("r_shadows_throwdirection", sprintf("%v", v_forward));
|
cvar_set("r_shadows_throwdirection", sprintf("%v", v_forward));
|
||||||
}
|
}
|
||||||
|
@ -92,5 +84,4 @@ void
|
||||||
light_environment::light_environment(void)
|
light_environment::light_environment(void)
|
||||||
{
|
{
|
||||||
solid = SOLID_NOT;
|
solid = SOLID_NOT;
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -63,7 +63,6 @@ point_message::point_message(void)
|
||||||
{
|
{
|
||||||
m_flRadius = 512;
|
m_flRadius = 512;
|
||||||
m_strMessage = "No message";
|
m_strMessage = "No message";
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
|
|
|
@ -22,6 +22,8 @@ prop_static:NSEntity
|
||||||
void(void) prop_static;
|
void(void) prop_static;
|
||||||
|
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
|
virtual void(void) Respawn;
|
||||||
|
virtual void(void) Spawned;
|
||||||
};
|
};
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -43,17 +45,26 @@ prop_static::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
prop_static::prop_static(void)
|
prop_static::Respawn(void)
|
||||||
{
|
{
|
||||||
float skindata;
|
makestatic(this);
|
||||||
drawmask = MASK_ENGINE;
|
}
|
||||||
Init();
|
|
||||||
|
|
||||||
|
void
|
||||||
|
prop_static::Spawned(void)
|
||||||
|
{
|
||||||
|
super::Spawned();
|
||||||
|
|
||||||
|
float skindata;
|
||||||
solid = SOLID_NOT;
|
solid = SOLID_NOT;
|
||||||
setmodel(this, model);
|
setmodel(this, model);
|
||||||
skindata = loadcustomskin("", sprintf("geomset 0 %i\ngeomset 1 %i\n", m_iBody, m_iBody));
|
skindata = loadcustomskin("", sprintf("geomset 0 %i\ngeomset 1 %i\n", m_iBody, m_iBody));
|
||||||
applycustomskin(this, skindata);
|
applycustomskin(this, skindata);
|
||||||
setorigin(this, origin);
|
setorigin(this, origin);
|
||||||
setsize(this, mins * scale, maxs * scale);
|
setsize(this, mins * scale, maxs * scale);
|
||||||
makestatic(this);
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
prop_static::prop_static(void)
|
||||||
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,7 +62,6 @@ void
|
||||||
sky_camera::sky_camera(void)
|
sky_camera::sky_camera(void)
|
||||||
{
|
{
|
||||||
g_skyscale = 16;
|
g_skyscale = 16;
|
||||||
Init();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -62,13 +62,13 @@ button_target::Respawn(void)
|
||||||
if (HasSpawnFlags(BUTTA_USE)) {
|
if (HasSpawnFlags(BUTTA_USE)) {
|
||||||
PlayerUse = PUseWrapper;
|
PlayerUse = PUseWrapper;
|
||||||
} else {
|
} else {
|
||||||
health = 1;
|
SetHealth(1);
|
||||||
takedamage = DAMAGE_YES;
|
SetTakedamage(DAMAGE_YES);
|
||||||
Pain = Death = Damage;
|
Pain = Death = Damage;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* purely cosmetic */
|
/* purely cosmetic */
|
||||||
frame = HasSpawnFlags(BUTTA_TEXON) ? 1 : 0;
|
SetFrame(HasSpawnFlags(BUTTA_TEXON) ? 1 : 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -76,7 +76,7 @@ button_target::Trigger(entity act, int status)
|
||||||
{
|
{
|
||||||
/* make unusable */
|
/* make unusable */
|
||||||
PlayerUse = __NULL__;
|
PlayerUse = __NULL__;
|
||||||
takedamage = DAMAGE_NO;
|
SetTakedamage(DAMAGE_NO);
|
||||||
|
|
||||||
frame = 1 - frame;
|
frame = 1 - frame;
|
||||||
UseTargets(act, status, m_flDelay);
|
UseTargets(act, status, m_flDelay);
|
||||||
|
@ -91,5 +91,4 @@ button_target::Damage(void)
|
||||||
void
|
void
|
||||||
button_target::button_target(void)
|
button_target::button_target(void)
|
||||||
{
|
{
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,7 +49,7 @@ cycler::Pain(void)
|
||||||
} else {
|
} else {
|
||||||
frame += 1;
|
frame += 1;
|
||||||
}
|
}
|
||||||
health = 9999;
|
SetHealth(9999);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -58,12 +58,11 @@ cycler::Respawn(void)
|
||||||
super::Respawn();
|
super::Respawn();
|
||||||
|
|
||||||
SetSolid(SOLID_BBOX);
|
SetSolid(SOLID_BBOX);
|
||||||
takedamage = DAMAGE_YES;
|
SetTakedamage(DAMAGE_YES);
|
||||||
health = 9999;
|
SetHealth(9999);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
cycler::cycler(void)
|
cycler::cycler(void)
|
||||||
{
|
{
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -52,6 +52,7 @@ class env_beverage:NSRenderableEntity
|
||||||
|
|
||||||
void(void) env_beverage;
|
void(void) env_beverage;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(entity, int) Trigger;
|
virtual void(entity, int) Trigger;
|
||||||
|
@ -116,13 +117,17 @@ env_beverage::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_beverage::env_beverage(void)
|
env_beverage::Spawned(void)
|
||||||
{
|
{
|
||||||
|
super::Spawned();
|
||||||
|
|
||||||
precache_model("models/can.mdl");
|
precache_model("models/can.mdl");
|
||||||
precache_sound("weapons/g_bounce3.wav");
|
precache_sound("weapons/g_bounce3.wav");
|
||||||
|
}
|
||||||
|
|
||||||
super::NSRenderableEntity();
|
void
|
||||||
|
env_beverage::env_beverage(void)
|
||||||
|
{
|
||||||
if (!m_iUses) {
|
if (!m_iUses) {
|
||||||
m_iUses = 10;
|
m_iUses = 10;
|
||||||
}
|
}
|
||||||
|
|
|
@ -112,5 +112,4 @@ env_explosion::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
env_explosion::env_explosion(void)
|
env_explosion::env_explosion(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -126,5 +126,4 @@ env_fade::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
env_fade::env_fade(void)
|
env_fade::env_fade(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,7 @@ class env_global:NSPointTrigger
|
||||||
void(void) env_global;
|
void(void) env_global;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string,string) Restore;
|
virtual void(string,string) Restore;
|
||||||
virtual void(entity, int) Trigger;
|
virtual void(entity, int) Trigger;
|
||||||
|
@ -169,9 +170,9 @@ env_global::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_global::env_global(void)
|
env_global::Spawned(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
super::Spawned();
|
||||||
|
|
||||||
if (!m_strGlobalState) {
|
if (!m_strGlobalState) {
|
||||||
objerror("env_global: No globalstate name given! Aborting\n");
|
objerror("env_global: No globalstate name given! Aborting\n");
|
||||||
|
@ -183,3 +184,8 @@ env_global::env_global(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_global::env_global(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
|
@ -71,7 +71,6 @@ env_hudhint::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
env_hudhint::env_hudhint(void)
|
env_hudhint::env_hudhint(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -206,6 +206,5 @@ env_laser::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
env_laser::env_laser(void)
|
env_laser::env_laser(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
pvsflags = PVSF_IGNOREPVS;
|
pvsflags = PVSF_IGNOREPVS;
|
||||||
}
|
}
|
||||||
|
|
|
@ -102,7 +102,6 @@ env_message::SpawnKey(string strKey, string strValue)
|
||||||
|
|
||||||
void env_message::env_message(void)
|
void env_message::env_message(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
@ -115,6 +115,5 @@ env_render::Trigger(entity act, int state)
|
||||||
void
|
void
|
||||||
env_render::env_render(void)
|
env_render::env_render(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -77,5 +77,4 @@ env_shake::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
env_shake::env_shake(void)
|
env_shake::env_shake(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -150,8 +150,6 @@ env_shooter::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
env_shooter::env_shooter(void)
|
env_shooter::env_shooter(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
|
|
||||||
if (!m_strShootModel) {
|
if (!m_strShootModel) {
|
||||||
remove(this);
|
remove(this);
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,6 +53,7 @@ class env_spark:NSPointTrigger
|
||||||
|
|
||||||
void(void) env_spark;
|
void(void) env_spark;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(void) CreateSpark;
|
virtual void(void) CreateSpark;
|
||||||
virtual void(void) TimedSpark;
|
virtual void(void) TimedSpark;
|
||||||
virtual void(entity, int) Trigger;
|
virtual void(entity, int) Trigger;
|
||||||
|
@ -123,9 +124,15 @@ env_spark::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_spark::Spawned(void)
|
||||||
|
{
|
||||||
|
super::Spawned();
|
||||||
|
|
||||||
|
Sound_Precache("env_spark.sfx");
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_spark::env_spark(void)
|
env_spark::env_spark(void)
|
||||||
{
|
{
|
||||||
Sound_Precache("env_spark.sfx");
|
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -56,6 +56,8 @@ class env_sprite:NSRenderableEntity
|
||||||
string m_strMaterial;
|
string m_strMaterial;
|
||||||
|
|
||||||
void(void) env_sprite;
|
void(void) env_sprite;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(entity, int) Trigger;
|
virtual void(entity, int) Trigger;
|
||||||
virtual float(entity, float) SendEntity;
|
virtual float(entity, float) SendEntity;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
|
@ -178,17 +180,19 @@ env_sprite::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
env_sprite::env_sprite(void)
|
env_sprite::Spawned(void)
|
||||||
{
|
{
|
||||||
m_iIsShader = false;
|
|
||||||
m_flFramerate = 10;
|
|
||||||
m_flScale = 1.0f;
|
|
||||||
|
|
||||||
super::NSRenderableEntity();
|
|
||||||
|
|
||||||
m_iToggled = (HasSpawnFlags(ENVS_STARTON) > 0) ? TRUE : FALSE;
|
m_iToggled = (HasSpawnFlags(ENVS_STARTON) > 0) ? TRUE : FALSE;
|
||||||
|
|
||||||
/* how pointless this would be otherwise. */
|
/* how pointless this would be otherwise. */
|
||||||
if (!targetname)
|
if (!targetname)
|
||||||
m_iToggled = TRUE;
|
m_iToggled = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
env_sprite::env_sprite(void)
|
||||||
|
{
|
||||||
|
m_iIsShader = false;
|
||||||
|
m_flFramerate = 10;
|
||||||
|
m_flScale = 1.0f;
|
||||||
|
}
|
||||||
|
|
|
@ -132,5 +132,4 @@ func_areaportal::PortalClose(void)
|
||||||
void
|
void
|
||||||
func_areaportal::func_areaportal(void)
|
func_areaportal::func_areaportal(void)
|
||||||
{
|
{
|
||||||
super::NSEntity();
|
|
||||||
}
|
}
|
|
@ -131,6 +131,7 @@ class func_breakable:NSSurfacePropEntity
|
||||||
void(void) func_breakable;
|
void(void) func_breakable;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(void) Respawn;
|
virtual void(void) Respawn;
|
||||||
virtual void(void) Pain;
|
virtual void(void) Pain;
|
||||||
virtual void(void) Death;
|
virtual void(void) Death;
|
||||||
|
@ -369,8 +370,10 @@ func_breakable::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_breakable::func_breakable(void)
|
func_breakable::Spawned(void)
|
||||||
{
|
{
|
||||||
|
super::Spawned();
|
||||||
|
|
||||||
/* func_breakable defaults to glass */
|
/* func_breakable defaults to glass */
|
||||||
if (classname == "func_breakable") {
|
if (classname == "func_breakable") {
|
||||||
SetPropData(funcbreakable_surftable[0]);
|
SetPropData(funcbreakable_surftable[0]);
|
||||||
|
@ -380,9 +383,11 @@ func_breakable::func_breakable(void)
|
||||||
SetSurfaceData(funcbreakable_surftable[1]);
|
SetSurfaceData(funcbreakable_surftable[1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* proper init */
|
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
|
|
||||||
/* precache impact sound */
|
/* precache impact sound */
|
||||||
Sound_Precache(GetSurfaceData(SURFDATA_SND_BULLETIMPACT));
|
Sound_Precache(GetSurfaceData(SURFDATA_SND_BULLETIMPACT));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_breakable::func_breakable(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
|
@ -130,5 +130,4 @@ func_brush::Respawn(void)
|
||||||
void
|
void
|
||||||
func_brush::func_brush(void)
|
func_brush::func_brush(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -102,6 +102,7 @@ class func_button:NSSurfacePropEntity
|
||||||
string m_strOnIn;
|
string m_strOnIn;
|
||||||
string m_strOnOut;
|
string m_strOnOut;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(void) Respawn;
|
virtual void(void) Respawn;
|
||||||
virtual void(void) Arrived;
|
virtual void(void) Arrived;
|
||||||
virtual void(void) Returned;
|
virtual void(void) Returned;
|
||||||
|
@ -488,20 +489,29 @@ func_button::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_button::func_button(void)
|
func_button::Spawned(void)
|
||||||
{
|
{
|
||||||
m_flWait = 4.0f;
|
super::Spawned();
|
||||||
|
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
|
|
||||||
/* sounds */
|
/* sounds */
|
||||||
Sound_Precache(m_strSndPressed);
|
Sound_Precache(m_strSndPressed);
|
||||||
Sound_Precache(m_strSndUnpressed);
|
Sound_Precache(m_strSndUnpressed);
|
||||||
|
|
||||||
/* input/output */
|
/* input/output */
|
||||||
m_strOnPressed = CreateOutput(m_strOnPressed);
|
if (m_strOnPressed)
|
||||||
m_strOnDamaged = CreateOutput(m_strOnDamaged);
|
m_strOnPressed = CreateOutput(m_strOnPressed);
|
||||||
m_strOnUseLocked = CreateOutput(m_strOnUseLocked);
|
if (m_strOnDamaged)
|
||||||
m_strOnIn = CreateOutput(m_strOnIn);
|
m_strOnDamaged = CreateOutput(m_strOnDamaged);
|
||||||
m_strOnOut = CreateOutput(m_strOnOut);
|
if (m_strOnUseLocked)
|
||||||
|
m_strOnUseLocked = CreateOutput(m_strOnUseLocked);
|
||||||
|
if (m_strOnIn)
|
||||||
|
m_strOnIn = CreateOutput(m_strOnIn);
|
||||||
|
if (m_strOnOut)
|
||||||
|
m_strOnOut = CreateOutput(m_strOnOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_button::func_button(void)
|
||||||
|
{
|
||||||
|
m_flWait = 4.0f;
|
||||||
}
|
}
|
||||||
|
|
|
@ -165,5 +165,4 @@ func_conveyor::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
func_conveyor::func_conveyor(void)
|
func_conveyor::func_conveyor(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -101,6 +101,8 @@ class func_door:NSRenderableEntity
|
||||||
|
|
||||||
void(void) func_door;
|
void(void) func_door;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
|
|
||||||
virtual void(void) PortalOpen;
|
virtual void(void) PortalOpen;
|
||||||
virtual void(void) PortalClose;
|
virtual void(void) PortalClose;
|
||||||
virtual void(void) SetMovementDirection;
|
virtual void(void) SetMovementDirection;
|
||||||
|
@ -638,9 +640,9 @@ func_door::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_door::func_door(void)
|
func_door::Spawned(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
super::Spawned();
|
||||||
|
|
||||||
if (m_strSndOpen)
|
if (m_strSndOpen)
|
||||||
Sound_Precache(m_strSndOpen);
|
Sound_Precache(m_strSndOpen);
|
||||||
|
@ -658,6 +660,39 @@ func_door::func_door(void)
|
||||||
Sound_Precache(m_strUnlockedSfx);
|
Sound_Precache(m_strUnlockedSfx);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_door::func_door(void)
|
||||||
|
{
|
||||||
|
m_vecPos1 =
|
||||||
|
m_vecPos2 =
|
||||||
|
m_vecDest =
|
||||||
|
m_vecMoveDir = [0,0,0];
|
||||||
|
|
||||||
|
m_flSpeed =
|
||||||
|
m_flLip =
|
||||||
|
m_iState =
|
||||||
|
m_flNextTrigger =
|
||||||
|
m_flWait =
|
||||||
|
m_flDelay = 0.0f;
|
||||||
|
|
||||||
|
m_iDamage =
|
||||||
|
m_iLocked =
|
||||||
|
m_iPortalState =
|
||||||
|
m_iForceClosed = 0;
|
||||||
|
|
||||||
|
m_iCanTouch = false;
|
||||||
|
m_flSoundWait = 0.0f;
|
||||||
|
|
||||||
|
targetClose =
|
||||||
|
m_strLockedSfx =
|
||||||
|
m_strUnlockedSfx =
|
||||||
|
|
||||||
|
m_strSndOpen =
|
||||||
|
m_strSndClose =
|
||||||
|
m_strSndMove =
|
||||||
|
m_strSndStop = __NULL__;
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_water(void)
|
func_water(void)
|
||||||
{
|
{
|
||||||
|
|
|
@ -92,6 +92,7 @@ class func_door_rotating:NSRenderableEntity
|
||||||
|
|
||||||
void(void) func_door_rotating;
|
void(void) func_door_rotating;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(void) PortalOpen;
|
virtual void(void) PortalOpen;
|
||||||
virtual void(void) PortalClose;
|
virtual void(void) PortalClose;
|
||||||
virtual void(void) Respawn;
|
virtual void(void) Respawn;
|
||||||
|
@ -492,13 +493,9 @@ func_door_rotating::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_door_rotating::func_door_rotating(void)
|
func_door_rotating::Spawned(void)
|
||||||
{
|
{
|
||||||
m_flSpeed = 100;
|
super::Spawned();
|
||||||
m_flDelay = 4;
|
|
||||||
m_flDistance = 90;
|
|
||||||
|
|
||||||
super::NSRenderableEntity();
|
|
||||||
|
|
||||||
if (m_strSndOpen)
|
if (m_strSndOpen)
|
||||||
Sound_Precache(m_strSndOpen);
|
Sound_Precache(m_strSndOpen);
|
||||||
|
@ -509,3 +506,11 @@ func_door_rotating::func_door_rotating(void)
|
||||||
if (m_strLockedSfx)
|
if (m_strLockedSfx)
|
||||||
Sound_Precache(m_strLockedSfx);
|
Sound_Precache(m_strLockedSfx);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_door_rotating::func_door_rotating(void)
|
||||||
|
{
|
||||||
|
m_flSpeed = 100;
|
||||||
|
m_flDelay = 4;
|
||||||
|
m_flDistance = 90;
|
||||||
|
}
|
||||||
|
|
|
@ -39,6 +39,7 @@ class func_guntarget:NSSurfacePropEntity
|
||||||
void(void) func_guntarget;
|
void(void) func_guntarget;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(void) Respawn;
|
virtual void(void) Respawn;
|
||||||
|
@ -246,11 +247,16 @@ func_guntarget::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void func_guntarget::func_guntarget(void)
|
void
|
||||||
|
func_guntarget::Spawned(void)
|
||||||
{
|
{
|
||||||
m_flSpeed = 100;
|
super::Spawned();
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
|
|
||||||
if (m_strOnDeath)
|
if (m_strOnDeath)
|
||||||
m_strOnDeath = CreateOutput(m_strOnDeath);
|
m_strOnDeath = CreateOutput(m_strOnDeath);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void func_guntarget::func_guntarget(void)
|
||||||
|
{
|
||||||
|
m_flSpeed = 100;
|
||||||
|
}
|
||||||
|
|
|
@ -42,6 +42,7 @@ class func_healthcharger:NSRenderableEntity
|
||||||
void(void) func_healthcharger;
|
void(void) func_healthcharger;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
|
@ -211,15 +212,19 @@ func_healthcharger::Respawn(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_healthcharger::func_healthcharger(void)
|
func_healthcharger::Spawned(void)
|
||||||
{
|
{
|
||||||
m_strSndFirst = "items/medshot4.wav";
|
super::Spawned();
|
||||||
m_strSndCharging = "items/medcharge4.wav";
|
|
||||||
m_strSndDone = "items/medshotno1.wav";
|
|
||||||
|
|
||||||
super::NSRenderableEntity();
|
|
||||||
|
|
||||||
precache_sound(m_strSndFirst);
|
precache_sound(m_strSndFirst);
|
||||||
precache_sound(m_strSndCharging);
|
precache_sound(m_strSndCharging);
|
||||||
precache_sound(m_strSndDone);
|
precache_sound(m_strSndDone);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_healthcharger::func_healthcharger(void)
|
||||||
|
{
|
||||||
|
m_strSndFirst = "items/medshot4.wav";
|
||||||
|
m_strSndCharging = "items/medcharge4.wav";
|
||||||
|
m_strSndDone = "items/medshotno1.wav";
|
||||||
|
}
|
||||||
|
|
|
@ -53,5 +53,4 @@ func_lod::Respawn(void)
|
||||||
void
|
void
|
||||||
func_lod::func_lod(void)
|
func_lod::func_lod(void)
|
||||||
{
|
{
|
||||||
super::NSEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -236,5 +236,4 @@ func_mortar_field::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
func_mortar_field::func_mortar_field(void)
|
func_mortar_field::func_mortar_field(void)
|
||||||
{
|
{
|
||||||
super::NSBrushTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -167,5 +167,4 @@ func_pendulum::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
func_pendulum::func_pendulum(void)
|
func_pendulum::func_pendulum(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -56,7 +56,6 @@ func_physbox::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
func_physbox::func_physbox(void)
|
func_physbox::func_physbox(void)
|
||||||
{
|
{
|
||||||
super::NSPhysicsEntity();
|
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
class func_physbox:NSSurfacePropEntity
|
class func_physbox:NSSurfacePropEntity
|
||||||
|
@ -84,7 +83,6 @@ func_physbox::Respawn(void)
|
||||||
void
|
void
|
||||||
func_physbox::func_physbox(void)
|
func_physbox::func_physbox(void)
|
||||||
{
|
{
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -193,5 +193,4 @@ void
|
||||||
func_plat::func_plat(void)
|
func_plat::func_plat(void)
|
||||||
{
|
{
|
||||||
m_flSpeed = 100.0f;
|
m_flSpeed = 100.0f;
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -237,5 +237,4 @@ void
|
||||||
func_platrot::func_platrot(void)
|
func_platrot::func_platrot(void)
|
||||||
{
|
{
|
||||||
m_flSpeed = 100.0f;
|
m_flSpeed = 100.0f;
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
|
@ -170,5 +170,4 @@ func_pushable::Respawn(void)
|
||||||
void
|
void
|
||||||
func_pushable::func_pushable(void)
|
func_pushable::func_pushable(void)
|
||||||
{
|
{
|
||||||
super::func_breakable();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,6 +42,7 @@ class func_recharge:NSRenderableEntity
|
||||||
void(void) func_recharge;
|
void(void) func_recharge;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
|
@ -217,15 +218,19 @@ func_recharge::Respawn(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_recharge::func_recharge(void)
|
func_recharge::Spawned(void)
|
||||||
{
|
{
|
||||||
m_strSndFirst = "items/suitchargeok1.wav";
|
super::Spawned();
|
||||||
m_strSndCharging = "items/suitcharge1.wav";
|
|
||||||
m_strSndDone = "items/suitchargeno1.wav";
|
|
||||||
|
|
||||||
super::NSRenderableEntity();
|
|
||||||
|
|
||||||
precache_sound(m_strSndFirst);
|
precache_sound(m_strSndFirst);
|
||||||
precache_sound(m_strSndCharging);
|
precache_sound(m_strSndCharging);
|
||||||
precache_sound(m_strSndDone);
|
precache_sound(m_strSndDone);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_recharge::func_recharge(void)
|
||||||
|
{
|
||||||
|
m_strSndFirst = "items/suitchargeok1.wav";
|
||||||
|
m_strSndCharging = "items/suitcharge1.wav";
|
||||||
|
m_strSndDone = "items/suitchargeno1.wav";
|
||||||
|
}
|
||||||
|
|
|
@ -269,5 +269,4 @@ func_rot_button::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
func_rot_button::func_rot_button(void)
|
func_rot_button::func_rot_button(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -238,6 +238,4 @@ void
|
||||||
func_rotating::func_rotating(void)
|
func_rotating::func_rotating(void)
|
||||||
{
|
{
|
||||||
m_flSpeed = 100;
|
m_flSpeed = 100;
|
||||||
super::NSRenderableEntity();
|
|
||||||
Respawn();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -89,6 +89,7 @@ class func_tank:NSVehicle
|
||||||
|
|
||||||
void(void) func_tank;
|
void(void) func_tank;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(void) customphysics;
|
virtual void(void) customphysics;
|
||||||
|
@ -337,13 +338,18 @@ func_tank::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_tank::func_tank(void)
|
func_tank::Spawned(void)
|
||||||
{
|
{
|
||||||
m_iVehicleFlags |= VHF_FROZEN | VHF_NOATTACK;
|
super::Spawned();
|
||||||
super::NSVehicle();
|
|
||||||
|
|
||||||
if (m_strSpriteFlash)
|
if (m_strSpriteFlash)
|
||||||
precache_model(m_strSpriteFlash);
|
precache_model(m_strSpriteFlash);
|
||||||
if (m_strSpriteSmoke)
|
if (m_strSpriteSmoke)
|
||||||
precache_model(m_strSpriteSmoke);
|
precache_model(m_strSpriteSmoke);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_tank::func_tank(void)
|
||||||
|
{
|
||||||
|
m_iVehicleFlags |= VHF_FROZEN | VHF_NOATTACK;
|
||||||
|
}
|
||||||
|
|
|
@ -72,5 +72,4 @@ func_tankcontrols::Respawn(void)
|
||||||
void
|
void
|
||||||
func_tankcontrols::func_tankcontrols(void)
|
func_tankcontrols::func_tankcontrols(void)
|
||||||
{
|
{
|
||||||
super::NSBrushTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -63,6 +63,7 @@ class func_tracktrain:NSRenderableEntity
|
||||||
|
|
||||||
void(void) func_tracktrain;
|
void(void) func_tracktrain;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(entity, int) Trigger;
|
virtual void(entity, int) Trigger;
|
||||||
|
@ -347,16 +348,20 @@ func_tracktrain::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_tracktrain::Spawned(void)
|
||||||
|
{
|
||||||
|
super::Spawned();
|
||||||
|
|
||||||
|
if (m_strMoveSnd)
|
||||||
|
Sound_Precache(m_strMoveSnd);
|
||||||
|
if (m_strStopSnd)
|
||||||
|
Sound_Precache(m_strStopSnd);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_tracktrain::func_tracktrain(void)
|
func_tracktrain::func_tracktrain(void)
|
||||||
{
|
{
|
||||||
/* FIXME: This is all decided by the first path_corner pretty much */
|
/* FIXME: This is all decided by the first path_corner pretty much */
|
||||||
m_flSpeed = 100;
|
m_flSpeed = 100;
|
||||||
super::NSRenderableEntity();
|
|
||||||
|
|
||||||
if (m_strMoveSnd)
|
|
||||||
Sound_Precache(m_strMoveSnd);
|
|
||||||
|
|
||||||
if (m_strStopSnd)
|
|
||||||
Sound_Precache(m_strStopSnd);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,5 +43,4 @@ func_traincontrols::Respawn(void)
|
||||||
void
|
void
|
||||||
func_traincontrols::func_traincontrols(void)
|
func_traincontrols::func_traincontrols(void)
|
||||||
{
|
{
|
||||||
super::NSBrushTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -64,6 +64,8 @@ class func_train:NSRenderableEntity
|
||||||
|
|
||||||
void(void) func_train;
|
void(void) func_train;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
|
@ -298,16 +300,20 @@ func_train::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
func_train::Spawned(void)
|
||||||
|
{
|
||||||
|
super::Spawned();
|
||||||
|
|
||||||
|
if (m_strMoveSnd)
|
||||||
|
Sound_Precache(m_strMoveSnd);
|
||||||
|
if (m_strStopSnd)
|
||||||
|
Sound_Precache(m_strStopSnd);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
func_train::func_train(void)
|
func_train::func_train(void)
|
||||||
{
|
{
|
||||||
/* FIXME: This is all decided by the first path_corner pretty much */
|
/* FIXME: This is all decided by the first path_corner pretty much */
|
||||||
m_flSpeed = 100;
|
m_flSpeed = 100;
|
||||||
super::NSRenderableEntity();
|
|
||||||
|
|
||||||
if (m_strMoveSnd)
|
|
||||||
Sound_Precache(m_strMoveSnd);
|
|
||||||
|
|
||||||
if (m_strStopSnd)
|
|
||||||
Sound_Precache(m_strStopSnd);
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -579,8 +579,6 @@ func_vehicle::func_vehicle(void)
|
||||||
m_vecGravityDir = [0,0,-1];
|
m_vecGravityDir = [0,0,-1];
|
||||||
m_iVehicleFlags |= VHF_FROZEN;
|
m_iVehicleFlags |= VHF_FROZEN;
|
||||||
|
|
||||||
super::NSVehicle();
|
|
||||||
|
|
||||||
m_wlFL = spawn(func_vehicle_wheel);
|
m_wlFL = spawn(func_vehicle_wheel);
|
||||||
m_wlFR = spawn(func_vehicle_wheel);
|
m_wlFR = spawn(func_vehicle_wheel);
|
||||||
m_wlBL = spawn(func_vehicle_wheel);
|
m_wlBL = spawn(func_vehicle_wheel);
|
||||||
|
|
|
@ -85,7 +85,7 @@ func_wall_toggle::Trigger(entity act, int state)
|
||||||
|
|
||||||
if (m_iVisible) {
|
if (m_iVisible) {
|
||||||
SetSolid(SOLID_BSP);
|
SetSolid(SOLID_BSP);
|
||||||
SetModelindex(m_oldmodelindex);
|
SetModel(GetSpawnModel());
|
||||||
} else {
|
} else {
|
||||||
SetSolid(SOLID_NOT);
|
SetSolid(SOLID_NOT);
|
||||||
SetModelindex(0);
|
SetModelindex(0);
|
||||||
|
@ -124,5 +124,4 @@ func_wall_toggle::Input(entity eAct, string strInput, string strData)
|
||||||
void
|
void
|
||||||
func_wall_toggle::func_wall_toggle(void)
|
func_wall_toggle::func_wall_toggle(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -146,5 +146,4 @@ void
|
||||||
game_counter::game_counter(void)
|
game_counter::game_counter(void)
|
||||||
{
|
{
|
||||||
m_iStartCount = 0;
|
m_iStartCount = 0;
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -112,5 +112,4 @@ void
|
||||||
game_counter_set::game_counter_set(void)
|
game_counter_set::game_counter_set(void)
|
||||||
{
|
{
|
||||||
m_iCount = 0;
|
m_iCount = 0;
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -155,5 +155,4 @@ game_player_equip::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
game_player_equip::game_player_equip(void)
|
game_player_equip::game_player_equip(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -194,5 +194,4 @@ game_text::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
game_text::game_text(void)
|
game_text::game_text(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,5 +47,4 @@ void gibshooter2::gibshooter2(void)
|
||||||
m_flScale = 1.0;
|
m_flScale = 1.0;
|
||||||
|
|
||||||
precache_model(m_strShootModel);
|
precache_model(m_strShootModel);
|
||||||
super::env_shooter();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,5 +39,4 @@ class info_intermission:NSPointTrigger
|
||||||
void
|
void
|
||||||
info_intermission::info_intermission(void)
|
info_intermission::info_intermission(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,5 +40,4 @@ class info_notnull:NSPointTrigger
|
||||||
void
|
void
|
||||||
info_notnull::info_notnull(void)
|
info_notnull::info_notnull(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -68,9 +68,7 @@ info_null::Respawn(void)
|
||||||
void
|
void
|
||||||
info_null::info_null(void)
|
info_null::info_null(void)
|
||||||
{
|
{
|
||||||
#ifdef DEBUG_INFONULL
|
#ifndef DEBUG_INFONULL
|
||||||
super::NSPointTrigger();
|
|
||||||
#else
|
|
||||||
remove(self);
|
remove(self);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
@ -141,6 +141,4 @@ infodecal::infodecal(void)
|
||||||
remove(self);
|
remove(self);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -247,8 +247,6 @@ light::light(void)
|
||||||
m_flStyle = 0;
|
m_flStyle = 0;
|
||||||
m_flSwitchStyle = 0;
|
m_flSwitchStyle = 0;
|
||||||
|
|
||||||
super::NSPointTrigger();
|
|
||||||
|
|
||||||
/* switch styles before 12 are builtins from Quake. */
|
/* switch styles before 12 are builtins from Quake. */
|
||||||
if (m_flSwitchStyle > 0 && m_flSwitchStyle <= 11) {
|
if (m_flSwitchStyle > 0 && m_flSwitchStyle <= 11) {
|
||||||
m_strPattern = getlightstyle(m_flSwitchStyle);
|
m_strPattern = getlightstyle(m_flSwitchStyle);
|
||||||
|
|
|
@ -66,6 +66,7 @@ class logic_auto:NSPointTrigger
|
||||||
void(void) logic_auto;
|
void(void) logic_auto;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
|
virtual void(void) Spawned;
|
||||||
virtual void(float) Save;
|
virtual void(float) Save;
|
||||||
virtual void(string, string) Restore;
|
virtual void(string, string) Restore;
|
||||||
virtual void(void) Respawn;
|
virtual void(void) Respawn;
|
||||||
|
@ -204,11 +205,9 @@ logic_auto::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
logic_auto::logic_auto(void)
|
logic_auto::Spawned(void)
|
||||||
{
|
{
|
||||||
m_iFromSaveGame = 0;
|
super::Spawned();
|
||||||
|
|
||||||
super::NSPointTrigger();
|
|
||||||
|
|
||||||
if (m_strOnMapSpawn)
|
if (m_strOnMapSpawn)
|
||||||
m_strOnMapSpawn = CreateOutput(m_strOnMapSpawn);
|
m_strOnMapSpawn = CreateOutput(m_strOnMapSpawn);
|
||||||
|
@ -225,3 +224,9 @@ logic_auto::logic_auto(void)
|
||||||
if (m_strOnMultiNewRound)
|
if (m_strOnMultiNewRound)
|
||||||
m_strOnMultiNewRound = CreateOutput(m_strOnMultiNewRound);
|
m_strOnMultiNewRound = CreateOutput(m_strOnMultiNewRound);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
logic_auto::logic_auto(void)
|
||||||
|
{
|
||||||
|
m_iFromSaveGame = 0;
|
||||||
|
}
|
||||||
|
|
|
@ -138,5 +138,4 @@ momentary_door::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
momentary_door::momentary_door(void)
|
momentary_door::momentary_door(void)
|
||||||
{
|
{
|
||||||
super::NSMomentary();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -263,5 +263,4 @@ void
|
||||||
momentary_rot_button::momentary_rot_button(void)
|
momentary_rot_button::momentary_rot_button(void)
|
||||||
{
|
{
|
||||||
m_flReturnspeed = m_flSpeed = -1;
|
m_flReturnspeed = m_flSpeed = -1;
|
||||||
super::NSMomentary();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -121,5 +121,4 @@ NSMomentary::Restore(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
NSMomentary::NSMomentary(void)
|
NSMomentary::NSMomentary(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -58,7 +58,6 @@ monster_furniture::Respawn(void)
|
||||||
void
|
void
|
||||||
monster_furniture::monster_furniture(void)
|
monster_furniture::monster_furniture(void)
|
||||||
{
|
{
|
||||||
super::NSMonster();
|
|
||||||
spawnflags |= MSF_MULTIPLAYER;
|
spawnflags |= MSF_MULTIPLAYER;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -64,5 +64,4 @@ monster_generic::monster_generic(void)
|
||||||
base_health = 100;
|
base_health = 100;
|
||||||
|
|
||||||
spawnflags |= MSF_MULTIPLAYER;
|
spawnflags |= MSF_MULTIPLAYER;
|
||||||
super::NSTalkMonster();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -271,5 +271,4 @@ void
|
||||||
monstermaker::monstermaker(void)
|
monstermaker::monstermaker(void)
|
||||||
{
|
{
|
||||||
m_flDelay = 1.0f;
|
m_flDelay = 1.0f;
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -78,7 +78,9 @@ multi_manager_sub::Restore(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
multi_manager_sub::multi_manager_sub(void)
|
multi_manager_sub::multi_manager_sub(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
m_eActivator = __NULL__;
|
||||||
|
m_iValue = 0;
|
||||||
|
m_flUntilTriggered = 0.0f;
|
||||||
}
|
}
|
||||||
|
|
||||||
class multi_manager:NSPointTrigger
|
class multi_manager:NSPointTrigger
|
||||||
|
@ -88,6 +90,8 @@ class multi_manager:NSPointTrigger
|
||||||
int m_iBusy;
|
int m_iBusy;
|
||||||
int m_iValue;
|
int m_iValue;
|
||||||
|
|
||||||
|
virtual void(void) Spawned;
|
||||||
|
|
||||||
/* overrides */
|
/* overrides */
|
||||||
virtual void(entity, int) Trigger;
|
virtual void(entity, int) Trigger;
|
||||||
virtual void(string, string) SpawnKey;
|
virtual void(string, string) SpawnKey;
|
||||||
|
@ -251,6 +255,9 @@ multi_manager::SpawnKey(string strKey, string strValue)
|
||||||
case "spawnflags":
|
case "spawnflags":
|
||||||
case "angle":
|
case "angle":
|
||||||
case "angles":
|
case "angles":
|
||||||
|
case "target":
|
||||||
|
case "spawnflags":
|
||||||
|
super::SpawnKey(strKey, strValue);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
if (substring(strKey, strlen(strKey) - 3, 1) == "#") {
|
if (substring(strKey, strlen(strKey) - 3, 1) == "#") {
|
||||||
|
@ -272,13 +279,12 @@ multi_manager::SpawnKey(string strKey, string strValue)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
multi_manager::multi_manager(void)
|
multi_manager::Spawned(void)
|
||||||
{
|
{
|
||||||
int iFields;
|
int iFields;
|
||||||
int b;
|
int b;
|
||||||
m_strBuffer = "";
|
|
||||||
|
|
||||||
super::NSPointTrigger();
|
super::Spawned();
|
||||||
|
|
||||||
for (b = 0; b < 16; b++) {
|
for (b = 0; b < 16; b++) {
|
||||||
m_eTriggers[b] = spawn(multi_manager_sub);
|
m_eTriggers[b] = spawn(multi_manager_sub);
|
||||||
|
@ -304,3 +310,14 @@ multi_manager::multi_manager(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
multi_manager::multi_manager(void)
|
||||||
|
{
|
||||||
|
for (int i = 0; i < 16; i++)
|
||||||
|
m_eTriggers[i] = __NULL__;
|
||||||
|
|
||||||
|
m_strBuffer = __NULL__;
|
||||||
|
m_iBusy =
|
||||||
|
m_iValue = 0;
|
||||||
|
}
|
||||||
|
|
|
@ -143,5 +143,4 @@ void
|
||||||
multisource::multisource(void)
|
multisource::multisource(void)
|
||||||
{
|
{
|
||||||
m_strGlobalState = __NULL__;
|
m_strGlobalState = __NULL__;
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -146,5 +146,4 @@ path_corner::path_corner(void)
|
||||||
{
|
{
|
||||||
m_flWait = 1.0f;
|
m_flWait = 1.0f;
|
||||||
m_flSpeed = 100.0f;
|
m_flSpeed = 100.0f;
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -140,5 +140,4 @@ player_loadsaved::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
player_loadsaved::player_loadsaved(void)
|
player_loadsaved::player_loadsaved(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,5 +51,4 @@ player_weaponstrip::Trigger(entity act, int unused)
|
||||||
void
|
void
|
||||||
player_weaponstrip::player_weaponstrip(void)
|
player_weaponstrip::player_weaponstrip(void)
|
||||||
{
|
{
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -166,6 +166,4 @@ void
|
||||||
point_camera::point_camera(void)
|
point_camera::point_camera(void)
|
||||||
{
|
{
|
||||||
m_flFOV = 90;
|
m_flFOV = 90;
|
||||||
|
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -164,5 +164,4 @@ prop_door_rotating::prop_door_rotating(void)
|
||||||
{
|
{
|
||||||
m_flDistance = 90;
|
m_flDistance = 90;
|
||||||
m_flSpeed = 100;
|
m_flSpeed = 100;
|
||||||
super::NSPointTrigger();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,5 +74,4 @@ prop_dynamic::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
prop_dynamic::prop_dynamic(void)
|
prop_dynamic::prop_dynamic(void)
|
||||||
{
|
{
|
||||||
super::NSSurfacePropEntity();
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -56,7 +56,6 @@ prop_physics::SpawnKey(string strKey, string strValue)
|
||||||
void
|
void
|
||||||
prop_physics::prop_physics(void)
|
prop_physics::prop_physics(void)
|
||||||
{
|
{
|
||||||
super::NSPhysicsEntity();
|
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
class prop_physics:NSRenderableEntity
|
class prop_physics:NSRenderableEntity
|
||||||
|
@ -75,6 +74,5 @@ prop_physics::Respawn(void)
|
||||||
void
|
void
|
||||||
prop_physics::prop_physics(void)
|
prop_physics::prop_physics(void)
|
||||||
{
|
{
|
||||||
super::NSRenderableEntity();
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue