2 Screenshots

About This File

Short story: Repeating blasters were originally intended to give the user an additional attack in every round of combat (like twin-blade melee weapons do). This mod implements that effect. I.e. a character without force speed would normally do 1 attack when using a repeater, 2 when using rapid shot as well. Now, 2 attacks will be done when using the default attack and 3 when using rapid shot.

Long story: After investigating in 2015 what could be the reason for repeaters costing more (500 vs 300) credits while having a worse crit range (5% vs 10%) than blaster rifles while having no advantage whatsoever, I found out that repeaters were originally intended to give the user an additional attack per round, sort of making them the double-blades of the blasters. Sadly, this was never implemented, as one internal item comment even comments on. I didn't know enough about scripting back then and quickly lost interest in fixing this. But now, more than 3 years later, it's finally fixed via scripting, placing the required code in the k_ai_master script.

Known issues: Due to hardcoded mechanics, power blast can never do more than 1 attack, and sniper shot never more than 2. Normal attack appears to usually only do 2, but may rarely do 3 when using force speed as well. Sadly, these cannot be changed without access to the game code. This information turned out to be incorrect, and the user Darg727 made a fix for this. However, this has a downside: It works by making power blast and sniper shot always shoot 4 shots regardless of how many attacks are available, which looks very strange because all shots that don't have a corresponding attack round are auto-misses. For example, using a sniper shot with a blaster rifle or single pistol will cause 4 shots to be fired simultaneously, like a shotgun blast, with 3 of the 4 automatically hitting the floor/ceiling/wall. Using knight speed would allow 2 of those 4 to hit and only 2 would be an auto-miss, etc.... As per Darg727's upload permissions, I have included the responsible file (weapondischarge.2da) as an optional mod in the download for additional visibility for those people that might want to use the feature but would not come across his modification otherwise.

Compatible with any mod that does not edit the k_ai_master.ncs file, and incompatible with any that does. (However, it is easy for any modder to add the compatibility, source is included.)

Note that this fix works for both the player and enemies! This can make some fights of the game slightly more challenging.


What's New in Version 2.0   See changelog

Released

Complete rewrite in order to fix the bug where party members could get locked out from receiving the bonus, it should now reliably work under any circumstances.

Fixed knight/master speed and this overwriting another's extra attacks. (Though note that extra attacks from scripts seem to be capped at +2, so sadly there is still a lost attack when combining repeaters with master speed.)

Debug ncs file added to make checking for functionality easier in case any issues pop up again (they really should not).

  • Like 11
  • Thanks 2
  • Light Side Points 2



User Feedback

Recommended Comments



6 hours ago, smugglerAlex said:

Awesome, works with TSL?

This particular version, no. But I could make one for TSL if you want. (Even though I think that that game is balanced around the idea of repeaters only having 1 attack per round when you look at their damage values.)

Share this comment


Link to comment
Share on other sites
6 hours ago, A Future Pilot said:

Could I please have permission to include this mod in the K1 Community Patch?

Thanks!

I don't really feel comfortable with it at this point. Quite some thought went into this (nobody else bothered to fix it in more than a decade) and I don't really want it to be reduced to a random entry on some list. 😕

  • Like 1
  • Sad 1

Share this comment


Link to comment
Share on other sites
On 12/8/2018 at 2:04 AM, smugglerAlex said:

Awesome, works with TSL?

If the mod author decides to make one, it will conflict with Improved AI mod (which also recompiles k_ai_master), although it should be easy enough to add a compatibility version for that.

Share this comment


Link to comment
Share on other sites
On 12/8/2018 at 5:19 AM, R2-X2 said:

This particular version, no. But I could make one for TSL if you want. (Even though I think that that game is balanced around the idea of repeaters only having 1 attack per round when you look at their damage values.)

I at least would be interested in a TSL version, if you are still interested in doing so.

Share this comment


Link to comment
Share on other sites

Thanks to a poster on another site I found out that you updated to include my edited 2da file. Because the visual disparity was mentioned I want to bring to light some further information I have in case someone would like it. The shots column determines the number of projectiles discharged per round (determines maximum number of hits to be rolled) and the hits column determines the maximum that can visually hit when you hit with an attack (set to 4 means that if you hit 4 times the projectiles will hit the target 4 times or if set to 2 and you hit 4 times the target only gets hit by 2). Tl;dr change the hit column to match the shots column to make it possible for all shots to visually hit the target when you actually do.

