I'm attempting to put restrictions on a lua ability that exist in match, but don't exist in platform gametypes like co-op and race. Yet part of my script, namely the part that manipulates S_SKIN values, is still executed in match anyways.
Example script for reproduction purposes:
Example script for reproduction purposes:
Code:
addHook("ThinkFrame", do
for player in players.iterate
if player.mo and player.mo.skin == "sonic"
and G_PlatformGametype()
and not G_RingSlingerGametype()
player.jumpfactor = 3*FRACUNIT
end
end
end)
Last edited by a moderator: