One of my game's upcoming boss fights is a tycoon-based mini-game where the players lose around 25% of their cash upon death.
The cash is shared by all players.
The issue here is that math is not one of my strong points, and I am unsure where to incorporate math.floor or math.ceil into my script in order to prevent decimals.
game.Players.PlayerAdded:connect (function(Player)
local Money = game.workspace.Money
Player.CharacterAdded:connect(function()
Player.Character.Humanoid.WalkSpeed = 25
Player.Character.Humanoid.Died:connect(function()
Money.Value = Money.Value - (Money.Value - (Money.Value*0.25))
end)
end)
end)
Any help would be greatly appreciated, because it gets quite bothersome when you have a 10 degit decimal at the top of your screen.
