Heat calculation is prone to error

  • Device: Galaxy S8
    OS version: Android 7.0
    App version: Not sure. Alpha 2.0?

    Reported via in-game tool: Yes
    Random: No
    Repeatable: Yes
    Exploitable: No

    The boolean operation(s) which determines whether or not a player has enough heat remaining to cast a spell is done in an error prone way which can lead to unexpected behavior when casting spells that cost 0 heat. Cool Off costs 0 heat but cannot be cast if the player is above 15 heat for some reason (such as a fire monster using Heat Up).

    Pseudocode of the bug:

    //Add spell cost to current heat to see if it goes over 15 heat
    If (currentHeat + spellHeatCost > 15){
    else {
    //If the player has enough heat bar to cast the spell, add spell cost to heat bar and cast the spell
    currentHeat += spellHeatCost;

    When heat is above 15, the if statement will return True even if the heat cost of the spell is 0 because currentHeat plus any non-negative number is going to still be greater than 15. Instead, available heat "room" remaining should be calculated first and prevented from going below 0 as follows:

    //How much more heat can the player gain without going over 15? In real code the "15" would be a global constant to allow it to be changed more easily.
    availableHeat = 15 - currentHeat;
    If (availableHeat < 0){
    availableHeat = 0;

    //Calculate if the player can cast a spell without going over 15 heat
    If(spellHeatCost <= availableHeat){
    } else {

    In this case, a spell with 0 heat will return True and the spell will be cast no matter what the player's current Heat level. But a spell that costs even 1 Heat will still fail due to Overheating if the player is at 15 or higher as normal.

    What should happen:
    Players can always cast spells that cost 0 heat no matter what their current heat level is.

    What does actually happen:
    Player overheats when casting 0 heat spells if they have above 15 heat.

    Does this prevent you for playing further:

  • @peter-larkin

    Great post!

    The Overheat mechanic has been a bug and is still an exploit. I thought they disabled it from player use though I know it is used by monsters just like other spells that have odd behaviour. Like the burn spells and steal.

    Keep it sparky!

Log in to reply

Looks like your connection to Maguss forum was lost, please wait while we try to reconnect.