Began working on Rocket Launcher.

Corrected some stuff and tweaked models and offsets again.
Added gib impact sounds (Droplets compat).
Made Translocator module throwing work like in UT (same math, even).
Corrected sludge wall sticking, uses projection now rather than a cheap trace.
This commit is contained in:
Marisa the Magician 2018-05-30 01:36:38 +02:00
commit a6ccec0997
19 changed files with 356 additions and 60 deletions

View file

@ -81,8 +81,9 @@ Model "UTRocketLauncher"
SurfaceSkin 0 3 "Eight_t4.png" SurfaceSkin 0 3 "Eight_t4.png"
SurfaceSkin 0 4 "miniammoledbase.png" SurfaceSkin 0 4 "miniammoledbase.png"
Scale -0.24 0.12 0.24 Scale -0.24 0.12 0.24
Offset 2.0 -11.0 -9.5 Offset 2.0 -12.0 -10.5
AngleOffset 90 AngleOffset 90
RollOffset -3
// Select // Select
FrameIndex EBLS A 0 0 FrameIndex EBLS A 0 0

View file

@ -742,7 +742,7 @@ Model "FlakCannon"
AngleOffset 90 AngleOffset 90
PitchOffset 90 PitchOffset 90
Scale 0.08 0.08 0.08 Scale 0.08 0.08 0.08
Offset 7.4 -25.0 -7.5 Offset 7.4 -25.0 -8.5
FrameIndex FMUZ A 2 0 FrameIndex FMUZ A 2 0
} }
@ -758,9 +758,9 @@ Model "FlakCannon"
SurfaceSkin 0 4 "flakammoledbase.png" SurfaceSkin 0 4 "flakammoledbase.png"
AngleOffset 90 AngleOffset 90
PitchOffset 180 PitchOffset 180
RollOffset 174.375 RollOffset 178
Scale 0.28 -0.14 0.28 Scale 0.28 -0.14 0.28
Offset 8.6 -10.4 -12.8 Offset 8.6 -10.4 -13.8
// select // select
FrameIndex FLKS A 0 0 FrameIndex FLKS A 0 0

View file

@ -16,7 +16,7 @@ Model "BioGel"
Path "models" Path "models"
Model 0 "BioGelm_d.3d" Model 0 "BioGelm_d.3d"
Skin 0 "Jgreen.png" Skin 0 "Jgreen.png"
Scale 0.08 0.096 0.08 Scale 0.096 0.08 0.08
PitchOffset -90 PitchOffset -90
USEACTORPITCH USEACTORPITCH
USEACTORROLL USEACTORROLL
@ -88,7 +88,7 @@ Model "BioSplash"
Path "models" Path "models"
Model 0 "BioGelm_d.3d" Model 0 "BioGelm_d.3d"
Skin 0 "Jgreen.png" Skin 0 "Jgreen.png"
Scale 0.08 0.096 0.08 Scale 0.096 0.08 0.08
PitchOffset -90 PitchOffset -90
USEACTORPITCH USEACTORPITCH
USEACTORROLL USEACTORROLL
@ -160,7 +160,7 @@ Model "BioGlob"
Path "models" Path "models"
Model 0 "BioGelm_d.3d" Model 0 "BioGelm_d.3d"
Skin 0 "Jgreen.png" Skin 0 "Jgreen.png"
Scale 0.08 0.096 0.08 Scale 0.096 0.08 0.08
PitchOffset -90 PitchOffset -90
USEACTORPITCH USEACTORPITCH
USEACTORROLL USEACTORROLL

View file

@ -181,7 +181,7 @@ Model "PulseGun"
AngleOffset 90 AngleOffset 90
PitchOffset 90 PitchOffset 90
Scale 0.08 0.08 0.08 Scale 0.08 0.08 0.08
Offset 8.5 -25.0 -4.5 Offset 8.5 -25.0 -3.5
FrameIndex PMUZ A 2 0 FrameIndex PMUZ A 2 0
} }
@ -195,7 +195,7 @@ Model "PulseGun"
SurfaceSkin 0 2 "JPulseGun_03.png" SurfaceSkin 0 2 "JPulseGun_03.png"
AngleOffset 90 AngleOffset 90
Scale 0.26 -0.195 0.26 Scale 0.26 -0.195 0.26
Offset 0.0 -7.5 -8.0 Offset 0.0 -7.5 -7.0
// Select // Select
FrameIndex PGNS A 0 2 FrameIndex PGNS A 0 2

View file

@ -28,7 +28,7 @@ Model "Ripper2"
Skin 1 "JRazorw.png" Skin 1 "JRazorw.png"
Scale 0.2 0.2 0.24 Scale 0.2 0.2 0.24
AngleOffset 90 AngleOffset 90
ZOffset 6 ZOffset 10
FrameIndex RZRP B 1 0 FrameIndex RZRP B 1 0
} }
@ -86,7 +86,7 @@ Model "Ripper2"
SurfaceSkin 0 3 "JRazor5.png" SurfaceSkin 0 3 "JRazor5.png"
SurfaceSkin 0 4 "JRazor3.png" SurfaceSkin 0 4 "JRazor3.png"
Scale 0.16 -0.08 0.16 Scale 0.16 -0.08 0.16
Offset 6.4 -9.8 -7.9 Offset 6.4 -9.8 -8.4
AngleOffset 90 AngleOffset 90
// Select // Select

View file

@ -33,7 +33,7 @@ Model "Translocator"
SurfaceSkin 1 1 "tloc2_.png" SurfaceSkin 1 1 "tloc2_.png"
Scale 0.046 0.046 0.0552 Scale 0.046 0.046 0.0552
AngleOffset -90 AngleOffset -90
ZOffset 6 ZOffset 1
FrameIndex TLCP B 1 0 FrameIndex TLCP B 1 0
} }
@ -48,8 +48,9 @@ Model "Translocator"
SurfaceSkin 0 3 "tloc4.png" SurfaceSkin 0 3 "tloc4.png"
Scale 0.11 -0.055 0.11 Scale 0.11 -0.055 0.11
Offset -19.8 -22.8 -31.2 Offset -19.8 -22.8 -31.2
AngleOffset -94.21875 AngleOffset -95
PitchOffset 3.55555555556 PitchOffset 5
RollOffset -5
// select // select
FrameIndex TLCS A 0 18 FrameIndex TLCS A 0 18

View file

@ -120,6 +120,14 @@ misc/gibbed5 gib5
$random misc/gibbed { misc/gibbed1 misc/gibbed2 misc/gibbed3 misc/gibbed4 misc/gibbed5 } $random misc/gibbed { misc/gibbed1 misc/gibbed2 misc/gibbed3 misc/gibbed4 misc/gibbed5 }
// universal gibs compat // universal gibs compat
$alias UniversalGibs/Gib misc/gibbed $alias UniversalGibs/Gib misc/gibbed
// droplets compat
misc/gibp1 gibp1
misc/gibp2 gibp3
misc/gibp3 gibp4
misc/gibp4 gibp5
misc/gibp5 gibp6
$random misc/gibp { misc/gibp1 misc/gibp2 misc/gibp3 misc/gibp4 misc/gibp5 }
$alias blood/hit misc/gibp
impact/select imppick impact/select imppick
impact/pull impaltst impact/pull impaltst

BIN
sounds/gibP1.ogg Normal file

Binary file not shown.

BIN
sounds/gibP3.ogg Normal file

Binary file not shown.

BIN
sounds/gibP4.ogg Normal file

Binary file not shown.

BIN
sounds/gibP5.ogg Normal file

Binary file not shown.

BIN
sounds/gibP6.ogg Normal file

Binary file not shown.

View file

