Generator Destruction (a variation) Prefab V9 Feedback Round Fix

Custom game mode. Kinda like Gang Garrison 2!

  1. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    Generator Destruction (a variation) Prefab - Custom game mode. Kinda like Gang Garrison 2!

    NOTE: This is still a Work-In-Progress. Will keep this updated until I'm done working on it.

    Generator Destruction is a custom game mode for TF2. Due to not being officially supported by Valve, this is one of the variations of this game mode. (one of which is called Generator Defense, or probably the same name as this one...) To keep it simple, the map prefix is just "gd_".

    What is the goal in your take of Generator Destruction?
    • Each team has a generator the other team needs to destroy.
    • At the beginning of the round, both generators have uber and Wrangler shield.
    • To drop the uber and/or shield, each team must destroy the other team's shield batteries. Destroying these batteries reduces the shield's power.
    • There are two shield batteries on each team. They are weak but repairable by Engineers.
    • Destroy the batteries, destroy the generator, win the game.
    About the Generator itself
    • The generator is a Dispenser. It is classified as a building: However it does not heal, give metal, and cannot be upgraded nor repaired.
    About the Shield Batteries
    • Unlike other variations of this game mode, this one has something called a shield battery.
    • As of 3 July 2021, the shield batteries look like Repair Nodes (scrapped Engineer building)
    • Each battery destroyed reduces the shield's power. First battery removes Uber, second battery removes Wrangler shield.

    Gameplay Theory
    • Players have to decide whether to go destroy the batteries first to weaken the shield, or to make a direct attack on the generator.
    • Players are rewarded for destroying the batteries quickly, because each battery resets the time it takes to reboot the shield's power.

    Map-Design Theory
    • idk

    Special Thanks @MegapiemanPHD , Da Spud Lord , Pdan , Mr. Burguers , and sonoma for helping me with this.
    Credit Benjamoose and Murphy for Repair Node textures.
     
    Last edited: Jul 4, 2021
  2. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    General Notes about V6
    • Both generators gain 400 HP per player on the server. (no cap)
    • Similarly, the generator's shield batteries gain 30 HP per player on the server, capped at 600 HP
    • Shield Batteries respawn the same way Robot Destruction robots spawn. Default in prefab is:
      • 1 battery destroyed = 60 seconds
      • 2 battery destroyed = 120 seconds
    • In V5 and below, Generators could sapped and destroyed prematurely with the Red-Tape Recorder. This was fixed in V6 (fix was just removing sappers immediately upon being placed).
    • Voicelines were added in V6 for when the generator is being attacked.
    Damage Reduction Logic
    • Damage reduction calculations are actually just adding back the health via percentage.
    Custom Assets Included
    • Repair Node model + textures (credit Benjamoose + Murphy for textures)
    • Uber Dispenser
    • HUD icons
      • Uber
      • Shield Dispenser
      • Dispenser
    • Spliced TF2 Announcer lines
      • "You must destroy the enemy's reactor!"
      • "Destroy the enemy's reactor core!"
    • .res HUD file
    • Sound script file (for removing intel capture lines on classes, removing all RD sounds, adding new announcer lines)
    • Custom MOTD / "whiteboard" description for GD
    Intel/Flag Notes
    • The points added at the start of the round are actually from a Robot Destruction intel spawned by a point_template, then send RoundActivate. This workaround for Source reasons doesn't consider the game having zero points on either team, because if there are no points the intels don't spawn in RD. However because it's spawns via template, it exists permanently, and RoundActivate collects the points automatically. (credit Mr. Burguers for the find)
    • You can also subtract points by setting an RD intel with negative points to subtract on pickup.
      • This does not work using RoundActivate.
    • You can subtract all points on the scoreboard for a team by setting the value to 4294967295 or higher. Use Google for more info why.
      • This method does work with RoundActivate.
    • func_respawnroom prevents capturing the intel, resulting in the workaround to remove points from the HUD a little difficult. The work-around for this is the logic constantly searches for a player inside the map-wide trigger until it is captured. If it fails to find a player, the intel deletes itself and respawns in a loop until it finds a player to capture it.
    Other
    • Robot Destruction entities work in Player Destruction, including the Robots, including the intelligences. (although not 100%, see below)
      • Due to the intel being set to RD in a PD game mode, the capture HUD notifications are actually disabled and don't give any notification.
    • math_counter has a input to GetValue and OutValue. It seems like GetValue processes after OutValue if done with the same delay. It's used a lot in this logic.
     
    Last edited: Jul 4, 2021
  3. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V2
    • Added sound script to replace robot / announcer sounds
    • Re-organized the logic. Split into two sides--One for stuff the player interacts with, and the other side stuff that needs to be out-of-bounds.
    • Fixed broken damage reduction refires.
    • Updated shield effects to FireUser.

    Read the rest of this update entry...
     
    Last edited: Jul 4, 2021
  4. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
  5. True lemon

    True lemon L3: Member

    Messages:
    127
    Positive Ratings:
    23
    Good to know it's a variation since I was looking at this on the discord and felt it changed the gameplay enough to not be a replacement of the original. Granted, it's most likely a whole ton better in the logic department though.
     
    • Thanks Thanks x 1
  6. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    I'm glad you think it's appropriate too. I think this is one of those modes that won't ever have a standard way to implement it, and instead always going in a direction of experimentation.

    I'm proud of this logic. And I hope it works well for people who might use it.
     
  7. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V3
    • Logic Updated
      • Damage Reduction logic tightened to calculate precisely the time of damage occurs. That means no lag or hiccups where the generator heals erroneously. It's flawless! Woooooo!
      • HUD counter logic tuned to be even more accurate, and less laggy.
        • The score only updates when someone picks up a flag to reduce the score. These flags spawn when the score needs to be updated, but this update lags the game if updated too fast.
        • To change the update speed, change the map-wide trigger's Delay Before Retrigger parameter to something over 1 second. (default in my prefab is 1.1) Anything faster will probably cause stuttering in the server.

    Read the rest of this update entry...
     
  8. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V4
    • Fixed file directory not actually having a 'custom' folder in it! doh
    • Added effects for the shield batteries.
    • Fixed bug where vgui_screen would resize on all dispensers.
    • Added scaling health for shield batteries (+50 per player, cap 1200)
    • Fixed bug where shield batteries couldn't spawn. (due to env_entity_maker not spawning the template in brushes)
    • Added new assets
      • Uber Dispenser
      • "Generator" sign (it's kind of WIP)
      • "Uber" HUD icon

    Read the rest of this update entry...
     
  9. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V5
    • The vgui_screen panel on the generator now disappear when ubered.
    • Added a fix for the HUD not deducting points when a player is in the respawn room.
    • Updated the files
      • Added a GD description for the whiteboard in the beginning of the map
      • Updated the level sounds to remove the intel-capture lines for all classes.
    • Updated readme
    For those updating from V4 to V5
    • Copy and replace all the logic side of the prefab.
    • Copy the BLU generator (just the BLU one!) from this prefab and replace it with the one in your map.
    • Place the condition triggers in the respawn rooms.
      • You can make a new brush entity called "trigger_add_tf_player_condition" with condition 65, set to -1 duration.
    • Re-place all the map-wide triggers with the new ones in the prefab.
    That's all for now. Have fun!

    Read the rest of this update entry...
     
    Last edited: Jul 2, 2021
  10. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V6
    Map with V4 (gd_texas_a1c: https://feedback.tf2maps.net/map/gd_texas_a1c/)

    Shield Batteries
    • Dropped count from 3 -> 2
    • Now uses Repair Node model
    • Reduced health from 50 per player to 30 per player (cap 600)
    • Buildings now permanently disabled (can't heal etc)

    Generator
    • Reduced health from 500 per player to 400 per player
    • (Bug Fix) Sappers are now removed immediately on placement. (Red-Tape broke the map)
    • (Bug Fix) Sappers don't re-enable buildings
    • Generator now only ubered, gains 66% damage resistance, then completely vulnerable.
    Added new announcer voicelines
    • "You must destroy the enemy's reactor!"
    • "Destroy the enemy's reactor core!"

    Added new assets

    Read the rest of this update entry...
     
  11. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
  12. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    ok so the sappers still crash the game. And Red-Tape still is evil and changes the max HP of the building. Working on a fix as I speak.
     
    • Thanks Thanks x 1
  13. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V7
    • (while throwing salt over my shoulder superstitiously) Squashed evil bugs with Sappers...
      • Fixed Red-Tape Recorder resetting health of Generator. (known bug: Does change health of batteries. Could potentially fix that later but it's a non-issue)
      • Fixed both sappers from crashing the game.
      • Thanks Da Spud Lord for helping me with figuring out a workable solution for this.
    • Updated HUD icon for shielded Dispenser and base Dispenser
    • (undocumented in V6) reduced HUD update for map-wide triggers from Retrigger rate 1.1 to 0.01

    Read the rest of this update entry...
     
  14. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V8
    • Added explosion effect on generator destruction.
    • Increased cooldown of /Protect your reactor/ line from 5s to 12s.
    • All generators/shield batteries now heal 5HP/sec
    • Shield batteries leave a blueprint on destruction.
    • Added new voicelines for when both batteries are destroyed.
    • Added sounds when the generator's health changes on the HUD.
    • Fixed seeing robots outside the map w/ cond 114.
    • Reduced generator HP increments from 400 to 300.
    • Updated custom assets, folders and readme.
    • Fixed visgroups not filtering some entities in prefab.

    Read the rest of this update entry...
     
  15. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    V9
    • Fixed crash in server bootup I/O by placing the damage reduction logic into a point_template.
      • This ties in with the Red-Tape Recorder sapper fix. I had to make the building have a high enough level to make the Red-Tape not reduce the logic-modified health of the building...
    • Updated sappers to deal 30 damage per placement (up from 10).

    VERSION NOTE: This'll be the last version that has the gameplay elements of having the generator be invincible until the nodes are destroyed. More on that coming soon.

    Read the rest of this update entry...
     
  16. Yaki

    Yaki L6: Sharp Member

    Messages:
    306
    Positive Ratings:
    144
    Sorry gang! So apparently I didn't fix the feedback round crash. THIS VERSION MIGHT FIX IT--It's a small func_door that, when sent Open, kills most of the GD entities.

    You can find the door right above the logic_auto on the right-hand side of the map!

    Read the rest of this update entry...