From cbaec17b4fde2c4114bd99bcd54fac55e23300d3 Mon Sep 17 00:00:00 2001 From: MirceaKitsune Date: Sat, 30 Jul 2011 15:08:35 +0300 Subject: [PATCH] Implement constant particles falling off regurgitated prey, until the green goo color washes off. The amount of green goo on the player also determines how often particles are generated. --- data/defaultVT.cfg | 1 + data/effectinfo.txt | 26 ++++++++++++++++++++++++++ data/qcsrc/server/vore.qc | 34 +++++++++++++++++++++++----------- 3 files changed, 50 insertions(+), 11 deletions(-) diff --git a/data/defaultVT.cfg b/data/defaultVT.cfg index 1b38df56..6e51de39 100644 --- a/data/defaultVT.cfg +++ b/data/defaultVT.cfg @@ -1601,6 +1601,7 @@ set g_vore_soundocclusion 0.25 "directional player sounds are cut to this amount set g_vore_regurgitatecolor_release "0.6 0.4 0" "the color players will have when regurgitated alive" set g_vore_regurgitatecolor_release_fade 0.01 "how quickly the regurgitation color washes off players once they leave the stomach" set g_vore_regurgitatecolor_digest "0.3 0.15 0" "the color players will have when digested, only works when g_vore_keepdeadprey is disabled" +set g_vore_regurgitatecolor_particles 1 "players that have a regurgitate color applied generate particles this often, based on how washed away the goo is" set g_vore_keepdeadprey 0.75 "If enabled, prey remains in the stomach after dying, else the predator throws up their dead body. 0 = disabled, 1 = ernabled, anything between = probability" set g_vore_neighborprey_distance 8 "Distance by which prey inside the same stomach are positioned away from each other. 0 disables seeing neighboring prey" set g_vore_neighborprey_scale 1 "When neighborprey is enabled, all prey is resized by this amount" diff --git a/data/effectinfo.txt b/data/effectinfo.txt index f4d92003..e4c850df 100644 --- a/data/effectinfo.txt +++ b/data/effectinfo.txt @@ -4845,3 +4845,29 @@ size 25 30 alpha 100 256 400 color 0x000000 0x408000 originjitter 110 110 110 + +// constant regurgitate effect +// used in: vore.qc: pointparticles(particleeffectnum("regurgitate"), e.predator.origin, '0 0 0', 1) +effect vore_regurgitate_constant +count 5 +type blood +tex 24 32 +size 8 20 +alpha 512 512 128 +color 0x9B9BCD 0x3769CD +bounce -1 +airfriction 1 +liquidfriction 4 +velocityjitter 128 128 32 +velocitymultiplier 4 +staincolor 0x408000 0x80FF00 +staintex 16 24 +//green mist +effect vore_regurgitate_constant +countabsolute 5 +type alphastatic +tex 0 8 +size 20 25 +alpha 100 256 400 +color 0x000000 0x408000 +originjitter 110 110 110 diff --git a/data/qcsrc/server/vore.qc b/data/qcsrc/server/vore.qc index febc062e..6e333e1d 100644 --- a/data/qcsrc/server/vore.qc +++ b/data/qcsrc/server/vore.qc @@ -662,6 +662,7 @@ void Vore_SetSbarRings() } } +.float regurgitatecolor_particles_tick; void Vore() { // main vore code, this is where it all happens @@ -672,17 +673,28 @@ void Vore() if(!self.stat_eaten) if(stov(cvar_string("g_vore_regurgitatecolor_release"))) if(self.colormod) - if(cvar("g_vore_regurgitatecolor_release_fade")) - { - self.colormod_x += cvar("g_vore_regurgitatecolor_release_fade") * frametime; - if(self.colormod_x > 1) - self.colormod_x = 1; - self.colormod_y += cvar("g_vore_regurgitatecolor_release_fade") * frametime; - if(self.colormod_y > 1) - self.colormod_y = 1; - self.colormod_z += cvar("g_vore_regurgitatecolor_release_fade") * frametime; - if(self.colormod_z > 1) - self.colormod_z = 1; + if(self.colormod != '1 1 1') + { + if(cvar("g_vore_regurgitatecolor_release_fade")) + { + self.colormod_x += cvar("g_vore_regurgitatecolor_release_fade") * frametime; + if(self.colormod_x > 1) + self.colormod_x = 1; + self.colormod_y += cvar("g_vore_regurgitatecolor_release_fade") * frametime; + if(self.colormod_y > 1) + self.colormod_y = 1; + self.colormod_z += cvar("g_vore_regurgitatecolor_release_fade") * frametime; + if(self.colormod_z > 1) + self.colormod_z = 1; + } + + if(cvar("g_vore_regurgitatecolor_particles")) + if(self.regurgitatecolor_particles_tick < time) + { + pointparticles(particleeffectnum("vore_regurgitate_constant"), self.origin, '0 0 0', 1); + self.regurgitatecolor_particles_tick = time + cvar("g_vore_regurgitatecolor_particles") * vlen(self.colormod); + dprint(strcat(ftos(cvar("g_vore_regurgitatecolor_particles") * vlen(self.colormod)), " --------\n")); + } } // set all vore stats -- 2.39.2