Skip to content

Commit

Permalink
Make juggernaut take 2x more if player has more
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiskster committed Sep 7, 2024
1 parent dde14d6 commit f4dcd0c
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/Lua/InbuiltModeScripts/juggernaut.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,16 @@ local function P_StealPlayerScoreButOOG(player, amount) -- oog means outofgame
if player == refplayer or refplayer.ptsr.outofgame then
continue
end

if refplayer.score >= amount then
stolen = $ + amount
refplayer.score = $ - amount

local per_amount = amount -- the real amount

if refplayer.score > player.score then
per_amount = $ * 2
end

if refplayer.score >= per_amount then
stolen = $ + per_amount
refplayer.score = $ - per_amount
else
stolen = $ + refplayer.score
refplayer.score = 0
Expand Down

0 comments on commit f4dcd0c

Please sign in to comment.