• Please make sure you are familiar with the forum rules. You can find them here: https://forums.tripwireinteractive.com/index.php?threads/forum-rules.2334636/

Code Mut: Per Server Stats

Could you tell us the error that is shown? Are you sure the database configuration is properly setup?

Of course, both servers can retrieve the perks

I think it has something to do with the connection timed out sort of thing.
And there is no error, the perks simply aren't being loaded for a period of time after map change...

Any way to keep the connection between the server and database constant?

I don't see a setting there that allows me to set the connection time to > 60 seconds or infinite

Oh i forgot about the error message

here it is: "This application has failed to start because the application configuration is incorrect"
 
Last edited:
Upvote 0
Some things that could be looked into:

Berserkers only have 25% damage resistance, not the newest-patch 40%.
Demolitions with LAW can only carry 13 rockets, not 22 (or whatever the percentrage is perked).
Speed boost for Medic displays as "r%" instead of some number.
Commando can see Stalkers past level 6 just fine, but not life bars.
Support seems to be stuck at +120% extra grenade capacity, but it's some perked percentage (For example, at level 30 it says +120%, but I can carry 35 grenades, which is +600%)

Also, I notice some perk benefits are "frozen" at level 6 and above. For example, a level 7+ Medic gets faster speed and better healing, but his armor bonus is only +75% and stays there. Commando gets faster reloads and less reloads, but no extra damage. I know there because of balance, but is there a way to fix that? Like a percentage increase over levels?
 
Upvote 0
Of course, both servers can retrieve the perks

I think it has something to do with the connection timed out sort of thing.
And there is no error, the perks simply aren't being loaded for a period of time after map change...

Any way to keep the connection between the server and database constant?

I don't see a setting there that allows me to set the connection time to > 60 seconds or infinite

Oh i forgot about the error message

here it is: "This application has failed to start because the application configuration is incorrect"
Sorry mate I can't exactly help myself but I know this may be helpful for others who may read this. I don't use a database due to it having some communication problems I think it was. I save all the data into it's own file so easily editable if needed to.
 
Upvote 0
Sorry mate I can't exactly help myself but I know this may be helpful for others who may read this. I don't use a database due to it having some communication problems I think it was. I save all the data into it's own file so easily editable if needed to.

But i want to share the same perks between both servers... If the database doesn't work, then the perks can't be shared... I hope Marco has a fix for this
 
Upvote 0
Hey,

When it will be possible to have ServerPerks Database On LINUX platform?
ore would it be eser to use MysqL Database for Perks ?

And how to make ServerPerksStats.ini convert to data.ini ?

I actually like the idea of this using a MySQL database but will this cause slight lag because of a constant connection from server to external database?
 
Upvote 0
Hi Marco,

I have been working on a lot of perks and weapons. I am using this mut for stats and perk selection. Everything is working great but one small detail. I would really like to fix it so i can release this mutator im working on.
When you first join and select a perk, it gives you the proper loadout of weapons. This is working on the 20+ perks and 50+ weapons im using. But when changing perks it never changes the weapon loadout. e.g.

Im berserker with Katana. I die or switch perks at the end of the round. When i spawn or switch to commando perk, i dont get the weapons for commando, i keep the weapons loadout from Berzerker.

How can i make it so the weapons loadout switches along with the perks? So when i switch from berzerker to commando, i get the weapons for commando instead of keeping the berzerker weapons? How does that function work? Where is this function?

Thanks in advance!
 
Last edited:
Upvote 0
Hi Marco,

I have been working on a lot of perks and weapons. I am using this mut for stats and perk selection. Everything is working great but one small detail. I would really like to fix it so i can release this mutator im working on.
When you first join and select a perk, it gives you the proper loadout of weapons. This is working on the 20+ perks and 50+ weapons im using. But when changing perks it never changes the weapon loadout. e.g.

Im berserker with Katana. I die or switch perks at the end of the round. When i spawn or switch to commando perk, i dont get the weapons for commando, i keep the weapons loadout from Berzerker.

How can i make it so the weapons loadout switches along with the perks? So when i switch from berzerker to commando, i get the weapons for commando instead of keeping the berzerker weapons? How does that function work? Where is this function?

Thanks in advance!

This is something I also get and I also found out you can NOT change perk during trader time at all. You have to of done it during the wave before which is a little annoying.

Anyway you could share how to fix these two?
 
  • Like
Reactions: Benjamin
Upvote 0
Hi Marco,

I now have it switching the weapons loadout when a player dies. That is fine.

The only thing now is selecting a perk during a wave or during trader time. I want them to get the new perks weapons loadout. Even if the way to make it happen is to kill them at the end of the wave and/or during trader time. So they respawn with the proper weapons.

If all else fails, will have to disable perk selection during waves and trader time. Which i dont want to do.

Any help would be greatly appreciated.
 
Last edited:
Upvote 0
Right what I want to do is change the Footer to not allow you to spectate once you've clicked ready but to UNREADY instead.

I've found inside SRLobbyFooter.uc
Code:
 else if(Sender == b_Ready)
 {
  if ( PC.Level.NetMode == NM_Standalone || !PC.PlayerReplicationInfo.bReadyToPlay )
  {
   //Set Ready
   PC.ServerRestartPlayer();
   PC.PlayerReplicationInfo.bReadyToPlay = True;
   if ( PC.Level.GRI.bMatchHasBegun )
    PC.ClientCloseMenu(true, false);
   b_Ready.Caption = UnreadyString;
  }
  else
  {
   // Spectate map while waiting for players to get ready
   LobbyMenu(PageOwner).bAllowClose = true;
   PC.ClientCloseMenu(true, false);
  }
 }