Only the triple digit rows affect the player and other playable characters.

I'll be updating my file on the other site.

Edited by Darg727

Share this comment


Link to comment
Share on other sites

I've been trying this with Mission but it appears that the mechanisms involved in making the extra attacks happen do not reliably persist across loading saves, loading screens, and/or leveling screens.

I haven't had any issues with Carth, Zaalbar, or the PC but I also haven't given them as much attention because they didn't need coaxing to work the first time.

Edited by Neros

Share this comment


Link to comment
Share on other sites
7 hours ago, Neros said:

I've been trying this with Mission but it appears that the mechanisms involved in making the extra attacks happen do not reliably persist across loading saves, loading screens, and/or leveling screens.

I haven't had any issues with Carth, Zaalbar, or the PC but I also haven't given them as much attention because they didn't need coaxing to work the first time.

Are you using the extra attacks for rifles? I think they themselves have some issues. I don't think the repeaters themselves do, though.

Share this comment


Link to comment
Share on other sites
48 minutes ago, StellarExile said:

Are you using the extra attacks for rifles? I think they themselves have some issues. I don't think the repeaters themselves do, though.

Using the repeater version.  I have a save where it does seem to work reliably on Mission but I seem to be able to break it by cycling her out of and back into the party or zone transition.

Share this comment


Link to comment
Share on other sites
10 hours ago, Neros said:

I've been trying this with Mission but it appears that the mechanisms involved in making the extra attacks happen do not reliably persist across loading saves, loading screens, and/or leveling screens.

I haven't had any issues with Carth, Zaalbar, or the PC but I also haven't given them as much attention because they didn't need coaxing to work the first time.

Hey there, the extra attacks don't really persist at all, and instead get re-applied every second or less as a temporary 1 second buff (that won't stack, if applied faster), to make sure the attacks count reacts quickly to weapon changes without being too computing-intensive. It's possible to break when starting to attack with a repeater and switching it to a different weapon and immediately attacking afterwards, that the next attack round can still receive the additional attack (or vice versa, missing the additional attack if attacking instantly after a switch, before the buff can be applied), but at the next time you attack, it should always be fine.

What are the exact circumstances you had with Mission? You can PM me a save where it doesn't work, maybe I'll find time to take a look.

3 hours ago, StellarExile said:

Are you using the extra attacks for rifles? I think they themselves have some issues. I don't think the repeaters themselves do, though.

Can you tell me more about these issues? I quickly wrote the blaster rifle including file as per a user's request, but wouldn't have thought there to be any differences to the repeater handling.

 

On 6/10/2020 at 6:42 AM, Darg727 said:

Thanks to a poster on another site I found out that you updated to include my edited 2da file. Because the visual disparity was mentioned I want to bring to light some further information I have in case someone would like it. The shots column determines the number of projectiles discharged per round (determines maximum number of hits to be rolled) and the hits column determines the maximum that can visually hit when you hit with an attack (set to 4 means that if you hit 4 times the projectiles will hit the target 4 times or if set to 2 and you hit 4 times the target only gets hit by 2). Tl;dr change the hit column to match the shots column to make it possible for all shots to visually hit the target when you actually do.

Only the triple digit rows affect the player and other playable characters.

I'll be updating my file on the other site.

I'll send you a PM.

Share this comment


Link to comment
Share on other sites
5 hours ago, Neros said:

Using the repeater version.  I have a save where it does seem to work reliably on Mission but I seem to be able to break it by cycling her out of and back into the party or zone transition.

That's strange. I don't think that should be happening as long as you're not using conflicting mods. Did you install it to a save where it didn't have the mod before?

4 hours ago, R2-X2 said:

Can you tell me more about these issues? I quickly wrote the blaster rifle including file as per a user's request, but wouldn't have thought there to be any differences to the repeater handling.

Ah, I was referring to the property where it fires 4 shots and only 1 hits because that's the limitation. No other issues I can think of, though :D.

Share this comment


Link to comment
Share on other sites
10 hours ago, StellarExile said:

