How would I go about making a custom perk machine that removes the delay (Melee's are as fast as you can hit MMB). I have little to no experience with making custom perk machines and resources about how to edit any sort of melee mechanics are limited. Any help?
Which means the only way possible would be to have alt weapons for each weapon where the knife was quicker, have each player switch to it when they have the perk, hide the alt weapon icon in menu, script gsc to check that the player doesn't have the alt weapon when they shouldn't, and then come up with an alternative pap method (play fx instead, or use alt models and check a player var for it), since all your weapon files will be used up, all after you edit the perk script for you custom perk machine. It would be a good deal of work, if it was even not buggy enough to be use-sable.
Last Edit: July 26, 2016, 04:36:50 am by MakeCents
If you want scripts / features made for you, then contact me by PM or email / skype etc it will cost you tho so if you have no intention of reciprocating don't even waste my time
Which means the only way possible would be to have alt weapons for each weapon where the knife was quicker, have each player switch to it when they have the perk, hide the alt weapon icon in menu, script gsc to check that the player doesn't have the alt weapon when they shouldn't, and then come up with an alternative pap method (play fx instead, or use alt models and check a player var for it), since all your weapon files will be used up, all after you edit the perk script for you custom perk machine. It would be a good deal of work, if it was even not buggy enough to be use-sable.
Why hide alt icon and do all that other script check to make sure your not switched to it? All you gotta do to prevent switching to alt weapons when you don't want the player to, and then hide the HUD is this:
Code Snippet
Plaintext
player SetActionSlot( 3, "" );
then when you need to go back to being able to switch to alt weapons, this:
Code Snippet
Plaintext
player SetActionSlot( 3, "altmode" );
Besides, alt weapons wouldn't really work out for this anyways. Just use a new set of weapon files that aren't alt weapons to the original one. But I can tell you doing all that for such a small little feature of a perk really isn't worth it.
Why hide alt icon and do all that other script check to make sure your not switched to it? All you gotta do to prevent switching to alt weapons when you don't want the player to, and then hide the HUD is this:
Code Snippet
Plaintext
player SetActionSlot( 3, "" );
then when you need to go back to being able to switch to alt weapons, this:
Code Snippet
Plaintext
player SetActionSlot( 3, "altmode" );
Besides, alt weapons wouldn't really work out for this anyways. Just use a new set of weapon files that aren't alt weapons to the original one. But I can tell you doing all that for such a small little feature of a perk really isn't worth it.
I've done it at least two different ways. It works, and I've seen the bugs that arise in both situations. I'm sure there are other ways, with there own set of bugs. The reason I chose alt weapons is so you can switch to the other weapon and back without an animation, so no one will ever know, and it could even be made into a powerup instead.
Edit: A third method I haven't tried is the forceviewmodelanim method, and making the fire anim of this other weapon fire the melee anim instead. That prob is really glitchy, if it would even work. If it does, then with some stat adjustments I guess you could do it with just one weapon file then and not need any of the other checks...?
Last Edit: August 02, 2016, 12:17:30 pm by MakeCents