Author Topic: Energy bar  (Read 1299 times)

Is there any way to increase the amount of energy in the energybar for player types? I don't mean increasing the recharge rate, or decreasing the %drain.  I actually want to increase the amount of energy in the bar.

Also, I was wondering if there is a way to make a player start with less than full energy, but then still be able to charge up to full.

(I wasn't sure if this should go in mod discussion or coding help, so I picked the one that sounded like it makes more sense, but please move it to the correct topic if i was wrong)

Code: [Select]
maxEnergy =  BIGARAMOUNTHERELUL;//was 15


To set the player's starting energy you'd need to package it like so:

Code: [Select]
package energyoverwrite{
function GameConnection::createPlayer(%client,%spawn)
{
     Parent::createPlayer(%client,%spawn);
     %client.player.setEnergyLevel(0);
}
};
activatepackage(energyoverwrite);
That's only if the createPlayer method is still used in this version of Blockland. It certainly was in 0002, just not sure about retail.

I was referring to playertypes in minigames, but your information may still be of use to me.  Thank you.

I believe it's either spawnplayer or playerspawn.

GameConnection::spawnplayer triggers GameConnection::createplayer with the second argument as a transform from PickSpawnPoint(); or MinigameSO::PickSpawnPoint().