Created
March 13, 2016 23:41
-
-
Save hallelujah/fc5ca9d8693fc5139922 to your computer and use it in GitHub Desktop.
kraken can spawn only once
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Krakener:CanSpawn(ignore_cooldown) | |
return (self:TimeUntilCanSpawn() <= 0 or ignore_cooldown) and not self.kraken and self.spawn_chance_mod > 0.0 | |
end | |
--[[ | |
This means that the quacken can sapwn if and only if all those conditions are met: | |
* cooldown is 0 (you did not spawn the quaken recently) | |
* there is no quacken in the world | |
* the chance threshold is positive (spawning a quacken is random) | |
--]] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment