Implemented GES Biorifle.
This commit is contained in:
parent
3e169dfde6
commit
3b4642be7c
7 changed files with 1010 additions and 7 deletions
10
Readme.md
10
Readme.md
|
|
@ -20,8 +20,11 @@ Doom Tournament (currently the devel branch is required).
|
||||||
- "Hold up to 2 seconds" feature from Unreal Bible
|
- "Hold up to 2 seconds" feature from Unreal Bible
|
||||||
- Flak Cannon (slot 6) (replaces rocket launcher)
|
- Flak Cannon (slot 6) (replaces rocket launcher)
|
||||||
- Razorjack (slot 7) (replaces chaingun)
|
- Razorjack (slot 7) (replaces chaingun)
|
||||||
- Razorjack hold fire to increase blade speed (from Unreal Bible)
|
- Hold fire to increase blade speed (from Unreal Bible)
|
||||||
- Make Razorjack altfire actually seek where player is aiming (toggleable)
|
- Make Razorjack altfire actually seek where player is aiming (toggleable)
|
||||||
|
- GES Bio Rifle (slot 8) (replaces plasma rifle)
|
||||||
|
- "Hold up to 2 seconds" feature from Unreal Bible
|
||||||
|
- Biorifle splashes like UT (toggleable)
|
||||||
- SMP 7243 (slot 0) (replaces bfg9000)
|
- SMP 7243 (slot 0) (replaces bfg9000)
|
||||||
- Backpack (replaces backpack, identical to Doom Tournament version)
|
- Backpack (replaces backpack, identical to Doom Tournament version)
|
||||||
- Unreal 1 HUD
|
- Unreal 1 HUD
|
||||||
|
|
@ -55,7 +58,6 @@ Doom Tournament (currently the devel branch is required).
|
||||||
|
|
||||||
## In progress
|
## In progress
|
||||||
|
|
||||||
- GES Bio Rifle (slot 8) (replaces plasma rifle)
|
|
||||||
- Rifle (slot 9) (replaces plasma rifle)
|
- Rifle (slot 9) (replaces plasma rifle)
|
||||||
- Minigun (slot 0) (replaces chaingun)
|
- Minigun (slot 0) (replaces chaingun)
|
||||||
|
|
||||||
|
|
@ -64,10 +66,6 @@ Doom Tournament (currently the devel branch is required).
|
||||||
- Unreal Bible & prototype build behaviour restoration
|
- Unreal Bible & prototype build behaviour restoration
|
||||||
- Rifle restored rapid fire
|
- Rifle restored rapid fire
|
||||||
- Rifle restored flashlight
|
- Rifle restored flashlight
|
||||||
- Biorifle "Hold up to 2 seconds" feature from Unreal Bible
|
|
||||||
|
|
||||||
- QOL improvements
|
|
||||||
- Biorifle splashes like UT (toggleable)
|
|
||||||
|
|
||||||
- Stunner (slot 4) (replaces chainsaw)
|
- Stunner (slot 4) (replaces chainsaw)
|
||||||
- Razorclaw (slot 1) (replaces chainsaw)
|
- Razorclaw (slot 1) (replaces chainsaw)
|
||||||
|
|
|
||||||
|
|
@ -58,6 +58,221 @@ Model "UBioAmmo2"
|
||||||
FrameIndex BIOA K 0 10
|
FrameIndex BIOA K 0 10
|
||||||
FrameIndex BIOA L 0 11
|
FrameIndex BIOA L 0 11
|
||||||
}
|
}
|
||||||
|
Model "UBioGel"
|
||||||
|
{
|
||||||
|
Path "models"
|
||||||
|
Model 0 "BioRGel_d.3d"
|
||||||
|
Skin 0 "Jflare.png"
|
||||||
|
Scale 0.12 0.1 0.1
|
||||||
|
PitchOffset -90
|
||||||
|
USEACTORPITCH
|
||||||
|
USEACTORROLL
|
||||||
|
|
||||||
|
// Flying
|
||||||
|
FrameIndex GELF A 0 0
|
||||||
|
FrameIndex GELF B 0 1
|
||||||
|
FrameIndex GELF C 0 2
|
||||||
|
FrameIndex GELF D 0 3
|
||||||
|
FrameIndex GELF E 0 4
|
||||||
|
FrameIndex GELF F 0 5
|
||||||
|
FrameIndex GELF G 0 6
|
||||||
|
FrameIndex GELF H 0 7
|
||||||
|
FrameIndex GELF I 0 8
|
||||||
|
FrameIndex GELF J 0 9
|
||||||
|
FrameIndex GELF K 0 10
|
||||||
|
FrameIndex GELF L 0 11
|
||||||
|
FrameIndex GELF M 0 12
|
||||||
|
// Hit
|
||||||
|
FrameIndex GELH A 0 14
|
||||||
|
FrameIndex GELH B 0 15
|
||||||
|
FrameIndex GELH C 0 16
|
||||||
|
FrameIndex GELH D 0 17
|
||||||
|
FrameIndex GELH E 0 18
|
||||||
|
FrameIndex GELH F 0 19
|
||||||
|
FrameIndex GELH G 0 20
|
||||||
|
FrameIndex GELH H 0 21
|
||||||
|
FrameIndex GELH I 0 22
|
||||||
|
FrameIndex GELH J 0 23
|
||||||
|
// Drip
|
||||||
|
FrameIndex GELD A 0 24
|
||||||
|
FrameIndex GELD B 0 25
|
||||||
|
FrameIndex GELD C 0 26
|
||||||
|
FrameIndex GELD D 0 27
|
||||||
|
FrameIndex GELD E 0 28
|
||||||
|
FrameIndex GELD F 0 29
|
||||||
|
FrameIndex GELD G 0 30
|
||||||
|
FrameIndex GELD H 0 31
|
||||||
|
FrameIndex GELD I 0 32
|
||||||
|
FrameIndex GELD J 0 33
|
||||||
|
FrameIndex GELD K 0 34
|
||||||
|
FrameIndex GELD L 0 35
|
||||||
|
FrameIndex GELD M 0 36
|
||||||
|
// Slide
|
||||||
|
FrameIndex GELS A 0 37
|
||||||
|
FrameIndex GELS B 0 38
|
||||||
|
FrameIndex GELS C 0 39
|
||||||
|
FrameIndex GELS D 0 40
|
||||||
|
FrameIndex GELS E 0 41
|
||||||
|
FrameIndex GELS F 0 42
|
||||||
|
FrameIndex GELS G 0 43
|
||||||
|
// Shrivel
|
||||||
|
FrameIndex GELX A 0 44
|
||||||
|
FrameIndex GELX B 0 45
|
||||||
|
FrameIndex GELX C 0 46
|
||||||
|
FrameIndex GELX D 0 47
|
||||||
|
FrameIndex GELX E 0 48
|
||||||
|
FrameIndex GELX F 0 49
|
||||||
|
FrameIndex GELX G 0 50
|
||||||
|
FrameIndex GELX H 0 51
|
||||||
|
FrameIndex GELX I 0 52
|
||||||
|
FrameIndex GELX J 0 53
|
||||||
|
FrameIndex GELX K 0 54
|
||||||
|
FrameIndex GELX L 0 55
|
||||||
|
}
|
||||||
|
|
||||||
|
Model "UBioSplash"
|
||||||
|
{
|
||||||
|
Path "models"
|
||||||
|
Model 0 "BioRGel_d.3d"
|
||||||
|
Skin 0 "Jflare.png"
|
||||||
|
Scale 0.12 0.1 0.1
|
||||||
|
PitchOffset -90
|
||||||
|
USEACTORPITCH
|
||||||
|
USEACTORROLL
|
||||||
|
|
||||||
|
// Flying
|
||||||
|
FrameIndex GELF A 0 0
|
||||||
|
FrameIndex GELF B 0 1
|
||||||
|
FrameIndex GELF C 0 2
|
||||||
|
FrameIndex GELF D 0 3
|
||||||
|
FrameIndex GELF E 0 4
|
||||||
|
FrameIndex GELF F 0 5
|
||||||
|
FrameIndex GELF G 0 6
|
||||||
|
FrameIndex GELF H 0 7
|
||||||
|
FrameIndex GELF I 0 8
|
||||||
|
FrameIndex GELF J 0 9
|
||||||
|
FrameIndex GELF K 0 10
|
||||||
|
FrameIndex GELF L 0 11
|
||||||
|
FrameIndex GELF M 0 12
|
||||||
|
// Hit
|
||||||
|
FrameIndex GELH A 0 14
|
||||||
|
FrameIndex GELH B 0 15
|
||||||
|
FrameIndex GELH C 0 16
|
||||||
|
FrameIndex GELH D 0 17
|
||||||
|
FrameIndex GELH E 0 18
|
||||||
|
FrameIndex GELH F 0 19
|
||||||
|
FrameIndex GELH G 0 20
|
||||||
|
FrameIndex GELH H 0 21
|
||||||
|
FrameIndex GELH I 0 22
|
||||||
|
FrameIndex GELH J 0 23
|
||||||
|
// Drip
|
||||||
|
FrameIndex GELD A 0 24
|
||||||
|
FrameIndex GELD B 0 25
|
||||||
|
FrameIndex GELD C 0 26
|
||||||
|
FrameIndex GELD D 0 27
|
||||||
|
FrameIndex GELD E 0 28
|
||||||
|
FrameIndex GELD F 0 29
|
||||||
|
FrameIndex GELD G 0 30
|
||||||
|
FrameIndex GELD H 0 31
|
||||||
|
FrameIndex GELD I 0 32
|
||||||
|
FrameIndex GELD J 0 33
|
||||||
|
FrameIndex GELD K 0 34
|
||||||
|
FrameIndex GELD L 0 35
|
||||||
|
FrameIndex GELD M 0 36
|
||||||
|
// Slide
|
||||||
|
FrameIndex GELS A 0 37
|
||||||
|
FrameIndex GELS B 0 38
|
||||||
|
FrameIndex GELS C 0 39
|
||||||
|
FrameIndex GELS D 0 40
|
||||||
|
FrameIndex GELS E 0 41
|
||||||
|
FrameIndex GELS F 0 42
|
||||||
|
FrameIndex GELS G 0 43
|
||||||
|
// Shrivel
|
||||||
|
FrameIndex GELX A 0 44
|
||||||
|
FrameIndex GELX B 0 45
|
||||||
|
FrameIndex GELX C 0 46
|
||||||
|
FrameIndex GELX D 0 47
|
||||||
|
FrameIndex GELX E 0 48
|
||||||
|
FrameIndex GELX F 0 49
|
||||||
|
FrameIndex GELX G 0 50
|
||||||
|
FrameIndex GELX H 0 51
|
||||||
|
FrameIndex GELX I 0 52
|
||||||
|
FrameIndex GELX J 0 53
|
||||||
|
FrameIndex GELX K 0 54
|
||||||
|
FrameIndex GELX L 0 55
|
||||||
|
}
|
||||||
|
|
||||||
|
Model "UBioGlob"
|
||||||
|
{
|
||||||
|
Path "models"
|
||||||
|
Model 0 "BioRGel_d.3d"
|
||||||
|
Skin 0 "Jflare.png"
|
||||||
|
Scale 0.12 0.1 0.1
|
||||||
|
PitchOffset -90
|
||||||
|
USEACTORPITCH
|
||||||
|
USEACTORROLL
|
||||||
|
|
||||||
|
// Flying
|
||||||
|
FrameIndex GELF A 0 0
|
||||||
|
FrameIndex GELF B 0 1
|
||||||
|
FrameIndex GELF C 0 2
|
||||||
|
FrameIndex GELF D 0 3
|
||||||
|
FrameIndex GELF E 0 4
|
||||||
|
FrameIndex GELF F 0 5
|
||||||
|
FrameIndex GELF G 0 6
|
||||||
|
FrameIndex GELF H 0 7
|
||||||
|
FrameIndex GELF I 0 8
|
||||||
|
FrameIndex GELF J 0 9
|
||||||
|
FrameIndex GELF K 0 10
|
||||||
|
FrameIndex GELF L 0 11
|
||||||
|
FrameIndex GELF M 0 12
|
||||||
|
// Hit
|
||||||
|
FrameIndex GELH A 0 14
|
||||||
|
FrameIndex GELH B 0 15
|
||||||
|
FrameIndex GELH C 0 16
|
||||||
|
FrameIndex GELH D 0 17
|
||||||
|
FrameIndex GELH E 0 18
|
||||||
|
FrameIndex GELH F 0 19
|
||||||
|
FrameIndex GELH G 0 20
|
||||||
|
FrameIndex GELH H 0 21
|
||||||
|
FrameIndex GELH I 0 22
|
||||||
|
FrameIndex GELH J 0 23
|
||||||
|
// Drip
|
||||||
|
FrameIndex GELD A 0 24
|
||||||
|
FrameIndex GELD B 0 25
|
||||||
|
FrameIndex GELD C 0 26
|
||||||
|
FrameIndex GELD D 0 27
|
||||||
|
FrameIndex GELD E 0 28
|
||||||
|
FrameIndex GELD F 0 29
|
||||||
|
FrameIndex GELD G 0 30
|
||||||
|
FrameIndex GELD H 0 31
|
||||||
|
FrameIndex GELD I 0 32
|
||||||
|
FrameIndex GELD J 0 33
|
||||||
|
FrameIndex GELD K 0 34
|
||||||
|
FrameIndex GELD L 0 35
|
||||||
|
FrameIndex GELD M 0 36
|
||||||
|
// Slide
|
||||||
|
FrameIndex GELS A 0 37
|
||||||
|
FrameIndex GELS B 0 38
|
||||||
|
FrameIndex GELS C 0 39
|
||||||
|
FrameIndex GELS D 0 40
|
||||||
|
FrameIndex GELS E 0 41
|
||||||
|
FrameIndex GELS F 0 42
|
||||||
|
FrameIndex GELS G 0 43
|
||||||
|
// Shrivel
|
||||||
|
FrameIndex GELX A 0 44
|
||||||
|
FrameIndex GELX B 0 45
|
||||||
|
FrameIndex GELX C 0 46
|
||||||
|
FrameIndex GELX D 0 47
|
||||||
|
FrameIndex GELX E 0 48
|
||||||
|
FrameIndex GELX F 0 49
|
||||||
|
FrameIndex GELX G 0 50
|
||||||
|
FrameIndex GELX H 0 51
|
||||||
|
FrameIndex GELX I 0 52
|
||||||
|
FrameIndex GELX J 0 53
|
||||||
|
FrameIndex GELX K 0 54
|
||||||
|
FrameIndex GELX L 0 55
|
||||||
|
}
|
||||||
|
|
||||||
Model "UBioRifle"
|
Model "UBioRifle"
|
||||||
{
|
{
|
||||||
|
|
@ -74,3 +289,116 @@ Model "UBioRifle"
|
||||||
ROTATING
|
ROTATING
|
||||||
FrameIndex BIOP A 1 0
|
FrameIndex BIOP A 1 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Model "UBioRifle"
|
||||||
|
{
|
||||||
|
Path "models"
|
||||||
|
Model 0 "BRifle_d.3d"
|
||||||
|
Skin 0 "JBrifle1.png"
|
||||||
|
Scale 0.2 -0.2 0.2
|
||||||
|
AngleOffset -90
|
||||||
|
Offset 7 -20 -11.5
|
||||||
|
|
||||||
|
// Select
|
||||||
|
FrameIndex BIOS A 0 0
|
||||||
|
FrameIndex BIOS B 0 1
|
||||||
|
FrameIndex BIOS C 0 2
|
||||||
|
FrameIndex BIOS D 0 3
|
||||||
|
FrameIndex BIOS E 0 4
|
||||||
|
FrameIndex BIOS F 0 5
|
||||||
|
FrameIndex BIOS G 0 6
|
||||||
|
FrameIndex BIOS H 0 7
|
||||||
|
FrameIndex BIOS I 0 8
|
||||||
|
FrameIndex BIOS J 0 9
|
||||||
|
FrameIndex BIOS K 0 10
|
||||||
|
FrameIndex BIOS L 0 11
|
||||||
|
FrameIndex BIOS M 0 12
|
||||||
|
FrameIndex BIOS N 0 13
|
||||||
|
FrameIndex BIOS O 0 14
|
||||||
|
FrameIndex BIOS P 0 15
|
||||||
|
FrameIndex BIOS Q 0 16
|
||||||
|
FrameIndex BIOS R 0 17
|
||||||
|
FrameIndex BIOS S 0 18
|
||||||
|
FrameIndex BIOS T 0 19
|
||||||
|
// Idle
|
||||||
|
FrameIndex BIOI A 0 20
|
||||||
|
// Walk
|
||||||
|
FrameIndex BIOW A 0 21
|
||||||
|
FrameIndex BIOW B 0 22
|
||||||
|
FrameIndex BIOW C 0 23
|
||||||
|
FrameIndex BIOW D 0 24
|
||||||
|
FrameIndex BIOW E 0 25
|
||||||
|
FrameIndex BIOW F 0 26
|
||||||
|
FrameIndex BIOW G 0 27
|
||||||
|
FrameIndex BIOW H 0 28
|
||||||
|
FrameIndex BIOW I 0 29
|
||||||
|
FrameIndex BIOW J 0 30
|
||||||
|
FrameIndex BIOW K 0 31
|
||||||
|
FrameIndex BIOW L 0 32
|
||||||
|
FrameIndex BIOW M 0 33
|
||||||
|
FrameIndex BIOW N 0 34
|
||||||
|
FrameIndex BIOW O 0 35
|
||||||
|
FrameIndex BIOW P 0 36
|
||||||
|
FrameIndex BIOW Q 0 37
|
||||||
|
FrameIndex BIOW R 0 38
|
||||||
|
FrameIndex BIOW S 0 39
|
||||||
|
FrameIndex BIOW T 0 40
|
||||||
|
// Altfire
|
||||||
|
FrameIndex BIOA A 0 41
|
||||||
|
FrameIndex BIOA B 0 42
|
||||||
|
FrameIndex BIOA C 0 43
|
||||||
|
FrameIndex BIOA D 0 44
|
||||||
|
FrameIndex BIOA E 0 45
|
||||||
|
FrameIndex BIOA F 0 46
|
||||||
|
FrameIndex BIOA G 0 47
|
||||||
|
FrameIndex BIOA H 0 48
|
||||||
|
FrameIndex BIOA I 0 49
|
||||||
|
FrameIndex BIOA J 0 50
|
||||||
|
FrameIndex BIOA K 0 51
|
||||||
|
FrameIndex BIOA L 0 52
|
||||||
|
FrameIndex BIOA M 0 53
|
||||||
|
FrameIndex BIOA N 0 54
|
||||||
|
FrameIndex BIOA O 0 55
|
||||||
|
FrameIndex BIOA P 0 56
|
||||||
|
FrameIndex BIOA Q 0 57
|
||||||
|
FrameIndex BIOA R 0 58
|
||||||
|
FrameIndex BIOA S 0 59
|
||||||
|
FrameIndex BIOA T 0 60
|
||||||
|
FrameIndex BIOA U 0 61
|
||||||
|
FrameIndex BIOA V 0 62
|
||||||
|
FrameIndex BIOA W 0 63
|
||||||
|
FrameIndex BIOA X 0 64
|
||||||
|
FrameIndex BIOA Y 0 65
|
||||||
|
FrameIndex BIOA Z 0 66
|
||||||
|
FrameIndex BIA2 A 0 67
|
||||||
|
FrameIndex BIA2 B 0 68
|
||||||
|
FrameIndex BIA2 C 0 69
|
||||||
|
FrameIndex BIA2 D 0 70
|
||||||
|
// Fire
|
||||||
|
FrameIndex BIOF A 0 71
|
||||||
|
FrameIndex BIOF B 0 72
|
||||||
|
FrameIndex BIOF C 0 73
|
||||||
|
FrameIndex BIOF D 0 74
|
||||||
|
FrameIndex BIOF E 0 75
|
||||||
|
FrameIndex BIOF F 0 76
|
||||||
|
FrameIndex BIOF G 0 77
|
||||||
|
FrameIndex BIOF H 0 78
|
||||||
|
FrameIndex BIOF I 0 79
|
||||||
|
FrameIndex BIOF J 0 80
|
||||||
|
// Drip
|
||||||
|
FrameIndex BIOT A 0 81
|
||||||
|
FrameIndex BIOT B 0 82
|
||||||
|
FrameIndex BIOT C 0 83
|
||||||
|
FrameIndex BIOT D 0 84
|
||||||
|
FrameIndex BIOT E 0 85
|
||||||
|
FrameIndex BIOT F 0 86
|
||||||
|
FrameIndex BIOT G 0 87
|
||||||
|
// Down
|
||||||
|
FrameIndex BIOD A 0 88
|
||||||
|
FrameIndex BIOD B 0 90
|
||||||
|
FrameIndex BIOD C 0 92
|
||||||
|
FrameIndex BIOD D 0 94
|
||||||
|
FrameIndex BIOD E 0 96
|
||||||
|
FrameIndex BIOD F 0 98
|
||||||
|
FrameIndex BIOD G 0 100
|
||||||
|
}
|
||||||
|
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 73 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 73 KiB |
|
|
@ -178,6 +178,9 @@ eightball/fly brocket
|
||||||
|
|
||||||
asmd/vapour vapour
|
asmd/vapour vapour
|
||||||
|
|
||||||
|
ges/drip GelDrip
|
||||||
|
ges/load GelLoad
|
||||||
|
|
||||||
dampener/on dampsnd
|
dampener/on dampsnd
|
||||||
dampener/off dampndea
|
dampener/off dampndea
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -42,18 +42,622 @@ Class UBioAmmo2 : UBioAmmo
|
||||||
|
|
||||||
Class UBioGel : Actor
|
Class UBioGel : Actor
|
||||||
{
|
{
|
||||||
|
Actor l, b;
|
||||||
|
enum EHitType
|
||||||
|
{
|
||||||
|
HIT_NONE,
|
||||||
|
HIT_WALL,
|
||||||
|
HIT_CEILING,
|
||||||
|
HIT_FLOOR
|
||||||
|
};
|
||||||
|
int hittype;
|
||||||
|
int deadtimer, dttimer;
|
||||||
|
Line atline;
|
||||||
|
int atside;
|
||||||
|
int atpart;
|
||||||
|
int atplane;
|
||||||
|
Sector atsector;
|
||||||
|
double atz;
|
||||||
|
double rollvel, pitchvel, yawvel;
|
||||||
|
Vector3 normal;
|
||||||
|
Actor atbridge;
|
||||||
|
bool onbridge;
|
||||||
|
Vector3 atbridgeofs;
|
||||||
|
|
||||||
|
override void PostBeginPlay()
|
||||||
|
{
|
||||||
|
Super.PostBeginPlay();
|
||||||
|
vel.z += 3;
|
||||||
|
deadtimer = 105;
|
||||||
|
A_AttachLight('BioLight',DynamicLight.PointLight,"40FF80",int(8*scale.x),int(8*scale.x));
|
||||||
|
rollvel = FRandom[GES](10,30)*RandomPick[GES](-1,1);
|
||||||
|
pitchvel = FRandom[GES](10,30)*RandomPick[GES](-1,1);
|
||||||
|
yawvel = FRandom[GES](10,30)*RandomPick[GES](-1,1);
|
||||||
|
}
|
||||||
|
override int SpecialMissileHit( Actor victim )
|
||||||
|
{
|
||||||
|
if ( victim == b ) return 1;
|
||||||
|
if ( (victim is 'BioHitbox') && ((victim.target == master) || (victim.target.master == master)) ) return 1;
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
override void Tick()
|
||||||
|
{
|
||||||
|
Super.Tick();
|
||||||
|
if ( isFrozen() ) return;
|
||||||
|
if ( !bNOGRAVITY )
|
||||||
|
{
|
||||||
|
roll += rollvel;
|
||||||
|
pitch += pitchvel;
|
||||||
|
pitch += yawvel;
|
||||||
|
if ( waterlevel > 0 )
|
||||||
|
{
|
||||||
|
vel.xy *= 0.98;
|
||||||
|
rollvel *= 0.98;
|
||||||
|
pitchvel *= 0.98;
|
||||||
|
yawvel *= 0.98;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( deadtimer > -2 )
|
||||||
|
{
|
||||||
|
if ( onbridge ) // attempt to follow the movement of the bridge (if it's moving)
|
||||||
|
{
|
||||||
|
if ( atbridge )
|
||||||
|
{
|
||||||
|
if ( !Warp(atbridge,atbridgeofs.x,atbridgeofs.y,atbridgeofs.z,0,WARPF_ABSOLUTEOFFSET|WARPF_USECALLERANGLE|WARPF_COPYINTERPOLATION) )
|
||||||
|
deadtimer = min(deadtimer,0);
|
||||||
|
}
|
||||||
|
else deadtimer = min(deadtimer,0);
|
||||||
|
}
|
||||||
|
if ( atline ) // attempt to follow the movement of the line
|
||||||
|
{
|
||||||
|
if ( atpart == 1 )
|
||||||
|
{
|
||||||
|
if ( atline.flags&Line.ML_DONTPEGTOP ) SetOrigin(Vec2OffsetZ(0,0,atz+atline.sidedef[atside].sector.GetPlaneTexZ(1)),true);
|
||||||
|
else SetOrigin(Vec2OffsetZ(0,0,atz+atline.sidedef[atside?0:1].sector.GetPlaneTexZ(1)),true);
|
||||||
|
}
|
||||||
|
else if ( atpart == -1 )
|
||||||
|
{
|
||||||
|
if ( atline.flags&Line.ML_DONTPEGBOTTOM ) SetOrigin(Vec2OffsetZ(0,0,atz+atline.sidedef[atside].sector.GetPlaneTexZ(0)),true);
|
||||||
|
else SetOrigin(Vec2OffsetZ(0,0,atz+atline.sidedef[atside?0:1].sector.GetPlaneTexZ(0)),true);
|
||||||
|
}
|
||||||
|
else if ( atline.flags&Line.ML_DONTPEGBOTTOM ) SetOrigin(Vec2OffsetZ(0,0,atz+atline.sidedef[atside].sector.GetPlaneTexZ(0)),true);
|
||||||
|
else SetOrigin(Vec2OffsetZ(0,0,atz+atline.sidedef[atside].sector.GetPlaneTexZ(1)),true);
|
||||||
|
if ( (pos.z > ceilingz) || (pos.z < floorz) ) deadtimer = min(deadtimer,0);
|
||||||
|
}
|
||||||
|
else if ( atsector ) // attempt to follow the movement of the plane
|
||||||
|
{
|
||||||
|
SetOrigin(Vec2OffsetZ(0,0,atz+atsector.GetPlaneTexZ(atplane)),true);
|
||||||
|
if ( ceilingz-floorz <= 2 ) deadtimer = min(deadtimer,0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( !InStateSequence(CurState,FindState("XDeath")) )
|
||||||
|
{
|
||||||
|
int numpt;
|
||||||
|
if ( (!bNOGRAVITY && !Random[GES](0,2)) || !Random[GES](0,10) )
|
||||||
|
{
|
||||||
|
numpt = Min(20,int(Scale.x*2))+Random[GES](-1,1);
|
||||||
|
for ( int i=0; i<numpt; i++ )
|
||||||
|
{
|
||||||
|
Vector3 pvel = (FRandom[GES](-1,1),FRandom[GES](-1,1),FRandom[GES](-1,1)).unit()*FRandom[GES](1,3);
|
||||||
|
Vector3 spos = pos+normal*2*scale.x;
|
||||||
|
let s = Spawn("BioSpark",spos);
|
||||||
|
s.vel = pvel;
|
||||||
|
if ( normal != (0,0,0) ) s.vel += normal*2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
numpt = Min(3,int(Scale.x*4))+Random[GES](-2,2);
|
||||||
|
for ( int i=0; i<numpt; i++ )
|
||||||
|
{
|
||||||
|
Vector3 pvel = (FRandom[GES](-1,1),FRandom[GES](-1,1),FRandom[GES](-1,1)).unit()*FRandom[GES](0.2,0.4);
|
||||||
|
let s = Spawn("UTSmoke",pos+normal);
|
||||||
|
s.vel = pvel+vel*0.25+normal*0.5;
|
||||||
|
s.scale *= scale.x;
|
||||||
|
s.A_SetRenderStyle(0.75,STYLE_AddShaded);
|
||||||
|
if ( Random[GES](0,1) ) s.SetShade("061004");
|
||||||
|
else s.SetShade("061006");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( deadtimer <= -1 ) return;
|
||||||
|
let bi = BlockThingsIterator.Create(self,4*Scale.x);
|
||||||
|
while ( bi.Next() )
|
||||||
|
{
|
||||||
|
if ( !bi.Thing || !bi.Thing.bSHOOTABLE || (bi.Thing == b) || ((bi.Thing is 'BioHitbox') && ((bi.Thing.target.master == self) || (bi.Thing.target == master))) || (bi.Thing == target && !bHITOWNER) ) continue;
|
||||||
|
if ( (Distance2D(bi.Thing)-bi.Thing.radius <= 4*Scale.x) && ((bi.Thing.pos.z <= pos.z+4*Scale.x) && (bi.Thing.pos.z+bi.Thing.height >= pos.z-4*Scale.x)) ) deadtimer = 0;
|
||||||
|
}
|
||||||
|
if ( deadtimer-- <= 0 )
|
||||||
|
{
|
||||||
|
deadtimer = -1;
|
||||||
|
SetStateLabel("XDeath");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// align self to what surface was hit
|
||||||
|
// TODO handle plane collision within the very border between two
|
||||||
|
// sectors (most noticeable with moving 3d floors)
|
||||||
|
virtual void AlignSelf()
|
||||||
|
{
|
||||||
|
F3DFloor ff;
|
||||||
|
bINTERPOLATEANGLES = false;
|
||||||
|
bHITOWNER = true;
|
||||||
|
A_NoGravity();
|
||||||
|
A_Stop();
|
||||||
|
if ( bAMBUSH )
|
||||||
|
{
|
||||||
|
SetStateLabel("XDeath");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
A_SetSize(0.1,0);
|
||||||
|
if ( tracer && tracer.bACTLIKEBRIDGE )
|
||||||
|
{
|
||||||
|
atbridge = tracer;
|
||||||
|
onbridge = true;
|
||||||
|
if ( (pos.x+radius) <= (atbridge.pos.x-atbridge.radius) )
|
||||||
|
{
|
||||||
|
// west side
|
||||||
|
normal = (-1,0,0);
|
||||||
|
SetOrigin((atbridge.pos.x-atbridge.radius,pos.y,pos.z),false);
|
||||||
|
atbridgeofs = pos-atbridge.pos;
|
||||||
|
angle = 180;
|
||||||
|
pitch = 0;
|
||||||
|
roll = 180; // otherwise it slides upwards (UT changes roll like this too)
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_WALL;
|
||||||
|
}
|
||||||
|
else if ( (pos.x-radius) >= (atbridge.pos.x+atbridge.radius) )
|
||||||
|
{
|
||||||
|
// east side
|
||||||
|
normal = (1,0,0);
|
||||||
|
SetOrigin((atbridge.pos.x+atbridge.radius,pos.y,pos.z),false);
|
||||||
|
atbridgeofs = pos-atbridge.pos;
|
||||||
|
angle = 0;
|
||||||
|
pitch = 0;
|
||||||
|
roll = 180; // otherwise it slides upwards (UT changes roll like this too)
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_WALL;
|
||||||
|
}
|
||||||
|
else if ( (pos.y+radius) <= (atbridge.pos.y-atbridge.radius) )
|
||||||
|
{
|
||||||
|
// north side
|
||||||
|
normal = (0,-1,0);
|
||||||
|
SetOrigin((pos.x,atbridge.pos.y-atbridge.radius,pos.z),false);
|
||||||
|
atbridgeofs = pos-atbridge.pos;
|
||||||
|
angle = 270;
|
||||||
|
pitch = 0;
|
||||||
|
roll = 180; // otherwise it slides upwards (UT changes roll like this too)
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_WALL;
|
||||||
|
}
|
||||||
|
else if ( (pos.y-radius) >= (atbridge.pos.y+atbridge.radius) )
|
||||||
|
{
|
||||||
|
// south side
|
||||||
|
normal = (0,1,0);
|
||||||
|
SetOrigin((pos.x,atbridge.pos.y+atbridge.radius,pos.z),false);
|
||||||
|
atbridgeofs = pos-atbridge.pos;
|
||||||
|
angle = 90;
|
||||||
|
pitch = 0;
|
||||||
|
roll = 180; // otherwise it slides upwards (UT changes roll like this too)
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_WALL;
|
||||||
|
}
|
||||||
|
else if ( pos.z >= (atbridge.pos.z+atbridge.height) )
|
||||||
|
{
|
||||||
|
// top of actor
|
||||||
|
normal = (0,0,1);
|
||||||
|
SetOrigin((pos.x,pos.y,atbridge.pos.z+atbridge.height),false);
|
||||||
|
atbridgeofs = pos-atbridge.pos;
|
||||||
|
pitch = -90;
|
||||||
|
angle = 0;
|
||||||
|
roll = FRandom[GES](0,360);
|
||||||
|
hittype = HIT_FLOOR;
|
||||||
|
}
|
||||||
|
else if ( (pos.z+height) <= atbridge.pos.z )
|
||||||
|
{
|
||||||
|
// bottom of actor
|
||||||
|
normal = (0,0,-1);
|
||||||
|
SetOrigin((pos.x,pos.y,atbridge.pos.z),false);
|
||||||
|
pitch = 90;
|
||||||
|
angle = 0;
|
||||||
|
roll = FRandom[GES](0,360);
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_CEILING;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// inside of actor, just shove to the top or bottom based on our Z velocity
|
||||||
|
if ( vel.z <= 0 )
|
||||||
|
{
|
||||||
|
normal = (0,0,1);
|
||||||
|
SetOrigin((pos.x,pos.y,atbridge.pos.z+atbridge.height),false);
|
||||||
|
atbridgeofs = pos-atbridge.pos;
|
||||||
|
pitch = -90;
|
||||||
|
angle = 0;
|
||||||
|
roll = FRandom[GES](0,360);
|
||||||
|
hittype = HIT_FLOOR;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
normal = (0,0,-1);
|
||||||
|
SetOrigin((pos.x,pos.y,atbridge.pos.z),false);
|
||||||
|
pitch = 90;
|
||||||
|
angle = 0;
|
||||||
|
roll = FRandom[GES](0,360);
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_CEILING;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if ( BlockingFloor )
|
||||||
|
{
|
||||||
|
// find closest 3d floor for its normal
|
||||||
|
for ( int i=0; i<BlockingFloor.Get3DFloorCount(); i++ )
|
||||||
|
{
|
||||||
|
if ( !(BlockingFloor.Get3DFloor(i).top.ZAtPoint(pos.xy) ~== floorz) ) continue;
|
||||||
|
ff = BlockingFloor.Get3DFLoor(i);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if ( ff )
|
||||||
|
{
|
||||||
|
normal = -ff.top.Normal;
|
||||||
|
atsector = ff.model;
|
||||||
|
atplane = 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
normal = BlockingFloor.floorplane.Normal;
|
||||||
|
atsector = BlockingFloor;
|
||||||
|
atplane = 0;
|
||||||
|
}
|
||||||
|
pitch = asin(-normal.z);
|
||||||
|
angle = atan2(normal.y,normal.x);
|
||||||
|
roll = FRandom[GES](0,360);
|
||||||
|
SetOrigin((pos.x,pos.y,floorz)+normal*0.5,false);
|
||||||
|
atz = pos.z-atsector.GetPlaneTexZ(atplane);
|
||||||
|
hittype = HIT_FLOOR;
|
||||||
|
}
|
||||||
|
else if ( BlockingCeiling )
|
||||||
|
{
|
||||||
|
// find closest 3d floor for its normal
|
||||||
|
for ( int i=0; i<BlockingCeiling.Get3DFloorCount(); i++ )
|
||||||
|
{
|
||||||
|
if ( !(BlockingCeiling.Get3DFloor(i).bottom.ZAtPoint(pos.xy) ~== ceilingz) ) continue;
|
||||||
|
ff = BlockingCeiling.Get3DFloor(i);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
if ( ff )
|
||||||
|
{
|
||||||
|
normal = -ff.bottom.Normal;
|
||||||
|
atsector = ff.model;
|
||||||
|
atplane = 0;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
normal = BlockingCeiling.ceilingplane.Normal;
|
||||||
|
atsector = BlockingCeiling;
|
||||||
|
atplane = 1;
|
||||||
|
}
|
||||||
|
pitch = asin(-normal.z);
|
||||||
|
angle = atan2(normal.y,normal.x);
|
||||||
|
roll = FRandom[GES](0,360);
|
||||||
|
SetOrigin((pos.x,pos.y,ceilingz)+normal*0.5,false);
|
||||||
|
atz = pos.z-atsector.GetPlaneTexZ(atplane);
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else if ( normal dot (0,0,-1) > 0.7 )
|
||||||
|
hittype = HIT_CEILING;
|
||||||
|
else hittype = HIT_FLOOR;
|
||||||
|
}
|
||||||
|
else if ( BlockingLine )
|
||||||
|
{
|
||||||
|
atline = BlockingLine;
|
||||||
|
normal = (-BlockingLine.delta.y,BlockingLine.delta.x,0).unit();
|
||||||
|
atside = 1;
|
||||||
|
if ( !BlockingLine.sidedef[1] || (CurSector == BlockingLine.frontsector) )
|
||||||
|
{
|
||||||
|
atside = 0;
|
||||||
|
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);
|
||||||
|
// attempt to guess line part (upper/mid/lower)
|
||||||
|
if ( !atline.sidedef[1] ) atpart = 0; // mid
|
||||||
|
else if ( atline.sidedef[atside?0:1].sector.ceilingplane.ZAtPoint(pos.xy) < pos.z ) atpart = 1; // upper
|
||||||
|
else if ( atline.sidedef[atside?0:1].sector.floorplane.ZAtPoint(pos.xy) > (pos.z+height) ) atpart = -1; // lower
|
||||||
|
else
|
||||||
|
{
|
||||||
|
atpart = 0;
|
||||||
|
// check if we're touching a 3d floor line
|
||||||
|
Sector backsector = atline.sidedef[atside?0:1].sector;
|
||||||
|
for ( int i=0; i<backsector.Get3DFloorCount(); i++ )
|
||||||
|
{
|
||||||
|
if ( backsector.Get3DFloor(i).bottom.ZAtPoint(pos.xy) > (pos.z+height) ) continue;
|
||||||
|
if ( backsector.Get3DFloor(i).top.ZAtPoint(pos.xy) < pos.z ) continue;
|
||||||
|
ff = backsector.Get3DFloor(i);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
// attach to it
|
||||||
|
if ( ff )
|
||||||
|
{
|
||||||
|
atline = ff.master;
|
||||||
|
atside = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( atpart == 1 )
|
||||||
|
{
|
||||||
|
if ( atline.flags&Line.ML_DONTPEGTOP ) atz = pos.z-atline.sidedef[atside].sector.GetPlaneTexZ(1);
|
||||||
|
else atz = pos.z-atline.sidedef[atside?0:1].sector.GetPlaneTexZ(1);
|
||||||
|
}
|
||||||
|
else if ( atpart == -1 )
|
||||||
|
{
|
||||||
|
if ( atline.flags&Line.ML_DONTPEGBOTTOM ) atz = pos.z-atline.sidedef[atside].sector.GetPlaneTexZ(0);
|
||||||
|
else atz = pos.z-atline.sidedef[atside?0:1].sector.GetPlaneTexZ(0);
|
||||||
|
}
|
||||||
|
else if ( atline.flags&Line.ML_DONTPEGBOTTOM ) atz = pos.z-atline.sidedef[atside].sector.GetPlaneTexZ(0);
|
||||||
|
else atz = pos.z-atline.sidedef[atside].sector.GetPlaneTexZ(1);
|
||||||
|
angle = atan2(normal.y,normal.x);
|
||||||
|
pitch = 0;
|
||||||
|
roll = 180; // otherwise it slides upwards (UT changes roll like this too)
|
||||||
|
if ( waterlevel > 0 ) hittype = HIT_FLOOR;
|
||||||
|
else hittype = HIT_WALL;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
SetStateLabel("XDeath");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
b = Spawn("BioHitbox",pos);
|
||||||
|
b.target = self;
|
||||||
|
A_PlaySound("ges/hit");
|
||||||
|
A_SprayDecal("BioSplat",-172);
|
||||||
|
int numpt = Min(100,int(Scale.x*10))+Random[GES](-5,5);
|
||||||
|
for ( int i=0; i<numpt; i++ )
|
||||||
|
{
|
||||||
|
Vector3 pvel = (normal+(FRandom[GES](-.8,.8),FRandom[GES](-.8,.8),FRandom[GES](-.8,.8))).unit()*FRandom[GES](3,6);
|
||||||
|
let s = Spawn("BioSpark",pos);
|
||||||
|
s.vel = pvel;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
action void A_DropDrip()
|
||||||
|
{
|
||||||
|
let d = Spawn("UBioSplash",pos+invoker.normal*2*scale.x);
|
||||||
|
d.target = target;
|
||||||
|
d.angle = angle;
|
||||||
|
d.pitch = pitch;
|
||||||
|
d.roll = roll;
|
||||||
|
d.master = self;
|
||||||
|
d.scale = scale*0.5;
|
||||||
|
d.vel.z -= 6;
|
||||||
|
}
|
||||||
|
action void A_GelExplode()
|
||||||
|
{
|
||||||
|
A_NoGravity();
|
||||||
|
A_Stop();
|
||||||
|
A_RemoveLight('BioLight');
|
||||||
|
A_SetRenderStyle(1.,STYLE_Add);
|
||||||
|
if ( invoker.b ) invoker.b.Destroy();
|
||||||
|
let s = Spawn("BioXLight",pos);
|
||||||
|
s.args[3] = int(s.args[3]*Scale.x);
|
||||||
|
invoker.deadtimer = -2;
|
||||||
|
if ( invoker.atline ) invoker.atline.RemoteActivate(target,invoker.atside,SPAC_Impact,pos);
|
||||||
|
UTMainHandler.DoBlast(self,Min(175,int(Scale.x*100)),40000*Scale.x);
|
||||||
|
A_Explode(int(40*Scale.x),Min(175,int(Scale.x*100)));
|
||||||
|
A_PlaySound("ges/explode",CHAN_VOICE);
|
||||||
|
int numpt = Min(300,int(Scale.x*30))+Random[GES](-10,10);
|
||||||
|
for ( int i=0; i<numpt; i++ )
|
||||||
|
{
|
||||||
|
Vector3 pvel = (FRandom[GES](-1,1),FRandom[GES](-1,1),FRandom[GES](-1,1)).unit()*FRandom[GES](3,12);
|
||||||
|
let s = Spawn("BioSpark",pos);
|
||||||
|
s.vel = pvel;
|
||||||
|
}
|
||||||
|
numpt = Min(100,int(Scale.x*10))+Random[GES](-4,4);
|
||||||
|
for ( int i=0; i<numpt; i++ )
|
||||||
|
{
|
||||||
|
Vector3 pvel = (FRandom[GES](-1,1),FRandom[GES](-1,1),FRandom[GES](-1,1)).unit()*FRandom[GES](1.2,2.4);
|
||||||
|
let s = Spawn("UTSmoke",pos+invoker.normal*4);
|
||||||
|
s.vel = pvel;
|
||||||
|
s.scale *= 2;
|
||||||
|
s.A_SetRenderStyle(0.5,STYLE_AddShaded);
|
||||||
|
if ( Random[GES](0,1) ) s.SetShade("40FF60");
|
||||||
|
else s.SetShade("60FF40");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Default
|
||||||
|
{
|
||||||
|
Obituary "$O_BIORIFLE";
|
||||||
|
DamageType 'Slime';
|
||||||
|
Radius 3;
|
||||||
|
Height 3;
|
||||||
|
Speed 11;
|
||||||
|
Gravity 0.25;
|
||||||
|
PROJECTILE;
|
||||||
|
-NOGRAVITY;
|
||||||
|
+SKYEXPLODE;
|
||||||
|
+EXPLODEONWATER;
|
||||||
|
+FORCERADIUSDMG;
|
||||||
|
+FORCEXYBILLBOARD;
|
||||||
|
+MOVEWITHSECTOR;
|
||||||
|
+NODAMAGETHRUST;
|
||||||
|
+HITTRACER;
|
||||||
|
+INTERPOLATEANGLES;
|
||||||
|
}
|
||||||
|
States
|
||||||
|
{
|
||||||
|
Spawn:
|
||||||
|
GELF ABCDEFGHIJKLM 1;
|
||||||
|
Loop;
|
||||||
|
Death:
|
||||||
|
GELH A 1 AlignSelf();
|
||||||
|
GELH BCDEFGHIJ 1;
|
||||||
|
GELH J 1 A_SetTics(Random[GES](10,30));
|
||||||
|
GELH J -1
|
||||||
|
{
|
||||||
|
invoker.deadtimer = Random[GES](250,300);
|
||||||
|
if ( invoker.hittype == HIT_WALL ) return ResolveState("Slide");
|
||||||
|
else if ( invoker.hittype == HIT_CEILING ) return ResolveState("Drip");
|
||||||
|
return ResolveState(null);
|
||||||
|
}
|
||||||
|
Stop;
|
||||||
|
Drip:
|
||||||
|
GELD ABCDEFGH 4;
|
||||||
|
GELD I 4 A_DropDrip();
|
||||||
|
GELD JKLM 4;
|
||||||
|
GELH J -1;
|
||||||
|
Stop;
|
||||||
|
Slide:
|
||||||
|
GELS ABCDEF 3;
|
||||||
|
GELS G -1;
|
||||||
|
Stop;
|
||||||
|
Crash:
|
||||||
|
XDeath:
|
||||||
|
TNT1 A 0 A_JumpIf(invoker.HitType==HIT_NONE,"Explode");
|
||||||
|
TNT1 A 0 A_JumpIf(invoker.HitType==HIT_WALL,2);
|
||||||
|
GELH J 1 A_SetTics(Random[GES](3,10));
|
||||||
|
Goto Explode;
|
||||||
|
GELS G 1 A_SetTics(Random[GES](3,10));
|
||||||
|
Goto Explode;
|
||||||
|
Explode:
|
||||||
|
TNT1 A 0 A_Jump(255,"Explode1","Explode2","Explode3");
|
||||||
|
Explode1:
|
||||||
|
GEX1 A 1 Bright A_GelExplode();
|
||||||
|
GEX1 BCDEFGHIJK 3 Bright;
|
||||||
|
Stop;
|
||||||
|
Explode2:
|
||||||
|
GEX2 A 1 Bright A_GelExplode();
|
||||||
|
GEX2 BCDEFGHIJK 3 Bright;
|
||||||
|
Stop;
|
||||||
|
Explode3:
|
||||||
|
GEX3 A 1 Bright A_GelExplode();
|
||||||
|
GEX3 BCDEFGHIJK 3 Bright;
|
||||||
|
Stop;
|
||||||
|
Shrivel:
|
||||||
|
GELX ABCDEFGHIJKL 1 Bright; // UNUSED
|
||||||
|
Stop;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Class UBioGlob : UBioGel
|
Class UBioGlob : UBioGel
|
||||||
{
|
{
|
||||||
|
int numsplash;
|
||||||
|
|
||||||
|
override void AlignSelf()
|
||||||
|
{
|
||||||
|
Super.AlignSelf();
|
||||||
|
if ( !bAMBUSH && (Scale.x > 1) ) numsplash = int(4*Scale.x)-1;
|
||||||
|
}
|
||||||
|
override void Tick()
|
||||||
|
{
|
||||||
|
Super.Tick();
|
||||||
|
if ( isFrozen() || !sting_biosplash ) return;
|
||||||
|
Vector3 ofs = (cos(angle)*cos(pitch),sin(angle)*cos(pitch),-sin(pitch));
|
||||||
|
for ( int i=0; i<2; i++ )
|
||||||
|
{
|
||||||
|
if ( numsplash-- <= 0 ) return;
|
||||||
|
Vector3 dir = (ofs+(FRandom[GES](-.8,.8),FRandom[GES](-.8,.8),FRandom[GES](-.8,.8))).unit();
|
||||||
|
A_SetScale(scale.x-0.15);
|
||||||
|
A_AttachLight('BioLight',DynamicLight.PointLight,"40FF80",int(8*scale.x),int(8*scale.x));
|
||||||
|
let d = Spawn("UBioSplash",pos+ofs*4);
|
||||||
|
d.target = target;
|
||||||
|
d.master = self;
|
||||||
|
d.scale *= FRandom[GES](0.5,0.7);
|
||||||
|
d.angle = atan2(dir.y,dir.x);
|
||||||
|
d.pitch = -asin(dir.z);
|
||||||
|
d.vel = (cos(d.angle)*cos(d.pitch),sin(d.angle)*cos(d.pitch),-sin(d.pitch))*d.speed*FRandom[GES](0.4,0.6);
|
||||||
|
d.vel.z -= 2;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Class UBioSplash : UBioGel
|
Class UBioSplash : UBioGel
|
||||||
{
|
{
|
||||||
|
override void AlignSelf()
|
||||||
|
{
|
||||||
|
Super.AlignSelf();
|
||||||
|
if ( hittype == HIT_CEILING ) hittype = HIT_FLOOR;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Class UBioRifle : UnrealWeapon
|
Class UBioRifle : UnrealWeapon
|
||||||
{
|
{
|
||||||
|
double chargesize, count;
|
||||||
|
bool bCharging;
|
||||||
|
|
||||||
|
action void A_BioFire( bool bAlt = false )
|
||||||
|
{
|
||||||
|
Weapon weap = Weapon(invoker);
|
||||||
|
if ( !weap ) return;
|
||||||
|
if ( !bAlt )
|
||||||
|
{
|
||||||
|
if ( weap.Ammo1.Amount <= 0 ) return;
|
||||||
|
if ( !weap.DepleteAmmo(weap.bAltFire,true,1) ) return;
|
||||||
|
}
|
||||||
|
invoker.chargesize = min(invoker.chargesize,4.9);
|
||||||
|
if ( bAlt ) A_PlaySound("ges/fire",CHAN_WEAPON,Dampener.Active(self)?.17:1.,pitch:max(.5,1.35-invoker.chargesize/8.));
|
||||||
|
else A_PlaySound("ges/fire",CHAN_WEAPON,Dampener.Active(self)?.17:1.);
|
||||||
|
invoker.FireEffect();
|
||||||
|
UTMainHandler.DoFlash(self,Color(48,0,255,0),1);
|
||||||
|
A_AlertMonsters();
|
||||||
|
if ( bAlt ) A_QuakeEx(1+int(0.5*invoker.chargesize),1+int(0.5*invoker.chargesize),1+int(0.5*invoker.chargesize),5+int(1.2*invoker.chargesize),0,64,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.05+0.01*invoker.chargesize);
|
||||||
|
else A_QuakeEx(1,1,1,5,0,1,"",QF_RELATIVE|QF_SCALEDOWN,rollIntensity:0.05);
|
||||||
|
Vector3 x, y, z;
|
||||||
|
double a, s;
|
||||||
|
[x, y, z] = dt_CoordUtil.GetAxes(pitch,angle,roll);
|
||||||
|
Vector3 origin = level.Vec3Offset(Vec2OffsetZ(0,0,player.viewz),10*x+4*y-5*z);
|
||||||
|
Actor p;
|
||||||
|
if ( bAlt )
|
||||||
|
{
|
||||||
|
p = Spawn("UBioGlob",origin);
|
||||||
|
p.A_SetScale(0.5+invoker.chargesize/3.5);
|
||||||
|
UTMainHandler.DoSwing(self,(FRandom[GES](-0.6,-1.3),FRandom[GES](-0.9,-0.2)),1+invoker.chargesize*0.3,-0.1,3,SWING_Spring,3,2);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
p = Spawn("UBioGel",origin);
|
||||||
|
UTMainHandler.DoSwing(self,(FRandom[GES](-0.6,-1.3),FRandom[GES](-0.9,-0.2)),2,-0.5,2,SWING_Spring,2,2);
|
||||||
|
}
|
||||||
|
p.angle = angle;
|
||||||
|
p.pitch = BulletSlope();
|
||||||
|
p.vel = (cos(p.angle)*cos(p.pitch),sin(p.angle)*cos(p.pitch),-sin(p.pitch))*p.speed;
|
||||||
|
p.target = self;
|
||||||
|
for ( int i=0; i<12; i++ )
|
||||||
|
{
|
||||||
|
let s = Spawn("UTViewSmoke",origin);
|
||||||
|
UTViewSmoke(s).ofs = (10,4,-5);
|
||||||
|
s.scale *= 2.0;
|
||||||
|
s.target = self;
|
||||||
|
if ( Random[GES](0,1) ) s.SetShade("40FF60");
|
||||||
|
else s.SetShade("60FF40");
|
||||||
|
s.A_SetRenderStyle(0.5,STYLE_AddShaded);
|
||||||
|
UTViewSmoke(s).vvel += (FRandom[GES](0.8,1.6),FRandom[GES](-0.5,0.5),FRandom[GES](-0.5,0.5));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
action void A_ChargeUp()
|
||||||
|
{
|
||||||
|
let weap = Weapon(invoker);
|
||||||
|
if ( (invoker.chargesize < 4.9) && (weap.Ammo1.Amount > 0) )
|
||||||
|
{
|
||||||
|
invoker.chargesize += 1./TICRATE;
|
||||||
|
invoker.count += 1./TICRATE;
|
||||||
|
if ( invoker.count > 1. )
|
||||||
|
{
|
||||||
|
weap.DepleteAmmo(weap.bAltFire,true,1);
|
||||||
|
invoker.count = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( !(player.cmd.buttons&BT_ALTATTACK) )
|
||||||
|
player.SetPSPrite(PSP_WEAPON,invoker.FindState("AltRelease"));
|
||||||
|
}
|
||||||
|
action void A_BeginCharge()
|
||||||
|
{
|
||||||
|
let weap = Weapon(invoker);
|
||||||
|
invoker.bCharging = true;
|
||||||
|
weap.DepleteAmmo(weap.bAltFire,true,1);
|
||||||
|
invoker.count = invoker.chargesize = 0;
|
||||||
|
A_PlaySound("ges/load",CHAN_WEAPON,Dampener.Active(self)?.13:1.,true);
|
||||||
|
A_Overlay(-9999,"Dummy2");
|
||||||
|
}
|
||||||
|
override bool CheckAmmo( int fireMode, bool autoSwitch, bool requireAmmo, int ammocount )
|
||||||
|
{
|
||||||
|
if ( bCharging ) return true;
|
||||||
|
return Super.CheckAmmo(fireMode,autoSwitch,requireAmmo,ammocount);
|
||||||
|
}
|
||||||
Default
|
Default
|
||||||
{
|
{
|
||||||
Tag "$T_BIORIFLE";
|
Tag "$T_BIORIFLE";
|
||||||
|
|
@ -75,5 +679,74 @@ Class UBioRifle : UnrealWeapon
|
||||||
Stop;
|
Stop;
|
||||||
BIOP B -1;
|
BIOP B -1;
|
||||||
Stop;
|
Stop;
|
||||||
|
Select:
|
||||||
|
BIOS A 1 A_Raise(int.max);
|
||||||
|
Wait;
|
||||||
|
Ready:
|
||||||
|
BIOS ABCDEFGHIJKLMNOPQRST 1 A_WeaponReady(WRF_NOFIRE);
|
||||||
|
Goto Idle;
|
||||||
|
Dummy:
|
||||||
|
TNT1 A 1
|
||||||
|
{
|
||||||
|
A_CheckReload();
|
||||||
|
A_WeaponReady();
|
||||||
|
// that's a long-ass if
|
||||||
|
if ( player.FindPSprite(PSP_WEAPON).CurState.InStateSequence(invoker.FindState("Idle")) && (player.cmd.forwardmove || player.cmd.sidemove) && (player.vel.length() > 0.5) )
|
||||||
|
player.SetPSPrite(PSP_WEAPON,invoker.FindState("Sway"));
|
||||||
|
}
|
||||||
|
Wait;
|
||||||
|
Idle:
|
||||||
|
#### # 4 A_Overlay(-9999,"Dummy"); // little hackeroo to make this more responsive
|
||||||
|
BIOI A 1 A_Jump(80,"Drip");
|
||||||
|
BIOI A -1;
|
||||||
|
Stop;
|
||||||
|
Sway:
|
||||||
|
#### # 3;
|
||||||
|
BIOW ABCDEFGHIJKLMNOPQRS 3 A_JumpIf((!player.cmd.forwardmove && !player.cmd.sidemove) || (player.vel.length() < 0.5),"Idle");
|
||||||
|
Goto Sway+1;
|
||||||
|
Drip:
|
||||||
|
#### # 4;
|
||||||
|
BIOT ABC 6;
|
||||||
|
BIOT D 6 A_PlaySound("ges/drip",CHAN_ITEM,Dampener.Active(self)?.05:.5);
|
||||||
|
BIOT EFG 6;
|
||||||
|
BIOI A 4;
|
||||||
|
Goto Idle;
|
||||||
|
Fire:
|
||||||
|
BIOF A 0
|
||||||
|
{
|
||||||
|
A_Overlay(-9999,"Null");
|
||||||
|
A_BioFire();
|
||||||
|
}
|
||||||
|
BIOF ABCDEFGHIJ 1;
|
||||||
|
Goto Idle;
|
||||||
|
Dummy2:
|
||||||
|
TNT1 A 1 A_ChargeUp();
|
||||||
|
Wait;
|
||||||
|
AltFire:
|
||||||
|
#### # 2 A_BeginCharge();
|
||||||
|
BIOA ABCDEFGHIJKLMNOPQRSTUVWXYZ 6;
|
||||||
|
BIA2 ABC 6;
|
||||||
|
BIA2 D 0 A_JumpIf(sting_bhold,1);
|
||||||
|
Goto AltRelease;
|
||||||
|
BIA2 D 3;
|
||||||
|
BIA2 CBA 6;
|
||||||
|
BIOA ZYXWVUT 6;
|
||||||
|
BIOA S 0;
|
||||||
|
Goto AltRelease;
|
||||||
|
AltRelease:
|
||||||
|
#### # 1
|
||||||
|
{
|
||||||
|
A_Overlay(-9999,"Null");
|
||||||
|
if ( self is 'UTPlayer' )
|
||||||
|
UTPlayer(self).PlayAttacking3();
|
||||||
|
A_BioFire(true);
|
||||||
|
}
|
||||||
|
BIOF ABCDEFGHIJ 2;
|
||||||
|
Goto Idle;
|
||||||
|
Deselect:
|
||||||
|
BIOD A 0 A_Overlay(-9999,"Null");
|
||||||
|
BIOD ABCDEF 1;
|
||||||
|
BIOD G 1 A_Lower(int.max);
|
||||||
|
Wait;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -233,7 +233,8 @@ Class UPlayer : UTPlayer
|
||||||
let psp = player.FindPSprite(PSP_WEAPON);
|
let psp = player.FindPSprite(PSP_WEAPON);
|
||||||
if ( ((player.ReadyWeapon is 'UBioRifle') && (player.buttons&BT_ALTATTACK))
|
if ( ((player.ReadyWeapon is 'UBioRifle') && (player.buttons&BT_ALTATTACK))
|
||||||
|| (player.ReadyWeapon is 'Eightball')
|
|| (player.ReadyWeapon is 'Eightball')
|
||||||
|| ((player.ReadyWeapon is 'DispersionPistol') && DispersionPistol(player.ReadyWeapon).bCharging) )
|
|| ((player.ReadyWeapon is 'DispersionPistol') && DispersionPistol(player.ReadyWeapon).bCharging)
|
||||||
|
|| ((player.ReadyWeapon is 'UBioRifle') && UBioRifle(player.ReadyWeapon).bCharging) )
|
||||||
{
|
{
|
||||||
if ( !InStateSequence(CurState,FindState("MissileRepStill")) )
|
if ( !InStateSequence(CurState,FindState("MissileRepStill")) )
|
||||||
SetStateLabel("MissileRepStill");
|
SetStateLabel("MissileRepStill");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue