tf2classic / tf2classic-feature-proposals

Have an idea for a new addition to the game? Post it here!
2 stars 0 forks source link

[Items_Game] Finer control over Weapon Internals (a-la Weapon Scripts) #9

Open SilentFox3 opened 2 years ago

SilentFox3 commented 2 years ago

This is a very broad topic, so I'll see if I can't shorten it down to a few basic things that'd be nice to see that shouldn't be too intensive for coders to wrangle. Apologies.

In TF2 / Open Fortress, a lot of weapons have a bunch of info stored in Weapon Script files that define very basic properties about them, including a few that can't be changed by items_game.txt attributes alone. As a result, for TF2C custom content, some things are still limited to what weapons are used as the base, and can't be changed without using another weapon instead.

It would be nice to see the features below, either as new Attributes or new properties changeable in a weapon's items_game.txt entry;

-"primary_ammo" - What ammo type the weapon uses
-"secondary_ammo" - Ammo type expended for secondary actions (like Airblast, Coilgun Charge, or maybe Revving)

-"BrassModel" - Custom shell-eject model; lets guns eject shells if not empty
-"MagazineModel" - Custom mag / clip model; lets guns eject clips if not empty
-"MuzzleFlashModel" - Beta Muzzleflash model to use, if not empty

-"Muzzle_Flash" - Muzzle Particle to use when firing, if not empty
-"Explosion_Effect" - Explosion Particle for any weapons that have it, or that fire projectiles that then explode
-"Trail_Effect" - Trail Particles that get glued to projectiles - I think this applies to most projectiles since almost all have trails!

-"Bucket" - What bucket-slot this weapon occupies in-game
-"BucketPosition" - What bucket-slot sub-position this weapon occupies. These two SHOULD mostly fix the item-slot issues for off-slot weapons, albeit in a bit odd way..!
-"DamageType" - Override for what "kind" of damage this weapon does + associated flags. Maybe copy bitflags from trigger_hurt entity for this? Obviously this would only affect some visual stuff - no spawned explosions or afterburn, just flags to the damage itself.
-TextureData Block - This is WAY out of the scope of this suggestions list, but defining Kill-Icons in the items_game.txt entries would save so much headache for everyone, even yourselves for weapon development.

I'm not asking for all of these by any means, but seeing at least a few crop up where convenient would be a lifesaver. Thanks for listening.