- Joined
- Apr 13, 2020
- Messages
- 479
- Thread Author
- #1
This isn't as much a suggestion as it is an open-ended discussion. Some of you know that this week I have begun the work on the process of developing a weapon base (mostly) from scratch for Willard to use. ArcCW and TFA's many flaws are well known to us all. However, they are completely opaque systems with little flexibility. As such, it is finally time we make our own base and leave them both behind.
Do you all have any big requests or considerations when it comes to this new weapon system? If you do, then speak now or forever hold your peace. All that I ask is that you read the Q&A section prior to leaving any feedback.
This thing will probably take a few weeks to complete, then a bit longer after to integrate into IXHL2RP. It won't release this week, or next week, or the week after. But, I'd like to open this up for you all to provide feedback early on so that we can look into addressing it with this new system prior to any sort of major work being completed.
Why do this?
It must be FAST and it must have better hit registration. Without going into too much detail, I have realized why ArcCW's hit registration feels so bad on Willard, and it's due to some really questionable and expensive custom hit detection code that, at 20tps, just does not work well. I'm certain it works great in singleplayer, or on 66tps darkrp servers, but it does not work for us. What we need is a truly simple and fast solution, with as little code as possible in between the client clicking M1 and the server detecting a hit or not.
In the same vein, there is a lot of other redundant or completely unnecessary code which runs taking up CPU time on the server between ticks. Both ArcCW and TFA have these issues. We should get much more server stability and performance when we remove both addons.
At the same time, I have written a lot of code which should make it quite easy for a developer to use a model designed for another base within this one. This is a good thing, it means we should be able to port in really any SWEP on the workshop. I have a lot of custom animation override code that allows someone to easily dictate how a weapon should animate when it raises, shoots, fires, reloads, etc. That's usually the main pain point.
It also grants us a lot of flexibility. We can use it to consolidate a number of different SWEPs we already have in IXHL2RP (vort sweps, stunstick melee, etc) under one umbrella, so they all use the same set of UI features and act in the same predictable manner. At the same time, due to it's flexible nature, we can use it to add even non-guns: think fire extinguishers, spore cleanup equipment, binoculars, etc.
We can then fold in and rework a bunch of override code to make it all centralized to this base. Think audio, damage balancing, stamina based sway, gun level based recoil, etc.
What about attachments?
Unless someone else does this concurrently, I highly doubt we'll do attachments. They're so incredibly specific to a certain base that they're really a lot less flexible than you'd think they are. I do know that we will do them at some point. This does not means that the weapons themselves will be without accessories, instead they will just come prepackaged with them. Aka: A sniper could come with a 4x-12x scope, and a suppressed pistol will come with a suppressor, and so on. Flashlights are sort of pointless, given that you already have one in your inventory.
What does it look like?
This is still a bit up in the air. I do have some prototypes though.
I wrote a flexible picture-in-picture optics system to use for this base. This is how that work:
Given that it's procedural, I could do some interesting things with it. For example, for Civil Protection, I can integrate the new UI in such a way so that names could appear above heads within the optic. Or maybe if they're BOL the optic paints a red skull above their head or something. It's all totally customizable to that end.
For ADS weapons, it works as you might expect them to. I have code that allows you to aim down the sights of really anything, its pretty customizable. Below is a demonstration of that, as well as what I'm thinking about when it comes to how the crosshair will look.
How will damage / bullets / magazines work?
Well, let me roll all this into one answer. Just as before, you will need to put bullets into magazines if it is a weapon which requires a magazine. This will no longer be a requirement for shotguns, revolvers, etc. For those guns it will pick them up out of their inventory as per whatever the player sets as priority. I plan to implement some sort of system, similar to zomboid, where you will need to pack bullets into a mag one at a time. You can do multiple but each bullet takes a half second or so to load, and as you level up your guns, it will load faster. Gone are the days of being able to just have 2 mags and instantly pack infinite bullets into one of them.
We can also do away with a number of the bugs the magazine code has, as it will no longer depend on setting this ephemeral Clip1/Clip2 variable on the player so that the gun can shoot. The weapons will look directly into your inventory, skipping all of the underlying code branches that can sometimes grant ammo which never existed or delete ammo from your inventory for no reason. It'll also actually show how much ammo you have in reserve on the UI (see the earlier demos, as they were correctly showing primary / reserve ammo)
Now this will serve a purpose which isn't entirely just realism or necessity. In the second demo, you could see the pistol was loaded with 9mm +P. That is because I plan to have a magazine type accept a caliber, and that caliber can have many different subtypes, which all have different pros & cons. There will be a menu you can use to load let's say 20 rounds of standard 9mm into a mag, then put 10 rounds of +P in the top. The system will then shoot those 10 loaded at the top first, then it'll use the remaining 20 standard rounds from the magazine, preserving the order they were loaded in.
In this base, guns will shoot a caliber. That caliber will determine that gun's range, damage, and armor penetration values. The entity can define some multipliers to increase or decrease those values, as a 9MM SMG should do more damage than a 9MM Pistol, but it still works based on the caliber regardless. There will be lots of different ammo types for each caliber that the player can choose from depending on the situation. It'll be trivially to add more subtypes in the future, say if we want to add dragon breath 12ga.
When it comes to shotguns & revolvers, there will have to be some way to set priority. Aka, if I mark buckshot & slug both as priority 1, it will load 1/2 slug 1/2 buckshot. Then if I run out of slug, it'll load all buckshot, then when I run out of that it'll load whatever else. It'll just pull them off of the stacks in your inventory, no need for magazine items.
Refunds???
I don't know yet. It's too early to talk about that. We probably won't have nearly as many weapons to start in this base. I'm thinking a few pistols, a couple SMGs, a couple shotguns, and a rifle or two, plus some guns for OTA.
It must be FAST and it must have better hit registration. Without going into too much detail, I have realized why ArcCW's hit registration feels so bad on Willard, and it's due to some really questionable and expensive custom hit detection code that, at 20tps, just does not work well. I'm certain it works great in singleplayer, or on 66tps darkrp servers, but it does not work for us. What we need is a truly simple and fast solution, with as little code as possible in between the client clicking M1 and the server detecting a hit or not.
In the same vein, there is a lot of other redundant or completely unnecessary code which runs taking up CPU time on the server between ticks. Both ArcCW and TFA have these issues. We should get much more server stability and performance when we remove both addons.
At the same time, I have written a lot of code which should make it quite easy for a developer to use a model designed for another base within this one. This is a good thing, it means we should be able to port in really any SWEP on the workshop. I have a lot of custom animation override code that allows someone to easily dictate how a weapon should animate when it raises, shoots, fires, reloads, etc. That's usually the main pain point.
It also grants us a lot of flexibility. We can use it to consolidate a number of different SWEPs we already have in IXHL2RP (vort sweps, stunstick melee, etc) under one umbrella, so they all use the same set of UI features and act in the same predictable manner. At the same time, due to it's flexible nature, we can use it to add even non-guns: think fire extinguishers, spore cleanup equipment, binoculars, etc.
We can then fold in and rework a bunch of override code to make it all centralized to this base. Think audio, damage balancing, stamina based sway, gun level based recoil, etc.
What about attachments?
Unless someone else does this concurrently, I highly doubt we'll do attachments. They're so incredibly specific to a certain base that they're really a lot less flexible than you'd think they are. I do know that we will do them at some point. This does not means that the weapons themselves will be without accessories, instead they will just come prepackaged with them. Aka: A sniper could come with a 4x-12x scope, and a suppressed pistol will come with a suppressor, and so on. Flashlights are sort of pointless, given that you already have one in your inventory.
What does it look like?
This is still a bit up in the air. I do have some prototypes though.
I wrote a flexible picture-in-picture optics system to use for this base. This is how that work:
Given that it's procedural, I could do some interesting things with it. For example, for Civil Protection, I can integrate the new UI in such a way so that names could appear above heads within the optic. Or maybe if they're BOL the optic paints a red skull above their head or something. It's all totally customizable to that end.
For ADS weapons, it works as you might expect them to. I have code that allows you to aim down the sights of really anything, its pretty customizable. Below is a demonstration of that, as well as what I'm thinking about when it comes to how the crosshair will look.
How will damage / bullets / magazines work?
Well, let me roll all this into one answer. Just as before, you will need to put bullets into magazines if it is a weapon which requires a magazine. This will no longer be a requirement for shotguns, revolvers, etc. For those guns it will pick them up out of their inventory as per whatever the player sets as priority. I plan to implement some sort of system, similar to zomboid, where you will need to pack bullets into a mag one at a time. You can do multiple but each bullet takes a half second or so to load, and as you level up your guns, it will load faster. Gone are the days of being able to just have 2 mags and instantly pack infinite bullets into one of them.
We can also do away with a number of the bugs the magazine code has, as it will no longer depend on setting this ephemeral Clip1/Clip2 variable on the player so that the gun can shoot. The weapons will look directly into your inventory, skipping all of the underlying code branches that can sometimes grant ammo which never existed or delete ammo from your inventory for no reason. It'll also actually show how much ammo you have in reserve on the UI (see the earlier demos, as they were correctly showing primary / reserve ammo)
Now this will serve a purpose which isn't entirely just realism or necessity. In the second demo, you could see the pistol was loaded with 9mm +P. That is because I plan to have a magazine type accept a caliber, and that caliber can have many different subtypes, which all have different pros & cons. There will be a menu you can use to load let's say 20 rounds of standard 9mm into a mag, then put 10 rounds of +P in the top. The system will then shoot those 10 loaded at the top first, then it'll use the remaining 20 standard rounds from the magazine, preserving the order they were loaded in.
In this base, guns will shoot a caliber. That caliber will determine that gun's range, damage, and armor penetration values. The entity can define some multipliers to increase or decrease those values, as a 9MM SMG should do more damage than a 9MM Pistol, but it still works based on the caliber regardless. There will be lots of different ammo types for each caliber that the player can choose from depending on the situation. It'll be trivially to add more subtypes in the future, say if we want to add dragon breath 12ga.
When it comes to shotguns & revolvers, there will have to be some way to set priority. Aka, if I mark buckshot & slug both as priority 1, it will load 1/2 slug 1/2 buckshot. Then if I run out of slug, it'll load all buckshot, then when I run out of that it'll load whatever else. It'll just pull them off of the stacks in your inventory, no need for magazine items.
Refunds???
I don't know yet. It's too early to talk about that. We probably won't have nearly as many weapons to start in this base. I'm thinking a few pistols, a couple SMGs, a couple shotguns, and a rifle or two, plus some guns for OTA.
Do you all have any big requests or considerations when it comes to this new weapon system? If you do, then speak now or forever hold your peace. All that I ask is that you read the Q&A section prior to leaving any feedback.
This thing will probably take a few weeks to complete, then a bit longer after to integrate into IXHL2RP. It won't release this week, or next week, or the week after. But, I'd like to open this up for you all to provide feedback early on so that we can look into addressing it with this new system prior to any sort of major work being completed.