Jump to content

Edit History

Please note that revisions older than 365 days are pruned and will no longer show here
JoeSloeMoe

JoeSloeMoe

On 3/18/2024 at 5:30 PM, Hells_Janitor said:

 

We had the same issue when running it on our server too. I have no idea why it works exactly like you said and is fine in single-player, but borks when in a multiplayer environment.

 

It's on my radar to look into - sorry I didn't have any better news.

 

Hey Hells_Janitor, this is a nice mod, thanks.

 

The way its described and a quick look at the code and am wondering if the multiplayer code might not be shutting the buff down for some reason (eg. interpreting the duration of '0.01' as '0' and leaving the buff running. 

From the docs (buffs.xml line 11492 - not sure how up to date it is), replace resets the timer it doesnt replace the entire buff. So <stack_type value="replace"/> might not be doing what its intended to do.  The GameEvent is called at onSelfBuffStart so it will only run once even if the timer is reset.

Wonder if something like following would change the way it behaves:

 

<stack_type value="ignore"/>
<duration value="0"/>
<effect_group>
    <triggered_effect trigger="onSelfBuffStart" action="CallGameEvent" event="modBrassCatcher"/>
</effect_group> 
<effect_group>
    <triggered_effect trigger="onSelfBuffUpdate" action="RemoveBuff" buff="buffReclaimBrass"/>
</effect_group> 

 

Edit: Just to add that from the above, some calls to the buffReclaimBrass will be ignored, eg with a machine gun - can cater for this by upping the percent chance for brass.

cheers

JoeSloeMoe

JoeSloeMoe

23 hours ago, Hells_Janitor said:

 

We had the same issue when running it on our server too. I have no idea why it works exactly like you said and is fine in single-player, but borks when in a multiplayer environment.

 

It's on my radar to look into - sorry I didn't have any better news.

 

Hey Hells_Janitor, this is a nice mod, thanks.

 

The way its described and a quick look at the code and am wondering if the multiplayer code might not be shutting the buff down for some reason (eg. interpreting the duration of '0.01' as '0' and leaving the buff running. 

From the docs (buffs.xml line 11492 - not sure how up to date it is), replace resets the timer it doesnt replace the entire buff. So <stack_type value="replace"/> might not be doing what its intended to do.  The GameEvent is called at onSelfBuffStart so it will only run once even if the timer is reset.

Wonder if something like following would change the way it behaves:

 

<stack_type value="ignore"/>
<duration value="0"/>
<effect_group>
    <triggered_effect trigger="onSelfBuffStart" action="CallGameEvent" event="modBrassCatcher"/>
</effect_group> 
<effect_group>
    <triggered_effect trigger="onSelfBuffUpdate" action="RemoveBuff" buff="buffReclaimBrass"/>
</effect_group> 

 

cheers

×
×
  • Create New...