r70 - trunk/basezym/progsqc
DONOTREPLY at icculus.org
DONOTREPLY at icculus.org
Wed Jul 25 21:01:23 EDT 2007
Author: Vermeulen
Date: 2007-07-25 21:01:22 -0400 (Wed, 25 Jul 2007)
New Revision: 70
Modified:
trunk/basezym/progsqc/jumppads.qc
trunk/basezym/progsqc/player.qc
Log:
Jumppads working correctly
Modified: trunk/basezym/progsqc/jumppads.qc
===================================================================
--- trunk/basezym/progsqc/jumppads.qc 2007-07-25 03:04:51 UTC (rev 69)
+++ trunk/basezym/progsqc/jumppads.qc 2007-07-26 01:01:22 UTC (rev 70)
@@ -101,29 +101,24 @@
void() trigger_push_touch =
{
+ if (other.classname != "player")
+ return;
- if (other.deadflag && other.classname == "player")
- return;
-
if (!self.target)
{
other.velocity = self.movedir;
other.flags = other.flags - (other.flags & FL_ONGROUND);
return;
}
+
+ te_smallflash(other.origin);
- if (other.classname == "player")
- {
- if(self.pushltime < time) // prevent "snorring" sound when a player hits the jumppad more than once
- {
- sound (other, CHAN_ITEM, "misc/jumppad.wav", 1, ATTN_NORM);
- self.pushltime = time + 0.2;
- }
- }
-
self.movedir = trigger_push_calculatevelocity(other.origin, self.enemy, self.height);
other.flags = other.flags - (other.flags & FL_ONGROUND);
+
+ // reset tracking of oldvelocity for impact damage (sudden velocity changes)
+ other.oldvelocity = other.velocity = self.movedir;
if (self.spawnflags & PUSH_ONCE)
{
@@ -177,6 +172,8 @@
*/
void() trigger_push =
{
+ bprint("BOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO \n \n \n \n");
+
if (self.angles != '0 0 0')
SetMovedir ();
@@ -203,4 +200,4 @@
void() target_push = {};
void() info_notnull = {};
-void() target_position = {};
+void() target_position = {};
\ No newline at end of file
Modified: trunk/basezym/progsqc/player.qc
===================================================================
--- trunk/basezym/progsqc/player.qc 2007-07-25 03:04:51 UTC (rev 69)
+++ trunk/basezym/progsqc/player.qc 2007-07-26 01:01:22 UTC (rev 70)
@@ -488,7 +488,6 @@
if (self.button5)
{
self.jetpackfuel = max(0, self.jetpackfuel - 80 * frametime);
- bprint(ftos(self.jetpackfuel), "\n");
//self.armorregentime = max(self.armorregentime, time + ACTOR_SHIELD_REGENDELAY);
//self.armorregenplaysound = TRUE;
if (!self.jetpackactive)
More information about the zymotic-commits
mailing list