diff --git a/Readme.md b/Readme.md index 4476b4d..bb72607 100644 --- a/Readme.md +++ b/Readme.md @@ -56,6 +56,7 @@ This mod requires GZDoom 3.7.0 or later. - Add some more effects - Lava/Slime footstep sounds? - UT gore system (toggleable) + - Heretic compatibility ## Future plans diff --git a/animdefs.txt b/animdefs.txt index 1365cc2..dfd7600 100644 --- a/animdefs.txt +++ b/animdefs.txt @@ -5,21 +5,6 @@ texture static1 pic static2 tics 1 pic static3 tics 1 pic static4 tics 1 -texture FIZZHP00 - pic FIZZHP00 tics 8 - pic FIZZHP01 tics 8 - pic FIZZHP02 tics 8 - pic FIZZHP03 tics 8 -texture FIZZHP10 - pic FIZZHP10 tics 8 - pic FIZZHP11 tics 8 - pic FIZZHP12 tics 8 - pic FIZZHP13 tics 8 -texture FIZZHP20 - pic FIZZHP20 tics 8 - pic FIZZHP21 tics 8 - pic FIZZHP22 tics 8 - pic FIZZHP23 tics 8 texture invis00 pic invis00 tics 2 pic invis01 tics 2 diff --git a/filter/game-heretic/zmapinfo.txt b/filter/game-heretic/zmapinfo.txt new file mode 100644 index 0000000..cdbb4a4 --- /dev/null +++ b/filter/game-heretic/zmapinfo.txt @@ -0,0 +1,14 @@ +GameInfo +{ + AddEventHandlers = "RedeemerHUDHandler", "UTMainHandler" + PlayerClasses = "UTPlayerHereticCompatTMale1", "UTPlayerHereticCompatTMale2", "UTPlayerHereticCompatTFemale1", "UTPlayerHereticCompatTFemale2", "UTPlayerHereticCompatTBoss" + StatusBarClass = "UTHud" + BackpackType = "UTBackpack" + BorderFlat = "TEMPBG" + Border = 0,0,"","","","","","","","" +} + +// titlemaps need a mapinfo entry in devbuilds +map TITLEMAP "UT Logo Map" +{ +} diff --git a/gldefs.txt b/gldefs.txt index e2c887c..8f96065 100644 --- a/gldefs.txt +++ b/gldefs.txt @@ -2,53 +2,20 @@ HardwareShader Texture "models/Jgreen.png" { Shader "shaders/glsl/MeshEnviroMap.fp" } -Brightmap Texture "FIZZHP00" +HardwareShader Texture "fizzside" { - Map "brightmaps/fullbright.png" + Shader "shaders/glsl/FizzDistortX.fp" + Texture "warptex" "textures/warptex.png" } -Brightmap Texture "FIZZHP01" +HardwareShader Texture "fizztop" { - Map "brightmaps/fullbright.png" + Shader "shaders/glsl/FizzDistortXY.fp" + Texture "warptex" "textures/warptex.png" } -Brightmap Texture "FIZZHP02" +HardwareShader Texture "fizzfull" { - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP03" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP10" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP11" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP12" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP13" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP20" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP21" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP22" -{ - Map "brightmaps/fullbright.png" -} -Brightmap Texture "FIZZHP23" -{ - Map "brightmaps/fullbright.png" + Shader "shaders/glsl/FizzDistortXY.fp" + Texture "warptex" "textures/warptex.png" } HardwareShader Texture "models/jhbox1.png" { @@ -252,6 +219,10 @@ HardwareShader Texture "models/RedSkin2.png" { Shader "shaders/glsl/MeshEnviroMap_AmbientGlow.fp" } +HardwareShader Texture "models/NewGreen.png" +{ + Shader "shaders/glsl/MeshEnviroMap_AmbientGlow.fp" +} HardwareShader Texture "models/bpak.png" { Shader "shaders/glsl/AmbientGlow.fp" @@ -561,6 +532,14 @@ PulseLight "UTGoldKeyLight" Interval 2.0 Offset 0 16 0 } +PulseLight "UTGreenKeyLight" +{ + Color 0.0 1.0 0.0 + Size 15 + SecondarySize 20 + Interval 2.0 + Offset 0 16 0 +} Object "UTRedSkull" { Frame "USKL" { light "UTRedKeyLight" } @@ -585,6 +564,18 @@ Object "UTGoldKey" { Frame "UKEY" { light "UTGoldKeyLight" } } +Object "UTHereticYellowKey" +{ + Frame "UKEY" { light "UTGoldKeyLight" } +} +Object "UTHereticGreenKey" +{ + Frame "UKEY" { light "UTGreenKeyLight" } +} +Object "UTHereticBlueKey" +{ + Frame "UKEY" { light "UTBlueKeyLight" } +} HardwareShader PostProcess scene { Name "RedeemerView" diff --git a/modeldef.misc b/modeldef.misc index f4b9606..f00dcec 100644 --- a/modeldef.misc +++ b/modeldef.misc @@ -50,7 +50,7 @@ Model "UTHealthPack" Model 0 "hbox_d.3d" // indices start at 1 for this mesh SurfaceSkin 0 1 "jhbox1.png" - SurfaceSkin 0 2 "FIZZHP00" + SurfaceSkin 0 2 "fizzfull" Scale 0.2 0.24 0.2 RollOffset -90 ZOffset 16 @@ -64,8 +64,8 @@ Model "UTHealthBox" Model 0 "hboxbeta_d.3d" // indices start at 1 for this mesh SurfaceSkin 0 1 "jhboxbeta1.png" - SurfaceSkin 0 2 "FIZZHP10" - SurfaceSkin 0 3 "FIZZHP10" + SurfaceSkin 0 2 "fizzfull" + SurfaceSkin 0 3 "fizzfull" Scale 0.08 0.08 0.096 ZOffset 4 @@ -78,7 +78,7 @@ Model "UTMedBox" Model 0 "MedBox_d.3d" // indices start at 1 for this mesh SurfaceSkin 0 1 "JMedBox1.png" - SurfaceSkin 0 2 "FIZZHP10" + SurfaceSkin 0 2 "fizzfull" Scale 0.06 0.06 0.072 ZOffset 5 @@ -90,8 +90,8 @@ Model "UTHealthBonus" Path "models" Model 0 "Vial_d.3d" SurfaceSkin 0 0 "JVial0.png" - SurfaceSkin 0 1 "FIZZHP20" - SurfaceSkin 0 2 "FIZZHP20" + SurfaceSkin 0 1 "fizzside" + SurfaceSkin 0 2 "fizztop" Scale 0.04 0.04 0.048 ZOffset 8 DONTCULLBACKFACES @@ -228,6 +228,39 @@ Model "UTBlueKey" FrameIndex UKEY C 0 0 } +Model "UTHereticYellowKey" +{ + Path "models" + Model 0 "MercSymbol_d.3d" + Skin 0 "GoldSkin2.png" + Scale 0.08 0.08 0.096 + ZOffset 16 + ROTATING + + FrameIndex UKEY B 0 0 +} +Model "UTHereticGreenKey" +{ + Path "models" + Model 0 "UDamage_d.3d" + Skin 0 "NewGreen.png" + Scale 0.08 0.08 0.096 + ZOffset 16 + ROTATING + + FrameIndex UKEY D 0 0 +} +Model "UTHereticBlueKey" +{ + Path "models" + Model 0 "DomB_d.3d" + Skin 0 "BlueSkin2.png" + Scale 0.04 0.04 0.048 + ZOffset 16 + ROTATING + + FrameIndex UKEY C 0 0 +} Model "UTBackpack" { diff --git a/models/NewGreen.png b/models/NewGreen.png new file mode 100644 index 0000000..58f1ae4 Binary files /dev/null and b/models/NewGreen.png differ diff --git a/shaders/glsl/FizzDistortX.fp b/shaders/glsl/FizzDistortX.fp new file mode 100644 index 0000000..3e62195 --- /dev/null +++ b/shaders/glsl/FizzDistortX.fp @@ -0,0 +1,18 @@ +vec4 ProcessLight( vec4 color ) +{ + return vec4(1.0); +} + +vec4 ProcessTexel() +{ + vec2 coord = vTexCoord.st; + vec2 dist = 2.0*texture(warptex,vTexCoord.st).xy-1.0; + dist.x *= abs(mod(dist.y+timer*3.34536,4)-2)-1; + coord.x += dist.x*0.12; + dist = 2.0*texture(warptex,vTexCoord.st*2.0).xy-1.0; + dist.y *= abs(mod(dist.x+timer*5.45363,4)-2)-1; + coord.y -= dist.y*0.09; + coord.y = clamp(coord.y,0.0,1.0); + coord.x += timer*0.5346; + return getTexel(coord); +} diff --git a/shaders/glsl/FizzDistortXY.fp b/shaders/glsl/FizzDistortXY.fp new file mode 100644 index 0000000..8ecc683 --- /dev/null +++ b/shaders/glsl/FizzDistortXY.fp @@ -0,0 +1,18 @@ +vec4 ProcessLight( vec4 color ) +{ + return vec4(1.0); +} + +vec4 ProcessTexel() +{ + vec2 coord = vTexCoord.st; + vec2 dist = 2.0*texture(warptex,vTexCoord.st*0.6).xy-1.0; + dist.x *= abs(mod(dist.y+timer*1.34536,4)-2)-1; + coord.x += dist.x*0.12; + dist = 2.0*texture(warptex,vTexCoord.st*1.2).xy-1.0; + dist.y *= abs(mod(dist.x+timer*1.45363,4)-2)-1; + coord.y -= dist.y*0.09; + coord.x += timer*0.05346; + coord.y += timer*0.03425; + return getTexel(coord); +} diff --git a/textures.misc b/textures.misc index 6aa62ec..1022a10 100644 --- a/textures.misc +++ b/textures.misc @@ -1,123 +1,3 @@ -Texture "FIZZHP00",256,256 -{ - Patch "LAVA1",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",128,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",192,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",64,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",128,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",192,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",0,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",64,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",128,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",192,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",0,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",64,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",128,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",192,192{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP01",256,256 -{ - Patch "LAVA2",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",128,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",192,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",64,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",128,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",192,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",0,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",64,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",128,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",192,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",0,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",64,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",128,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",192,192{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP02",256,256 -{ - Patch "LAVA3",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",128,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",192,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",64,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",128,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",192,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",0,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",64,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",128,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",192,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",0,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",64,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",128,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",192,192{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP03",256,256 -{ - Patch "LAVA4",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",128,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",192,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",64,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",128,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",192,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",0,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",64,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",128,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",192,128{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",0,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",64,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",128,192{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",192,192{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP10",128,128 -{ - Patch "LAVA1",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA1",64,64{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP11",128,128 -{ - Patch "LAVA2",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA2",64,64{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP12",128,128 -{ - Patch "LAVA3",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA3",64,64{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP13",128,128 -{ - Patch "LAVA4",0,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",64,0{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",0,64{Translation "0:255=#[0,0,255]"} - Patch "LAVA4",64,64{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP20",64,64 -{ - Patch "LAVA1",0,0{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP21",64,64 -{ - Patch "LAVA2",0,0{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP22",64,64 -{ - Patch "LAVA3",0,0{Translation "0:255=#[0,0,255]"} -} -Texture "FIZZHP23",64,64 -{ - Patch "LAVA4",0,0{Translation "0:255=#[0,0,255]"} -} Sprite "HBOXA0",1,1{} Sprite "HBOXB0",1,1{} Sprite "HBOXC0",1,1{} @@ -142,3 +22,4 @@ Sprite "USKLC0",1,1{} Sprite "UKEYA0",1,1{} Sprite "UKEYB0",1,1{} Sprite "UKEYC0",1,1{} +Sprite "UKEYD0",1,1{} diff --git a/textures/fizzfull.png b/textures/fizzfull.png new file mode 100644 index 0000000..a33a988 Binary files /dev/null and b/textures/fizzfull.png differ diff --git a/textures/fizzside.png b/textures/fizzside.png new file mode 100644 index 0000000..b25eb0f Binary files /dev/null and b/textures/fizzside.png differ diff --git a/textures/fizztop.png b/textures/fizztop.png new file mode 100644 index 0000000..51fed75 Binary files /dev/null and b/textures/fizztop.png differ diff --git a/textures/warptex.png b/textures/warptex.png new file mode 100644 index 0000000..de45a9d Binary files /dev/null and b/textures/warptex.png differ diff --git a/zscript/compat.zsc b/zscript/compat.zsc index 4f6ea5f..412b609 100644 --- a/zscript/compat.zsc +++ b/zscript/compat.zsc @@ -1,3 +1,199 @@ -// TODO Heretic keys +// Heretic keys +Class UTHereticYellowKey : KeyYellow +{ + Default + { + Tag "Red Key"; + Species "KeyYellow"; + Inventory.PickupMessage "You got the Yellow Key."; + } + States + { + Spawn: + UKEY B -1; + Stop; + } +} -// TODO Alternative player classes used for compatibility with Heretic, Hexen, Strife and Chex +Class UTHereticGreenKey : KeyGreen +{ + Default + { + Tag "Green Key"; + Species "KeyGreen"; + Inventory.PickupMessage "You got the Green Key."; + } + States + { + Spawn: + UKEY D -1; + Stop; + } +} + +Class UTHereticBlueKey : KeyBlue +{ + Default + { + Tag "Blue Key"; + Species "KeyBlue"; + Inventory.PickupMessage "You got the Blue Key."; + } + States + { + Spawn: + UKEY C -1; + Stop; + } +} + +// Alternative player classes for compatibility with Heretic sprites +Class UTPlayerHereticCompat : UTPlayer +{ + Default + { + Player.ColorRange 225, 240; + Player.Colorset 0, "Green", 225, 240, 238; + Player.Colorset 1, "Yellow", 114, 129, 127; + Player.Colorset 2, "Red", 145, 160, 158; + Player.Colorset 3, "Blue", 190, 205, 203; + Player.Colorset 4, "Brown", 67, 82, 80; + Player.Colorset 5, "Light Gray", 9, 24, 22; + Player.Colorset 6, "Light Brown", 74, 89, 87; + Player.Colorset 7, "Light Red", 150, 165, 163; + Player.Colorset 8, "Light Blue", 192, 207, 205; + Player.Colorset 9, "Beige", 95, 110, 108; + } + States + { + Spawn: + PLAY A -1; + Stop; + See: + PLAY ABCD 4; + Loop; + Melee: + Missile: + PLAY F 6 BRIGHT; + PLAY E 12; + Goto Spawn; + Pain: + PLAY G 4; + PLAY G 4 A_Pain; + Goto Spawn; + Death: + PLAY H 6 A_PlayerSkinCheck("AltSkinDeath"); + PLAY I 6 A_PlayerScream; + PLAY JK 6; + PLAY L 6 A_NoBlocking; + PLAY MNO 6; + PLAY P -1; + Stop; + XDeath: + PLAY Q 0 A_PlayerSkinCheck("AltSkinXDeath"); + PLAY Q 5 A_PlayerScream; + PLAY R 0 A_NoBlocking; + PLAY R 5 A_SkullPop; + PLAY STUVWX 5; + PLAY Y -1; + Stop; + Burn: + FDTH A 5 BRIGHT A_PlaySound("*burndeath"); + FDTH B 4 BRIGHT; + FDTH C 5 BRIGHT; + FDTH D 4 BRIGHT A_PlayerScream; + FDTH E 5 BRIGHT; + FDTH F 4 BRIGHT; + FDTH G 5 BRIGHT A_PlaySound("*burndeath"); + FDTH H 4 BRIGHT; + FDTH I 5 BRIGHT; + FDTH J 4 BRIGHT; + FDTH K 5 BRIGHT; + FDTH L 4 BRIGHT; + FDTH M 5 BRIGHT; + FDTH N 4 BRIGHT; + FDTH O 5 BRIGHT A_NoBlocking; + FDTH P 4 BRIGHT; + FDTH Q 5 BRIGHT; + FDTH R 4 BRIGHT; + ACLO E 35 A_CheckPlayerDone; + Wait; + AltSkinDeath: + PLAY H 10; + PLAY I 10 A_PlayerScream; + PLAY J 10 A_NoBlocking; + PLAY KLM 10; + PLAY N -1; + Stop; + AltSkinXDeath: + PLAY O 5; + PLAY P 5 A_XScream; + PLAY Q 5 A_NoBlocking; + PLAY RSTUV 5; + PLAY W -1; + Stop; + } +} + +Class UTPlayerHereticCompatTMale1 : UTPlayerHereticCompat +{ + Default + { + Player.SoundClass "tmale1"; + Player.DisplayName "M Commando"; + Player.Portrait "Blake"; + -NOMENU; + } +} +Class UTPlayerHereticCompatTMale2 : UTPlayerHereticCompat +{ + Default + { + Player.SoundClass "tmale2"; + Player.DisplayName "M Soldier"; + Player.Portrait "Brock"; + -NOMENU; + } +} +Class UTPlayerHereticCompatTFemale1 : UTPlayerHereticCompat +{ + Default + { + Player.SoundClass "tfemale"; + Player.DisplayName "F Commando"; + Player.Portrait "Ivana"; + UTPlayer.DollType DOLL_Female; + -NOMENU; + } +} +Class UTPlayerHereticCompatTFemale2 : UTPlayerHereticCompat +{ + Default + { + Player.SoundClass "tfemale"; + Player.DisplayName "F Soldier"; + Player.Portrait "Lauren"; + UTPlayer.DollType DOLL_Female; + -NOMENU; + } +} +Class UTPlayerHereticCompatTBoss : UTPlayerHereticCompat +{ + transient CVar bossfootsteps; + Default + { + Player.SoundClass "tboss"; + Player.DisplayName "Boss"; + Player.Portrait "Xan"; + UTPlayer.DollType DOLL_Boss; + // should have NOBLOOD, but Xan did bleed in vanilla UT so... + // (this is what gave birth to the theory that Xan was actually Jerl Liandri himself) + -NOMENU; + } + override void PlayFootstep( double vol ) + { + if ( !bossfootsteps ) bossfootsteps = CVar.GetCVar('flak_bossfootsteps',players[consoleplayer]); + if ( bossfootsteps.GetBool() ) A_PlaySound("ut/bossfootstep",CHAN_5,vol); + else Super.PlayFootstep(vol); + } +} \ No newline at end of file diff --git a/zscript/utcommon.zsc b/zscript/utcommon.zsc index c039703..d65c938 100644 --- a/zscript/utcommon.zsc +++ b/zscript/utcommon.zsc @@ -1411,54 +1411,64 @@ Class UTMainHandler : StaticEventHandler override void CheckReplacement( ReplaceEvent e ) { - if ( e.Replacee == 'Chainsaw' ) + if ( (e.Replacee == 'Chainsaw') || (e.Replacee == 'Gauntlets') ) { if ( Random[Replacements](0,1) ) e.Replacement = 'UTChainsaw'; else e.Replacement = 'Enforcer'; } - else if ( e.Replacee == 'Fist' ) e.Replacement = 'ImpactHammer'; - else if ( e.Replacee == 'Pistol' ) e.Replacement = 'Enforcer'; - else if ( (e.Replacee == 'Shotgun') || (e.Replacee == 'SuperShotgun') ) + else if ( (e.Replacee == 'Fist') || (e.Replacee == 'Staff') ) e.Replacement = 'ImpactHammer'; + else if ( (e.Replacee == 'Pistol') || (e.Replacee == 'GoldWand') ) e.Replacement = 'Enforcer'; + else if ( (e.Replacee == 'Shotgun') || (e.Replacee == 'SuperShotgun') || (e.Replacee == 'Crossbow') ) { if ( !Random[Replacements](0,3) ) e.Replacement = 'Enforcer'; else if ( Random[Replacements](0,1) ) e.Replacement = 'BioRifle'; else e.Replacement = 'ShockRifle'; } - else if ( e.Replacee == 'Chaingun' ) + else if ( (e.Replacee == 'Chaingun') || (e.Replacee == 'Blaster') ) { if ( Random[Replacements](0,2) ) e.Replacement = 'PulseGun'; else e.Replacement = 'Ripper2'; } - else if ( e.Replacee == 'RocketLauncher' ) + else if ( (e.Replacee == 'RocketLauncher') || (e.Replacee == 'PhoenixRod') ) { if ( Random[Replacements](0,1) ) e.Replacement = 'FlakCannon'; else e.Replacement = 'UTRocketLauncher'; } - else if ( e.Replacee == 'PlasmaRifle' ) + else if ( (e.Replacee == 'PlasmaRifle') || (e.Replacee == 'SkullRod') ) { if ( Random[Replacements](0,1) ) e.Replacement = 'Minigun'; else e.Replacement = 'SniperRifle'; } else if ( e.Replacee == 'BFG9000' ) e.Replacement = 'WarheadLauncher'; - else if ( e.Replacee == 'Clip' ) e.Replacement = 'EClip'; - else if ( e.Replacee == 'ClipBox' ) + else if ( e.Replacee == 'Mace' ) + { + if ( !Random[Replacements](0,6) ) e.Replacement = 'EnhancedShockRifle'; + else e.Replacement = 'WarheadLauncher'; + } + else if ( (e.Replacee == 'Clip') || (e.Replacee == 'GoldWandAmmo') || (e.Replacee == 'GoldWandHefty') ) e.Replacement = 'EClip'; + else if ( (e.Replacee == 'ClipBox') ) { if ( !Random[Replacements](0,2) ) e.Replacement = 'EClip'; else if ( Random[Replacements](0,2) ) e.Replacement = 'PulseAmmo'; else e.Replacement = 'RipperAmmo'; } - else if ( e.Replacee == 'Shell' ) + else if ( (e.Replacee == 'BlasterAmmo') || (e.Replacee == 'BlasterHefty') ) + { + if ( Random[Replacements](0,2) ) e.Replacement = 'PulseAmmo'; + else e.Replacement = 'RipperAmmo'; + } + else if ( (e.Replacee == 'Shell') || (e.Replacee == 'CrossbowAmmo') ) { if ( !Random[Replacements](0,2) ) e.Replacement = 'EClip'; else if ( Random[Replacements](0,1) ) e.Replacement = 'BioAmmo2'; else e.Replacement = 'ShockAmmo2'; } - else if ( e.Replacee == 'ShellBox' ) + else if ( (e.Replacee == 'ShellBox') || (e.Replacee == 'CrossbowHefty') ) { if ( Random[Replacements](0,1) ) e.Replacement = 'BioAmmo'; else e.Replacement = 'ShockAmmo'; } - else if ( e.Replacee == 'RocketAmmo' ) + else if ( (e.Replacee == 'RocketAmmo') || (e.Replacee == 'PhoenixRodAmmo') || (e.Replacee == 'MaceAmmo') ) { if ( Random[Replacements](0,1) ) { @@ -1471,38 +1481,51 @@ Class UTMainHandler : StaticEventHandler else e.Replacement = 'UTRocketAmmo2'; } } - else if ( e.Replacee == 'RocketBox' ) + else if ( (e.Replacee == 'RocketBox') || (e.Replacee == 'PhoenixRodHefty') || (e.Replacee == 'MaceHefty') ) { if ( Random[Replacements](0,1) ) e.Replacement = 'FlakAmmo'; else e.Replacement = 'UTRocketAmmo'; } - else if ( e.Replacee == 'Cell' ) + else if ( (e.Replacee == 'Cell') || (e.Replacee == 'SkullRodAmmo') ) { if ( Random[Replacements](0,1) ) e.Replacement = 'EClip'; else if ( !Random[Replacements](0,3) ) e.Replacement = 'RifleAmmo'; else e.Replacement = 'RifleAmmo2'; } - else if ( e.Replacee == 'CellPack' ) + else if ( (e.Replacee == 'CellPack') || (e.Replacee == 'SkullRodHefty') ) { if ( !Random[Replacements](0,6) ) e.Replacement = 'WarheadAmmo'; else if ( Random[Replacements](0,1) ) e.Replacement = 'MiniAmmo'; else e.Replacement = 'RifleAmmo'; } else if ( e.Replacee == 'InvulnerabilitySphere' ) e.Replacement = 'EnhancedShockRifle'; - else if ( e.Replacee == 'Berserk' ) e.Replacement = 'UDamage'; - else if ( e.Replacee == 'Soulsphere' ) e.Replacement = 'UTHealthPack'; - else if ( e.Replacee == 'Megasphere' ) e.Replacement = 'UTShieldBelt'; - else if ( e.Replacee == 'Allmap' ) e.Replacement = 'UTMapRevealer'; - else if ( e.Replacee == 'BlurSphere' ) e.Replacement = 'UTInvisibility'; - else if ( e.Replacee == 'Infrared' ) e.Replacement = 'Searchlight'; - else if ( e.Replacee == 'RadSuit' ) e.Replacement = 'UTJumpBoots'; - else if ( e.Replacee == 'Backpack' ) e.Replacement = 'UTBackpack'; - else if ( e.Replacee == 'ArmorBonus' ) e.Replacement = 'UTArmorBonus'; - else if ( e.Replacee == 'HealthBonus' ) e.Replacement = 'UTHealthBonus'; - else if ( e.Replacee == 'GreenArmor' ) e.Replacement = 'UTThighPads'; - else if ( e.Replacee == 'BlueArmor' ) e.Replacement = 'UTBodyArmor'; + else if ( (e.Replacee == 'Berserk') || (e.Replacee == 'ArtiTomeOfPower') || (e.Replacee == 'ArtiEgg') ) e.Replacement = 'UDamage'; + else if ( (e.Replacee == 'Soulsphere') || (e.Replacee == 'ArtiSuperHealth') ) e.Replacement = 'UTHealthPack'; + else if ( (e.Replacee == 'Megasphere') || (e.Replacee == 'ArtiInvulnerability') ) e.Replacement = 'UTShieldBelt'; + else if ( (e.Replacee == 'Allmap') || (e.Replacee == 'SuperMap') ) e.Replacement = 'UTMapRevealer'; + else if ( (e.Replacee == 'BlurSphere') || (e.Replacee == 'ArtiInvisibility') ) e.Replacement = 'UTInvisibility'; + else if ( (e.Replacee == 'Infrared') || (e.Replacee == 'ArtiTorch') ) e.Replacement = 'Searchlight'; + else if ( (e.Replacee == 'RadSuit') || (e.Replacee == 'ArtiFly') ) e.Replacement = 'UTJumpBoots'; + else if ( (e.Replacee == 'Backpack') || (e.Replacee == 'BagOfHolding') ) e.Replacement = 'UTBackpack'; + else if ( (e.Replacee == 'ArmorBonus') || (e.Replacee == 'ArtiTimeBomb') ) e.Replacement = 'UTArmorBonus'; + else if ( (e.Replacee == 'HealthBonus') || (e.Replacee == 'CrystalVial') ) e.Replacement = 'UTHealthBonus'; + else if ( (e.Replacee == 'GreenArmor') || (e.Replacee == 'Silvershield') ) e.Replacement = 'UTThighPads'; + else if ( (e.Replacee == 'BlueArmor') || (e.Replacee == 'EnchantedShield') ) e.Replacement = 'UTBodyArmor'; else if ( e.Replacee == 'Stimpack' ) e.Replacement = 'UTMedBox'; else if ( e.Replacee == 'Medikit' ) e.Replacement = 'UTHealthBox'; + else if ( e.Replacee == 'ArtiHealth' ) + { + if ( !Random[Replacements](0,3) ) e.Replacement = 'UTHealthBox'; + else e.Replacement = 'UTMedBox'; + } + else if ( e.Replacee == 'ArtiTeleport' ) + { + // I have no idea what to replace this with, so just have some random stuff + if ( Random[Replacements](0,1) ) e.Replacement = 'UTBackpack'; + else if ( Random[Replacements](0,1) ) e.Replacement = 'UTShieldBelt'; + else if ( Random[Replacements](0,1) ) e.Replacement = 'UTHealthPack'; + else e.Replacement = 'UDamage'; + } else if ( e.Replacee == 'RedCard' ) e.Replacement = 'UTRedKey'; else if ( e.Replacee == 'BlueCard' ) e.Replacement = 'UTBlueKey'; else if ( e.Replacee == 'YellowCard' ) e.Replacement = 'UTGoldKey'; @@ -1512,6 +1535,9 @@ Class UTMainHandler : StaticEventHandler else if ( e.Replacee == 'TeleportFog' ) e.Replacement = 'UTTeleportFog'; else if ( e.Replacee == 'ItemFog' ) e.Replacement = 'UTItemFog'; else if ( flak_blood && (e.Replacee == 'Blood') ) e.Replacement = 'UTBlood'; + else if ( e.Replacee == 'KeyYellow' ) e.Replacement = 'UTHereticYellowKey'; + else if ( e.Replacee == 'KeyGreen' ) e.Replacement = 'UTHereticGreenKey'; + else if ( e.Replacee == 'KeyBlue' ) e.Replacement = 'UTHereticBlueKey'; } private Actor AddLight( Vector3 pos, Color col, int radius ) @@ -1635,6 +1661,101 @@ Class UTMainHandler : StaticEventHandler AddAmbient((3584,736,64),"testamb/slime",0.4,2.4); AddAmbient((3584,512,64),"testamb/lava",0.8,2.4); } + else if ( level.GetChecksum() ~== "D8206A3414DA967F2159473B5791139E" ) + { + TextureID deftex = TexMan.CheckForTexture("-noflat-",TexMan.Type_Any); + TextureID skytx = TexMan.CheckForTexture("BlueSky",TexMan.Type_Any); + TextureID baseflor = TexMan.CheckForTexture("rClfFlr0",TexMan.Type_Any); + TextureID baseceil = TexMan.CheckForTexture("rClfBas0",TexMan.Type_Any); + TextureID basewall = TexMan.CheckForTexture("uAlnWl2b",TexMan.Type_Any); + TextureID xbasewall = TexMan.CheckForTexture("xAlnWl2b",TexMan.Type_Any); + TextureID glasstex = TexMan.CheckForTexture("Glassg",TexMan.Type_Any); + level.ChangeSky(skytx,skytx); + for ( int i=0; i