Add decore_labstuff, decore_sack and it'll apparently attach to monster_tube_embryo

This commit is contained in:
Marco Cawthorne 2022-07-23 14:26:52 -07:00
parent c1e464d218
commit 29d3404bb0
Signed by: eukara
GPG Key ID: CE2032F0A2882A22
4 changed files with 124 additions and 4 deletions

View File

@ -0,0 +1,38 @@
/*
* Copyright (c) 2016-2022 Marco Cawthorne <marco@icculus.org>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
* IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/*QUAKED decore_labstuff (0 0.8 0.8) (-16 -16 0) (16 16 64)
This is a decorative entity from Gunman Chronicles.
-------- KEYS --------
"targetname" : Name
-------- MODEL FOR RADIANT ONLY - DO NOT SET THIS AS A KEY --------
model="models/swampstuff.mdl"
*/
class decore_labstuff:RWDecore
{
void(void) decore_labstuff;
};
void
decore_labstuff::decore_labstuff(void)
{
model = "models/labstuff.mdl";
mins = [-16, -16, 0];
maxs = [16, 16, 64];
}

46
src/server/decore_sack.qc Normal file
View File

@ -0,0 +1,46 @@
/*
* Copyright (c) 2016-2022 Marco Cawthorne <marco@icculus.org>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
* IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/*QUAKED decore_sack (0 0.8 0.8) (-16 -16 0) (16 16 64)
This is a decorative entity from Gunman Chronicles.
-------- KEYS --------
"targetname" : Name
-------- MODEL FOR RADIANT ONLY - DO NOT SET THIS AS A KEY --------
model="models/sack.mdl"
*/
class decore_sack:RWDecore
{
void(void) decore_sack;
virtual void(void) Respawn;
};
void
decore_sack::Respawn(void)
{
super::Respawn();
SetMovetype(MOVETYPE_NONE);
}
void
decore_sack::decore_sack(void)
{
model = "models/sack.mdl";
mins = [-16, -16, 0];
maxs = [16, 16, 64];
}

View File

@ -14,7 +14,7 @@
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/*QUAKED monster_tube_embryo (0 0.8 0.8) (-16 -16 0) (16 16 72)
/*QUAKED monster_tube_embryo (0 0.8 0.8) (-12 -12 -16) (16 16 24)
This is a monster entity from Gunman Chronicles.
-------- KEYS --------
@ -26,13 +26,47 @@ model="models/tubryo.mdl"
class monster_tube_embryo:NSMonster
{
decore_sack sack;
void(void) monster_tube_embryo;
virtual void(void) ParentUpdate;
virtual void(void) Spawned;
virtual void(void) Respawn;
};
void
monster_tube_embryo:: monster_tube_embryo(void)
monster_tube_embryo::ParentUpdate(void)
{
super::ParentUpdate();
sack.SetOrigin(GetOrigin());
sack.SetAngles(GetAngles());
}
void
monster_tube_embryo::Spawned(void)
{
super::Spawned();
if (!sack)
sack = spawn(decore_sack);
sack.SetRenderMode(RM_COLOR);
sack.SetRenderAmt(0.75f);
}
void
monster_tube_embryo::Respawn(void)
{
SetModel(GetSpawnModel());
SetMovetype(MOVETYPE_FLY);
SetOrigin(GetSpawnOrigin());
}
void
monster_tube_embryo::monster_tube_embryo(void)
{
model = "models/tubryo.mdl";
base_mins = [-16,-16,0];
base_maxs = [16,16,72];
base_mins = [-12,-12,-16];
base_maxs = [12,12,24];
}

View File

@ -36,6 +36,7 @@ decore_gutspile.qc
decore_hatgib.qc
decore_ice.qc
decore_icebeak.qc
decore_labstuff.qc
decore_mushroom.qc
decore_mushroom2.qc
decore_nest.qc
@ -43,6 +44,7 @@ decore_pipes.qc
decore_prickle.qc
decore_pteradon.qc
decore_sittingtubemortar.qc
decore_sack.qc
decore_swampplants.qc
decore_torchflame.qc
decore_torch.qc