Should it not be like this if it gives 50% more exp.This will add %50 more exp if player is in party
Code:-- Party Bonus if self:getParty() then exp = exp * 0.5 end
-- Party Bonus
if self:getParty() then
exp = exp * 1.5
end
local config = {
["Monday"] = 1.0,
["Tuesday"] = 1.0,
["Wednesday"] = 1.0,
["Thursday"] = 1.0,
["Friday"] = 1.0,
["Saturday"] = 1.5,
["Sunday"] = 2.0
}
function Player:onGainExperience(source, exp, rawExp)
return exp = exp * config[os.date("%A")]
end
also an easy table w/ functions inside could be made for each dayCode:local config = { ["Monday"] = 1.0, ["Tuesday"] = 1.0, ["Wednesday"] = 1.0, ["Thursday"] = 1.0, ["Friday"] = 1.0, ["Saturday"] = 1.5, ["Sunday"] = 2.0 } function Player:onGainExperience(source, exp, rawExp) return exp = exp * config[os.date("%A")] end
dont work for me :/Code:local config = { ["Monday"] = 1.0, ["Tuesday"] = 1.0, ["Wednesday"] = 1.0, ["Thursday"] = 1.0, ["Friday"] = 1.0, ["Saturday"] = 1.5, ["Sunday"] = 2.0 } function Player:onGainExperience(source, exp, rawExp) return exp = exp * config[os.date("%A")] end