How would I change to unready instead (for the spectator bit and not replace the b_Ready section)? I know it will have
Code:
else if(Sender == b_UnReady)
I think. Any help?
 
Upvote 0
Just a quick question for someone just tryin to get this working...How exactly do you get this workin lol..I dled the 1 file shoved it into my system folder not sure if i needed source code or database..mutator seemed to show up as well I had a weapon pack mutator active but when I start the listen server the perks box just says none perk active..and was also wondering where do I find the server startup commandline to add "?Mutator=ServerPerksV2.ServerPerksMut"?? Would much appreciate it if I could get some clarification as to how to make this work
 
Upvote 0
For listening servers you do NOT need to add the server command line. That is for dedicated servers only. To use a perk you need to change the minimum level to 0/1 instead of -1 (not available - need to unlock the level).

-----------------------------

I now have a bug in my version which is where my cloacked stalkers don't show their health bars until they've uncloaked.

Code:
// Display enemy health bars
static function SpecialHUDInfo(KFPlayerReplicationInfo KFPRI, Canvas C)
{
 local KFMonster KFEnemy;
 local HUDKillingFloor HKF;
 local float MaxDistanceSquared;
 if ( KFPRI.ClientVeteranSkillLevel > 0 )
 {
  HKF = HUDKillingFloor(C.ViewPort.Actor.myHUD);
  if ( HKF == none || C.ViewPort.Actor.Pawn == none )
   return;
  switch ( KFPRI.ClientVeteranSkillLevel )
  {
   case 1:
    MaxDistanceSquared = 25600; // 20% (160 units)
    break;
   case 2:
    MaxDistanceSquared = 102400; // 40% (320 units)
    break;
   case 3:
    MaxDistanceSquared = 230400; // 60% (480 units)
    break;
   case 4:
    MaxDistanceSquared = 409600; // 80% (640 units)
    break;
   case 5:
   case 6:
    MaxDistanceSquared = 640000; // 100% (800 units)
    break;
   default:
     MaxDistanceSquared = 640000; // 100% (800 units)
     break;
  }
  foreach C.ViewPort.Actor.DynamicActors(class'KFMonster',KFEnemy)
  {
   if ( KFEnemy.Health > 0 && !KFEnemy.Cloaked() && VSizeSquared(KFEnemy.Location - C.ViewPort.Actor.Pawn.Location) < MaxDistanceSquared )
   {
    HKF.DrawHealthBar(C, KFEnemy, KFEnemy.Health, KFEnemy.HealthMax , 50.0);
   }
  }
 }
}
static function bool ShowStalkers(KFPlayerReplicationInfo KFPRI)
{
 return true;
}
static function float GetStalkerViewDistanceMulti(KFPlayerReplicationInfo KFPRI)
{
 switch ( KFPRI.ClientVeteranSkillLevel )
 {
  case 0:
   return 0.0625; // 25%
  case 1:
   return 0.25; // 50%
  case 2:
   return 0.36; // 60%
  case 3:
   return 0.49; // 70%
  case 4:
   return 0.64; // 80%
 }
 return 1.0; // 100% of Standard Distance(800 units or 16 meters)
}

I've compared but it still seems the same as original. What I did was add the default for the health bars distance and ever since it's happened.
 
Last edited:
Upvote 0
I realised this and I tried just copying back what the original KFMod version has. Same problem but all of a sudden works. So I don't know what happened there.

Right what I want to do is change the Footer to not allow you to spectate once you've clicked ready but to UNREADY instead.

I've found inside SRLobbyFooter.uc
Code:
 else if(Sender == b_Ready)
 {
  if ( PC.Level.NetMode == NM_Standalone || !PC.PlayerReplicationInfo.bReadyToPlay )
  {
   //Set Ready
   PC.ServerRestartPlayer();
   PC.PlayerReplicationInfo.bReadyToPlay = True;
   if ( PC.Level.GRI.bMatchHasBegun )
    PC.ClientCloseMenu(true, false);
   b_Ready.Caption = UnreadyString;
  }
  else
  {
   // Spectate map while waiting for players to get ready
   LobbyMenu(PageOwner).bAllowClose = true;
   PC.ClientCloseMenu(true, false);
  }
 }

How would I change to unready instead (for the spectator bit and not replace the b_Ready section)? I know it will have
Code:
else if(Sender == b_UnReady)
I think. Any help?

I also got this to work by changing the above to:
Code:
 else if(Sender == b_Ready)
 {
  if ( PC.Level.NetMode == NM_Standalone || !PC.PlayerReplicationInfo.bReadyToPlay )
  {
   //Set Ready
   PC.ServerRestartPlayer();
   PC.PlayerReplicationInfo.bReadyToPlay = True;
   if ( PC.Level.GRI.bMatchHasBegun )
    PC.ClientCloseMenu(true, false);
   b_Ready.Caption = UnreadyString;
  }
  else
  { //Set UnReady
   PC.ServerRestartPlayer();
   PC.PlayerReplicationInfo.bReadyToPlay = False;
   if ( PC.Level.GRI.bMatchHasBegun )
    PC.ClientCloseMenu(true, false);
   b_Ready.Caption = ReadyString;
  }
 }
 
Upvote 0