Skip to main content
deleted 67 characters in body
Source Link
TheNumberOne
  • 11.6k
  • 1
  • 38
  • 70
{
    "Simpleton": function(dist, energy, bots, storage) {
        if (!dist) {
            storage.speed =return energy / (100
        }
        return- storage.speeddist)
    }
}
{
    "Simpleton": function(dist, energy, bots, storage) {
        if (!dist) {
            storage.speed = energy / 100
        }
        return storage.speed
    }
}
{
    "Simpleton": function(dist, energy, bots, storage) {
        return energy / (100 - dist)
    }
}
added 1112 characters in body
Source Link
TheNumberOne
  • 11.6k
  • 1
  • 38
  • 70

Steady

Steady tries to go the same amount every turn, but doesn't like having extra energy.

{
    "Steady": function(dist, energy, bots, storage) {
        storage.turns = storage.turns || 0
        storage.totalTurns = storage.totalTurns || 0
        storage.games = storage.games || 0
        storage.totalEnergyGained = storage.totalEnergyGained || 0
        storage.previousEnergy = storage.previousEnergy || 0
        if (!dist) {
            if (storage.games == 0) {
                storage.speed = 1
            } else {
                storage.totalTurns += storage.turns
                storage.turns = 0
                storage.speed = Math.sqrt(storage.totalEnergyGained / storage.totalTurns) + storage.previousEnergy / storage.totalTurns
            }
            storage.totalEnergyGained += energy - storage.previousEnergy
            storage.games++
        }
        storage.turns++;
        storage.previousEnergy = Math.max(energy - Math.max(Math.min(storage.speed, 100 - dist, Math.sqrt(energy)), 0) ** 2, 0)
        return storage.speed;
    }
}

Steady

Steady tries to go the same amount every turn, but doesn't like having extra energy.

{
    "Steady": function(dist, energy, bots, storage) {
        storage.turns = storage.turns || 0
        storage.totalTurns = storage.totalTurns || 0
        storage.games = storage.games || 0
        storage.totalEnergyGained = storage.totalEnergyGained || 0
        storage.previousEnergy = storage.previousEnergy || 0
        if (!dist) {
            if (storage.games == 0) {
                storage.speed = 1
            } else {
                storage.totalTurns += storage.turns
                storage.turns = 0
                storage.speed = Math.sqrt(storage.totalEnergyGained / storage.totalTurns) + storage.previousEnergy / storage.totalTurns
            }
            storage.totalEnergyGained += energy - storage.previousEnergy
            storage.games++
        }
        storage.turns++;
        storage.previousEnergy = Math.max(energy - Math.max(Math.min(storage.speed, 100 - dist, Math.sqrt(energy)), 0) ** 2, 0)
        return storage.speed;
    }
}
deleted 41 characters in body
Source Link
TheNumberOne
  • 11.6k
  • 1
  • 38
  • 70

Jack in the Box

Saves up its energy until it can beat the game in 40 moves, bringing the number of average moves per game down.

{
    "Jack in the Box": function(dist, energy, bots, storage) {
        if (!dist == 0) {
            if (10000 / energy <=>= 40250) {
                storage.speed = energy / 100
            } else {
                storage.speed = .5
            }
        }
        storage.turns++;
        return storage.speed
    }
}

Simpleton

Simpleton just wants to win :(

{
    "Simpleton": function(dist, energy, bots, storage) {
        if (!dist == 0) {
            storage.speed = energy / 100
        }
        return storage.speed
    }
}

Jack in the Box

Saves up its energy until it can beat the game in 40 moves, bringing the number of average moves per game down.

{
    "Jack in the Box": function(dist, energy, bots, storage) {
        if (dist == 0) {
            if (10000 / energy <= 40) {
                storage.speed = energy / 100
            } else {
                storage.speed = .5
            }
        }
        storage.turns++;
        return storage.speed
    }
}

Simpleton

Simpleton just wants to win :(

{
    "Simpleton": function(dist, energy, bots, storage) {
        if (dist == 0) {
            storage.speed = energy / 100
        }
        return storage.speed
    }
}

Jack in the Box

Saves up its energy until it can beat the game in 40 moves, bringing the number of average moves per game down.

{
    "Jack in the Box": function(dist, energy, bots, storage) {
        if (!dist) {
            if (energy >= 250) {
                storage.speed = energy / 100
            } else {
                storage.speed = .5
            }
        }
        return storage.speed
    }
}

Simpleton

Simpleton just wants to win :(

{
    "Simpleton": function(dist, energy, bots, storage) {
        if (!dist) {
            storage.speed = energy / 100
        }
        return storage.speed
    }
}
deleted 43 characters in body
Source Link
TheNumberOne
  • 11.6k
  • 1
  • 38
  • 70
Loading
Source Link
TheNumberOne
  • 11.6k
  • 1
  • 38
  • 70
Loading