@ -255,11 +255,12 @@ Class BioGel : Actor
atside = 0; atside = 0;
normal *= -1; normal *= -1;
} }
Vector3 orig = (BlockingLine.v1.p.x,BlockingLine.v1.p.y,0);
Vector3 onwall = pos-(normal dot (pos-orig))*normal;
SetOrigin(onwall+normal*0.5,false);
angle = atan2(normal.y,normal.x); angle = atan2(normal.y,normal.x);
pitch = 0; pitch = 0;
roll = 180; // otherwise it slides upwards (UT changes roll like this too) roll = 180; // otherwise it slides upwards (UT changes roll like this too)
LineTrace(angle+180,172,0,TRF_THRUACTORS,data:d);
SetOrigin(d.HitLocation+normal*0.5,false);
if ( waterlevel > 0 ) hittype = HIT_FLOOR; if ( waterlevel > 0 ) hittype = HIT_FLOOR;
else hittype = HIT_WALL; else hittype = HIT_WALL;
} }
@ -345,6 +346,7 @@ Class BioGel : Actor
+SKYEXPLODE; +SKYEXPLODE;
+FORCERADIUSDMG; +FORCERADIUSDMG;
+FORCEXYBILLBOARD; +FORCEXYBILLBOARD;
+MOVEWITHSECTOR;
} }
States States
{ {

View file

@ -38,6 +38,10 @@ Class UTRocketAmmo2 : UTRocketAmmo
Class UTRocket : Actor Class UTRocket : Actor
{ {
Default
{
Obituary "%o was smacked down by %k's Rocket Launcher.";
}
States States
{ {
Spawn: Spawn:
@ -48,6 +52,10 @@ Class UTRocket : Actor
Class UTGrenade : Actor Class UTGrenade : Actor
{ {
Default
{
Obituary "%o was smacked down by %k's Rocket Launcher.";
}
States States
{ {
Spawn: Spawn:
@ -58,12 +66,49 @@ Class UTGrenade : Actor
Class UTRocketLauncher : UTWeapon Class UTRocketLauncher : UTWeapon
{ {
int loaded; Actor LockedTarget;
// consumes 1 ammo
action void A_LoadRocket()
{
Weapon weap = Weapon(invoker);
if ( !weap ) return;
if ( weap.Ammo1.Amount <= 0 ) return;
if ( !weap.DepleteAmmo(weap.bAltFire,true,1) ) return;
}
// refire that is ignored if there's no ammo
action void A_LoadedRefire( statelabel flash = null )
{
Weapon weap = Weapon(invoker);
if ( !weap ) return;
if ( weap.Ammo1.Amount <= 0 ) return;
A_Refire(flash);
}
// fire all the rockets (or grenades)
action void A_FireRockets( int num )
{
Weapon weap = Weapon(invoker);
if ( !weap ) return;
if ( weap.bAltFire ) A_PlaySound("utrl/altfire",CHAN_WEAPON);
else A_PlaySound("utrl/fire",CHAN_WEAPON);
invoker.FireEffect();
UTMainHandler.DoFlash(self,Color(64,255,0,0),1);
A_AlertMonsters();
A_QuakeEx(2+num,2+num,2+num,6+num,0,1,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.1+num*0.05);
// TODO
}
// lock-on check (TODO)
Actor CheckTarget()
{
return null;
}
Default Default
{ {
Tag "Rocket Launcher"; Tag "Rocket Launcher";
//Obituary "%o was smacked down by %k's Rocket Launcher.";
Inventory.PickupMessage "You got the Rocket Launcher."; Inventory.PickupMessage "You got the Rocket Launcher.";
Weapon.UpSound "utrl/select"; Weapon.UpSound "utrl/select";
Weapon.SlotNumber 9; Weapon.SlotNumber 9;
@ -94,23 +139,253 @@ Class UTRocketLauncher : UTWeapon
} }
Wait; Wait;
Fire: Fire:
EBF1 ABCDEFGH 1; AltFire:
EBF2 ABCDEFGHIJK 1; // one is loaded already
EBF3 ABCDEFGHIJ 1; EBLI A 3 A_LoadRocket();
EBF4 ABCDEFGHIJK 1; EBLI A 0 A_LoadedRefire(1);
EBF5 ABCDEFGHIJKLM 1; Goto FireOne;
EBF6 ABCDEFGHIJKLMNOP 1; // load two
EBR1 ABCDEFG 1; EBLI A 2;
EBR2 ABCDEFG 1; EBL1 A 0;
EBR3 ABCDEFG 1; EBR1 A 2 A_PlaySound("utrl/rotate",CHAN_WEAPON,0.1);
EBR4 ABCDEFG 1; EBR1 B 0 A_Refire(1);
EBR5 ABCDEFG 1; Goto FireOne;
EBL1 ABCDEFG 1; EBR1 B 2;
EBL2 ABCDEFG 1; EBR1 C 0 A_Refire(1);
EBL3 ABCDEFG 1; Goto FireOne;
EBL4 ABCDEFG 1; EBR1 C 2;
EBL5 ABCDEFG 1; EBR1 D 0 A_Refire(1);
EBL6 ABCDEF 1; Goto FireOne;
EBR1 D 2;
EBR1 E 0 A_Refire(1);
Goto FireOne;
EBR1 E 2;
EBR1 F 0 A_Refire(1);
Goto FireOne;
EBR1 F 2;
EBR1 G 0 A_Refire(1);
Goto FireOne;
EBR1 G 2;
EBL2 A 0 A_Refire(1);
Goto FireOne;
EBL2 A 3 A_PlaySound("utrl/load",CHAN_WEAPON);
EBL2 B 0 A_Refire(1);
Goto FireOne;
EBL2 B 3;
EBL2 C 0 A_Refire(1);
Goto FireOne;
EBL2 C 3;
EBL2 D 0 A_Refire(1);
Goto FireOne;
EBL2 D 3;
EBL2 E 0 A_Refire(1);
Goto FireOne;
EBL2 E 3;
EBL2 F 0 A_Refire(1);
Goto FireOne;
EBL2 F 3;
EBL2 G 0 A_Refire(1);
Goto FireOne;
EBL2 G 3 A_LoadRocket();
EBR2 A 0 A_LoadedRefire(1);
Goto FireTwo;
// load three
EBR2 A 2 A_PlaySound("utrl/rotate",CHAN_WEAPON,0.1);
EBR2 B 0 A_Refire(1);
Goto FireTwo;
EBR2 B 2;
EBR2 C 0 A_Refire(1);
Goto FireTwo;
EBR2 C 2;
EBR2 D 0 A_Refire(1);
Goto FireTwo;
EBR2 D 2;
EBR2 E 0 A_Refire(1);
Goto FireTwo;
EBR2 E 2;
EBR2 F 0 A_Refire(1);
Goto FireTwo;
EBR2 F 2;
EBR2 G 0 A_Refire(1);
Goto FireTwo;
EBR2 G 2;
EBL3 A 0 A_Refire(1);
Goto FireTwo;
EBL3 A 3 A_PlaySound("utrl/load",CHAN_WEAPON);
EBL3 B 0 A_Refire(1);
Goto FireTwo;
EBL3 B 3;
EBL3 C 0 A_Refire(1);
Goto FireTwo;
EBL3 C 3;
EBL3 D 0 A_Refire(1);
Goto FireTwo;
EBL3 D 3;
EBL3 E 0 A_Refire(1);
Goto FireTwo;
EBL3 E 3;
EBL3 F 0 A_Refire(1);
Goto FireTwo;
EBL3 F 3;
EBL3 G 0 A_Refire(1);
Goto FireTwo;
EBL3 G 3 A_LoadRocket();
EBR3 A 0 A_LoadedRefire(1);
Goto FireThree;
// load four
EBR3 A 2 A_PlaySound("utrl/rotate",CHAN_WEAPON,0.1);
EBR3 B 0 A_Refire(1);
Goto FireThree;
EBR3 B 2;
EBR3 C 0 A_Refire(1);
Goto FireThree;
EBR3 C 2;
EBR3 D 0 A_Refire(1);
Goto FireThree;
EBR3 D 2;
EBR3 E 0 A_Refire(1);
Goto FireThree;
EBR3 E 2;
EBR3 F 0 A_Refire(1);
Goto FireThree;
EBR3 F 2;
EBR3 G 0 A_Refire(1);
Goto FireThree;
EBR3 G 2;
EBL4 A 0 A_Refire(1);
Goto FireThree;
EBL4 A 3 A_PlaySound("utrl/load",CHAN_WEAPON);
EBL4 B 0 A_Refire(1);
Goto FireThree;
EBL4 B 3;
EBL4 C 0 A_Refire(1);
Goto FireThree;
EBL4 C 3;
EBL4 D 0 A_Refire(1);
Goto FireThree;
EBL4 D 3;
EBL4 E 0 A_Refire(1);
Goto FireThree;
EBL4 E 3;
EBL4 F 0 A_Refire(1);
Goto FireThree;
EBL4 F 3;
EBL4 G 0 A_Refire(1);
Goto FireThree;
EBL4 G 3 A_LoadRocket();
EBR4 A 0 A_LoadedRefire(1);
Goto FireFour;
// load five
EBR4 A 2 A_PlaySound("utrl/rotate",CHAN_WEAPON,0.1);
EBR4 B 0 A_Refire(1);
Goto FireFour;
EBR4 B 2;
EBR4 C 0 A_Refire(1);
Goto FireFour;
EBR4 C 2;
EBR4 D 0 A_Refire(1);
Goto FireFour;
EBR4 D 2;
EBR4 E 0 A_Refire(1);
Goto FireFour;
EBR4 E 2;
EBR4 F 0 A_Refire(1);
Goto FireFour;
EBR4 F 2;
EBR4 G 0 A_Refire(1);
Goto FireFour;
EBR4 G 2;
EBL5 A 0 A_Refire(1);
Goto FireFour;
EBL5 A 3 A_PlaySound("utrl/load",CHAN_WEAPON);
EBL5 B 0 A_Refire(1);
Goto FireFour;
EBL5 B 3;
EBL5 C 0 A_Refire(1);
Goto FireFour;
EBL5 C 3;
EBL5 D 0 A_Refire(1);
Goto FireFour;
EBL5 D 3;
EBL5 E 0 A_Refire(1);
Goto FireFour;
EBL5 E 3;
EBL5 F 0 A_Refire(1);
Goto FireFour;
EBL5 F 3;
EBL5 G 0 A_Refire(1);
Goto FireFour;
EBL5 G 3 A_LoadRocket();
EBR5 A 0 A_LoadedRefire(1);
Goto FireFive;
// load six
EBR5 A 2 A_PlaySound("utrl/rotate",CHAN_WEAPON,0.1);
EBR5 B 0 A_Refire(1);
Goto FireFive;
EBR5 B 2;
EBR5 C 0 A_Refire(1);
Goto FireFive;
EBR5 C 2;
EBR5 D 0 A_Refire(1);
Goto FireFive;
EBR5 D 2;
EBR5 E 0 A_Refire(1);
Goto FireFive;
EBR5 E 2;
EBR5 F 0 A_Refire(1);
Goto FireFive;
EBR5 F 2;
EBR5 G 0 A_Refire(1);
Goto FireFive;
EBR5 G 2;
EBL6 A 0 A_Refire(1);
Goto FireFive;
EBL6 A 3 A_PlaySound("utrl/load",CHAN_WEAPON);
EBL6 B 0 A_Refire(1);
Goto FireFive;
EBL6 B 3;
EBL6 C 0 A_Refire(1);
Goto FireFive;
EBL6 C 3;
EBL6 D 0 A_Refire(1);
Goto FireFive;
EBL6 D 3;
EBL6 E 0 A_Refire(1);
Goto FireFive;
EBL6 E 3;
EBL6 F 0 A_Refire(1);
Goto FireFive;
EBL6 F 3 A_LoadRocket();
Goto FireSix;
FireOne:
EBF1 A 0 A_FireRockets(1);
EBF1 ABCDEFGH 2;
EBLI A 2;
Goto Idle;
FireTwo:
EBF2 A 0 A_FireRockets(2);
EBF2 ABCDEFGHIJK 2;
EBLI A 2;
Goto Idle;
FireThree:
EBF3 A 0 A_FireRockets(3);
EBF3 ABCDEFGHIJ 2;
EBLI A 2;
Goto Idle;
FireFour:
EBF4 A 0 A_FireRockets(4);
EBF4 ABCDEFGHIJK 2;
EBLI A 2;
Goto Idle;
FireFive:
EBF5 A 0 A_FireRockets(5);
EBF5 ABCDEFGHIJKLM 2;
EBLI A 2;
Goto Idle;
FireSix:
EBF6 A 0 A_FireRockets(6);
EBF6 ABCDEFGHIJKLMNOP 2;
EBLI A 2;
Goto Idle; Goto Idle;
Deselect: Deselect:
EBLD ABCDEFGHIJK 1; EBLD ABCDEFGHIJK 1;

View file

@ -482,7 +482,7 @@ Class FlakCannon : UTWeapon
action void A_Loading( bool first = false ) action void A_Loading( bool first = false )
{ {
if ( first ) A_PlaySound("flak/load",CHAN_WEAPON); if ( first ) A_PlaySound("flak/load",CHAN_WEAPON);
else A_PlaySound("flak/reload",CHAN_5); else A_PlaySound("flak/reload",CHAN_6);
} }
action void A_FireChunks() action void A_FireChunks()
{ {

View file

@ -105,7 +105,7 @@ Class Minigun : UTWeapon
invoker.bcnt = alt?3:5; invoker.bcnt = alt?3:5;
if ( !weap.DepleteAmmo(weap.bAltFire,true,1) ) return; if ( !weap.DepleteAmmo(weap.bAltFire,true,1) ) return;
invoker.FireEffect(); invoker.FireEffect();
UTMainHandler.DoFlash(self,Color(64,255,255,0),1); UTMainHandler.DoFlash(self,Color(32,255,255,0),1);
A_AlertMonsters(); A_AlertMonsters();
if ( alt ) A_QuakeEx(3,3,3,3,0,1,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.12); if ( alt ) A_QuakeEx(3,3,3,3,0,1,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.12);
else A_QuakeEx(2,2,2,5,0,1,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.08); else A_QuakeEx(2,2,2,5,0,1,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.08);
@ -407,7 +407,8 @@ Class Minigun : UTWeapon
MGU2 ABCDEFGHIJKLM 1; MGU2 ABCDEFGHIJKLM 1;
Goto Idle; Goto Idle;
Deselect: Deselect:
MGND ABCDEFGHIJ 2; MGND A 2 A_StopSound(CHAN_WEAPON);
MGND BCDEFGHIJ 2;
MGND J 1 A_Lower(int.max); MGND J 1 A_Lower(int.max);
Wait; Wait;
MuzzleFlash: MuzzleFlash:

View file

@ -61,7 +61,7 @@ Class DamageAmplifier : Powerup
Default Default
{ {
Powerup.Duration -30; Powerup.Duration -60;
Powerup.Color "EE00FF", 0.15; Powerup.Color "EE00FF", 0.15;
} }
@ -219,11 +219,6 @@ Class PowerUTInvisibility : PowerInvisibility
Super.EndEffect(); Super.EndEffect();
PrintPickupMessage(true,"Invisibility has worn off."); PrintPickupMessage(true,"Invisibility has worn off.");
} }
override bool isBlinking()
{
// don't cause blinking, it bugs out models
return false;
}
} }
Class UTInvisibility : PowerupGiver replaces BlurSphere Class UTInvisibility : PowerupGiver replaces BlurSphere
@ -347,6 +342,11 @@ Class UTJumpBoots : Inventory replaces RadSuit
Owner.TakeInventory("PowerJumpBoots_HighJump",1); Owner.TakeInventory("PowerJumpBoots_HighJump",1);
Owner.TakeInventory("PowerJumpBoots_IronFeet",1); Owner.TakeInventory("PowerJumpBoots_IronFeet",1);
} }
override void OwnerDied()
{
Super.OwnerDied();
DepleteOrDestroy();
}
States States
{ {
Spawn: Spawn:

View file

@ -197,7 +197,7 @@ Class PulseBoltCap : Actor
+NOGRAVITY; +NOGRAVITY;
+NOCLIP; +NOCLIP;
+DONTSPLASH; +DONTSPLASH;
Scale 0.25; Scale 0.15;
} }
States States
{ {
@ -217,7 +217,7 @@ Class PulseBoltHit : Actor
+NOGRAVITY; +NOGRAVITY;
+NOCLIP; +NOCLIP;
+DONTSPLASH; +DONTSPLASH;
Scale 0.25; Scale 0.15;
} }
States States
{ {
@ -293,8 +293,8 @@ Class PulseBolt : Actor
weffect.Destroy(); weffect.Destroy();
weffect = null; weffect = null;
} }
if ( !weffect ) weffect = Spawn("PulseBoltHit",t.Results.HitPos); if ( !weffect ) weffect = Spawn("PulseBoltHit",t.Results.HitPos-t.Results.HitVector);
else weffect.SetOrigin(t.Results.HitPos,true); else weffect.SetOrigin(t.Results.HitPos-t.Results.HitVector,true);
A_SprayDecal("BoltScorch",beamsize+8); A_SprayDecal("BoltScorch",beamsize+8);
if ( next ) if ( next )
{ {
@ -325,8 +325,8 @@ Class PulseBolt : Actor
weffect.Destroy(); weffect.Destroy();
weffect = null; weffect = null;
} }
if ( !weffect ) weffect = Spawn("PulseBoltCap",t.Results.HitPos); if ( !weffect ) weffect = Spawn("PulseBoltCap",t.Results.HitPos-t.Results.HitVector);
else weffect.SetOrigin(t.Results.HitPos,true); else weffect.SetOrigin(t.Results.HitPos-t.Results.HitVector,true);
} }
else else
{ {
@ -350,8 +350,8 @@ Class PulseBolt : Actor
{ {
frame = parent.frame; frame = parent.frame;
SetOrigin(parent.Vec3Offset(x.x*beamsize,x.y*beamsize,x.z*beamsize),true); SetOrigin(parent.Vec3Offset(x.x*beamsize,x.y*beamsize,x.z*beamsize),true);
A_SetAngle(parent.angle,SPF_INTERPOLATE); A_SetAngle(parent.angle);
A_SetPitch(parent.pitch,SPF_INTERPOLATE); A_SetPitch(parent.pitch);
CheckBeam(x); CheckBeam(x);
} }
Default Default
@ -363,6 +363,7 @@ Class PulseBolt : Actor
+NOGRAVITY; +NOGRAVITY;
+NOCLIP; +NOCLIP;
+DONTSPLASH; +DONTSPLASH;
+INTERPOLATEANGLES;
} }
States States
{ {
@ -390,12 +391,12 @@ Class StarterBolt : PulseBolt
if ( target.player ) if ( target.player )
{ {
[x, y, z] = Matrix4.GetAxes(target.pitch,target.angle,target.roll); [x, y, z] = Matrix4.GetAxes(target.pitch,target.angle,target.roll);
origin = (0,0,target.player.viewz-target.pos.z)+5.0*x+3.0*y-1.5*z; origin = (0,0,target.player.viewz-target.pos.z)+5.0*x+3.0*y-1.0*z;
} }
else origin = (0,0,target.missileheight); else origin = (0,0,target.missileheight);
SetOrigin(target.Vec3Offset(origin.x,origin.y,origin.z),true); SetOrigin(target.Vec3Offset(origin.x,origin.y,origin.z),true);
A_SetAngle(target.angle,SPF_INTERPOLATE); A_SetAngle(target.angle);
A_SetPitch(target.BulletSlope(),SPF_INTERPOLATE); A_SetPitch(target.BulletSlope());
frame++; frame++;
if ( frame > 4 ) frame = 0; if ( frame > 4 ) frame = 0;
CheckBeam(x); CheckBeam(x);
@ -436,7 +437,7 @@ Class PulseGun : UTWeapon
A_AlertMonsters(); A_AlertMonsters();
Vector3 x, y, z; Vector3 x, y, z;
[x, y, z] = Matrix4.GetAxes(pitch,angle,roll); [x, y, z] = Matrix4.GetAxes(pitch,angle,roll);
Vector3 origin = pos+(0,0,player.viewheight)+10.0*x+4.5*y-2.4*z; Vector3 origin = pos+(0,0,player.viewheight)+10.0*x+4.5*y-1.9*z;
int numpt = Random[Pulse](2,5); int numpt = Random[Pulse](2,5);
for ( int i=0; i<numpt; i++ ) for ( int i=0; i<numpt; i++ )
{ {
@ -476,7 +477,7 @@ Class PulseGun : UTWeapon
Vector3 x, y, z; Vector3 x, y, z;
double a; double a;
[x, y, z] = Matrix4.GetAxes(pitch,angle,roll); [x, y, z] = Matrix4.GetAxes(pitch,angle,roll);
Vector3 origin = pos+(0,0,player.viewheight)+10.0*x+4.0*y-2.0*z; Vector3 origin = pos+(0,0,player.viewheight)+10.0*x+4.0*y-1.5*z;
origin += y*cos(invoker.sangle)*2.0+z*sin(invoker.sangle)*2.0; origin += y*cos(invoker.sangle)*2.0+z*sin(invoker.sangle)*2.0;
invoker.sangle += 100; invoker.sangle += 100;
Actor p = Spawn("PulseBall",origin); Actor p = Spawn("PulseBall",origin);
@ -503,6 +504,11 @@ Class PulseGun : UTWeapon
A_StopSound(CHAN_WEAPON); A_StopSound(CHAN_WEAPON);
if ( invoker.beam ) invoker.beam.Destroy(); if ( invoker.beam ) invoker.beam.Destroy();
} }
override void OwnerDied()
{
Super.OwnerDied();
if ( beam ) beam.Destroy();
}
Default Default
{ {
Tag "Pulse Gun"; Tag "Pulse Gun";

View file

@ -120,12 +120,13 @@ Class TranslocatorModule : Actor
{ {
Radius 2; Radius 2;
Height 2; Height 2;
Speed 20; Speed 25;
PROJECTILE; PROJECTILE;
-NOGRAVITY; -NOGRAVITY;
+USEBOUNCESTATE; +USEBOUNCESTATE;
+SKYEXPLODE; +SKYEXPLODE;
+HITTRACER; +HITTRACER;
+MOVEWITHSECTOR;
BounceType "Doom"; BounceType "Doom";
BounceFactor 0.5; BounceFactor 0.5;
WallBounceFactor 0.5; WallBounceFactor 0.5;
@ -287,8 +288,9 @@ Class Translocator : UTWeapon
p.target = self; p.target = self;
p.angle = angle; p.angle = angle;
p.pitch = BulletSlope(); p.pitch = BulletSlope();
p.vel = (cos(p.angle)*cos(p.pitch),sin(p.angle)*cos(p.pitch),-sin(p.pitch))*p.speed; Vector3 dir = (cos(p.angle)*cos(p.pitch),sin(p.angle)*cos(p.pitch),-sin(p.pitch));
p.vel.z += 5; dir.z += 0.35*(1-abs(dir.z));
p.vel = dir*p.speed;
invoker.module = p; invoker.module = p;
} }