2016-12-01 17:50:48 +00:00
|
|
|
/*
|
2017-04-30 23:21:49 +00:00
|
|
|
FreeCS Project
|
2017-01-07 20:18:15 +00:00
|
|
|
Copyright (C) 2016, 2017 Marco "eukara" Hladik
|
2016-12-01 17:50:48 +00:00
|
|
|
|
|
|
|
This program is free software; you can redistribute it and/or
|
|
|
|
modify it under the terms of the GNU General Public License
|
|
|
|
as published by the Free Software Foundation; either version 2
|
|
|
|
of the License, or (at your option) any later version.
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
|
|
|
|
See the GNU General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with this program; if not, write to the Free Software
|
|
|
|
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
2016-12-04 14:04:30 +00:00
|
|
|
/*
|
|
|
|
=================
|
|
|
|
CSQC_Init
|
|
|
|
|
|
|
|
Comparable to worldspawn in SSQC in that it's mostly used for precaches
|
|
|
|
=================
|
|
|
|
*/
|
2016-12-01 17:50:48 +00:00
|
|
|
void CSQC_Init(float apilevel, string enginename, float engineversion) {
|
|
|
|
precache_model( HUD_NUMFILE );
|
2017-01-12 02:49:59 +00:00
|
|
|
|
2017-07-01 00:39:15 +00:00
|
|
|
precache_model( "sprites/top_left.spr" );
|
|
|
|
precache_model( "sprites/top.spr" );
|
|
|
|
precache_model( "sprites/top_right.spr" );
|
|
|
|
precache_model( "sprites/left.spr" );
|
|
|
|
precache_model( "sprites/right.spr" );
|
|
|
|
precache_model( "sprites/bottom_left.spr" );
|
|
|
|
precache_model( "sprites/bottom.spr" );
|
|
|
|
precache_model( "sprites/bottom_right.spr" );
|
|
|
|
|
|
|
|
precache_model( "sprites/sniper_scope.spr" );
|
2017-06-21 19:07:23 +00:00
|
|
|
precache_model( "sprites/fexplo.spr" );
|
2017-01-12 02:49:59 +00:00
|
|
|
precache_model( "sprites/muzzleflash1.spr" );
|
2016-12-17 12:55:18 +00:00
|
|
|
precache_model( "sprites/radar640.spr" );
|
2016-12-09 23:03:13 +00:00
|
|
|
precache_model( "sprites/640hud1.spr" );
|
|
|
|
precache_model( "sprites/640hud16.spr" );
|
2016-12-01 17:50:48 +00:00
|
|
|
|
2016-12-11 13:17:00 +00:00
|
|
|
precache_model( "sprites/640hud2.spr" );
|
|
|
|
precache_model( "sprites/640hud10.spr" );
|
|
|
|
precache_model( "sprites/640hud12.spr" );
|
|
|
|
precache_model( "sprites/640hud14.spr" );
|
|
|
|
precache_model( "sprites/640hud3.spr" );
|
|
|
|
|
|
|
|
precache_sound( "common/wpn_hudon.wav" );
|
|
|
|
precache_sound( "common/wpn_hudoff.wav" );
|
|
|
|
precache_sound( "common/wpn_moveselect.wav" );
|
|
|
|
precache_sound( "common/wpn_select.wav" );
|
|
|
|
|
2017-01-10 18:24:45 +00:00
|
|
|
precache_sound( "debris/bustglass1.wav" );
|
|
|
|
precache_sound( "debris/bustglass2.wav" );
|
2017-01-14 15:00:31 +00:00
|
|
|
precache_sound( "debris/bustglass3.wav" );
|
2017-01-10 18:24:45 +00:00
|
|
|
precache_sound( "debris/bustcrate1.wav" );
|
|
|
|
precache_sound( "debris/bustcrate2.wav" );
|
2017-01-14 15:00:31 +00:00
|
|
|
precache_sound( "debris/bustcrate3.wav" );
|
2017-01-10 18:24:45 +00:00
|
|
|
precache_sound( "debris/bustmetal1.wav" );
|
|
|
|
precache_sound( "debris/bustmetal2.wav" );
|
|
|
|
precache_sound( "debris/bustflesh1.wav" );
|
|
|
|
precache_sound( "debris/bustflesh2.wav" );
|
|
|
|
precache_sound( "debris/bustconcrete1.wav" );
|
|
|
|
precache_sound( "debris/bustconcrete2.wav" );
|
2017-01-14 15:00:31 +00:00
|
|
|
precache_sound( "debris/bustceiling.wav" );
|
2017-01-10 18:24:45 +00:00
|
|
|
|
2017-01-12 02:49:59 +00:00
|
|
|
for ( int i = 0; i < ( CS_WEAPON_COUNT - 1 ); i++ ) {
|
2016-12-01 17:50:48 +00:00
|
|
|
precache_model( sViewModels[ i ] );
|
|
|
|
}
|
2017-03-04 20:08:59 +00:00
|
|
|
|
2017-01-07 16:29:27 +00:00
|
|
|
PARTICLE_SPARK = particleeffectnum( "part_spark" );
|
|
|
|
PARTICLE_PIECES_BLACK = particleeffectnum( "part_pieces_black" );
|
|
|
|
PARTICLE_SMOKE_GREY = particleeffectnum( "part_smoke_grey" );
|
|
|
|
PARTICLE_SMOKE_BROWN = particleeffectnum( "part_smoke_brown" );
|
|
|
|
PARTICLE_BLOOD = particleeffectnum( "part_blood" );
|
2017-01-15 19:56:58 +00:00
|
|
|
DECAL_SHOT = particleeffectnum( "decal_shot" );
|
2017-03-04 16:08:17 +00:00
|
|
|
DECAL_GLASS = particleeffectnum( "decal_glass" );
|
2017-07-02 20:49:22 +00:00
|
|
|
PARTICLE_SMOKEGRENADE = particleeffectnum( "smokegren" );
|
2017-06-24 12:36:36 +00:00
|
|
|
|
|
|
|
FONT_16 = loadfont( "16", "gfx/conchars_16", "16", -1 );
|
2017-07-02 20:49:22 +00:00
|
|
|
|
|
|
|
SHADER_CULLED = shaderforname( "mirror_cull" );
|
2017-01-08 14:11:34 +00:00
|
|
|
|
2016-12-07 19:38:26 +00:00
|
|
|
Radio_InitSounds();
|
|
|
|
|
2016-12-01 17:50:48 +00:00
|
|
|
CSQC_ConsoleCommand_Init();
|
|
|
|
CSQC_VGUI_Init();
|
|
|
|
}
|
|
|
|
|
2016-12-04 14:04:30 +00:00
|
|
|
/*
|
|
|
|
=================
|
|
|
|
CSQC_WorldLoaded
|
|
|
|
|
|
|
|
Whenever the world is fully initialized...
|
|
|
|
=================
|
|
|
|
*/
|
2016-12-01 17:50:48 +00:00
|
|
|
void CSQC_WorldLoaded( void ) {
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2016-12-04 14:04:30 +00:00
|
|
|
/*
|
|
|
|
=================
|
|
|
|
CSQC_Shutdown
|
|
|
|
|
|
|
|
Incase you need to free something
|
|
|
|
=================
|
|
|
|
*/
|
2016-12-01 17:50:48 +00:00
|
|
|
void CSQC_Shutdown( void ) {
|
|
|
|
|
|
|
|
}
|