That's strange. I don't think that should be happening as long as you're not using conflicting mods. Did you install it to a save where it didn't have the mod before? [snip]

That seems to be unrelated. I started a new game, cheated in a LRB, gave it to Trask, and dropped a save before first combat: Trask gets his extra attacks.
Loaded that save: Trask does not get extra attacks.

Share this comment


Link to comment
Share on other sites
10 hours ago, Neros said:

That seems to be unrelated. I started a new game, cheated in a LRB, gave it to Trask, and dropped a save before first combat: Trask gets his extra attacks.
Loaded that save: Trask does not get extra attacks.

Hmmm... unless you're using other mods that conflict, I don't think that should be happening. Wonder what @R2-X2's thoughts are.

Share this comment


Link to comment
Share on other sites

Upon further investigation, I believe you might need to move both the ncs and nss scripts to your override even if the description says just to move one. I do remember asking jc2 about a similar matter for his Improved Grenades mod.

Share this comment


Link to comment
Share on other sites

Does this mod require any other mods to work or any other requirements that have to be met that are not mentioned in the READ ME or on here?  I have tried removing the equipment off of my characters and putting them back on, putting both the NCS and NSS files in the override folder, beginning a new game, putting all available NCS & NSS files in the folder, NOTHING.  I am running a bone dry Vanilla game and got curious as to why BR's were so shit and found this mod.  Without this mod, 2 of my favorite characters are basically useless (Candorus & HK-47).  Shame too as this was a really good idea.

PS.  IMO the regular BR's that are not repeating only need a base damage increase to be viable (2-12) and maybe a bit more critical chance (18-20 instead of 19-20).  

Share this comment


Link to comment
Share on other sites
On 12/11/2020 at 5:21 AM, Neros said:

That seems to be unrelated. I started a new game, cheated in a LRB, gave it to Trask, and dropped a save before first combat: Trask gets his extra attacks.
Loaded that save: Trask does not get extra attacks.

I did some recreational debugging, and I can confirm this is a problem for every party member except the PC.

The following is 100% repeatable.

Equip a repeater -> Preventative boolean gets set to TRUE, applies effect for 1 second -> Save -> Load -> Boolean is now permanently stuck as TRUE, effect has worn off, effect can never be applied again to that character.

Not sure why it works perfectly with the PC, but there's the error.

  • Like 2

Share this comment


Link to comment
Share on other sites

Ah damn it. Neros had sent me his save files, but I hadn't gotten to checking the issue.
Sounds like I screwed up something - will need to rethink the logic. It's probably something really basic... Weird how it's not bugged for the PC, that's probably how I didn't notice it in testing.

Edit: It makes total sense. The attacks script calls itself with a 1s delay, so saving and loading during that time will not have the script call persist to after the loading. I wonder where else this might break things... perhaps that's why speedruns use save-load spams to bypass scripted conversations and cutscenes.

It should be a relatively easy fix - putting in a "fail-safe" function to check if the boolean persists over more than one second and switch around the order of conditions and results a bit. If someone can remind me to look at it on Friday, that would be great, I am really forgetful at the moment...

  • Like 1
  • Light Side Points 1

Share this comment


Link to comment
Share on other sites

Sorry to add to the negative parade, but I discovered that this mod is overwriting the extra attacks from knight/master speed so the max extra attacks is only +1. The extra attack is also removed once the powers end. One needs to reactivate the powers or re-equip to get their extra attack back. After this it is still stuck at +1 attack even with master speed.

Share this comment


Link to comment
Share on other sites

I can't seem to find a way to reliably have the script run the way I intended it. Will probably make it a 6-second buff triggered by the OnHeartbeat function, which runs every 6 seconds, as far as I am aware. This would cause more latency when it comes to changing weapons, but that's probably something that can be endured. How often do people switch their weapons anyway...

As for not working together with force speed buffs, I have no idea what could cause this. I'm creating an entirely different effect that has one effect of the same type. Maybe there's something hardcoded in the game that prevents two sources to this effect from being active at the same time.

Share this comment


Link to comment
Share on other sites

so... as far as I've read in the comments, this mod doesn't work with companions (canderous hk-47 etc...) right?

any advance in a fix?

and is there any way to remove a companion's expired buff? in save editor maybe?

Edited by kallas_br

Share this comment


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.