With 0.4 the stamina recovery system is built into the server, if it isn't working start by checking your config.lua if it's activated / default values.
If the player is offline it shouldn't "recover" any stamina points, if you want that you need to modify the source code.
rateStaminaLoss = 1
rateStaminaGain = 3
rateStaminaThresholdGain = 3
staminaRatingLimitTop = 40 * 60
staminaRatingLimitBottom = 14 * 60
staminaLootLimit = 14 * 60
rateStaminaAboveNormal = 1.0
rateStaminaUnderNormal = 0.5
staminaThresholdOnlyPremium = true
Code:rateStaminaLoss = 1 rateStaminaGain = 3 rateStaminaThresholdGain = 3 staminaRatingLimitTop = 40 * 60 staminaRatingLimitBottom = 14 * 60 staminaLootLimit = 14 * 60 rateStaminaAboveNormal = 1.0 rateStaminaUnderNormal = 0.5 staminaThresholdOnlyPremium = true
config.lua
I set it up in several ways even so it does not regenerate the stamina.
In source code where could it be configured?
Check if you got the code related to stamina in your source code for starters, also try the serach function since there was a thread about this not long ago, might be a server related issue?
I used the same .exe file on another server, stamina increased.
Where would the problem be? I looked at everything and did not find, creaturescript, etc.
Yes, same settingsWell take a look in creaturescript and globalevents I suppose.
But i don't know if 0.4 has any Lua functions regarding stamina, was it the same config.lua settings?
Yes, same settings
//getPlayerStamina(cid)
//doPlayerSetStamina(cid, minutes)