Disabling get_energy_max to keep client/server sync
This commit is contained in:
parent
cdb2d3badd
commit
c73f68569f
2 changed files with 7 additions and 2 deletions
|
@ -170,6 +170,11 @@ function ShowInfo()
|
|||
Show("Core:")
|
||||
Show(" x, y, z = "..X..", "..Y..", "..Z)
|
||||
local energy = warp.get_energy_level()
|
||||
local energyMax = 1000000
|
||||
if warpcore.get_energy_max ~= nil then
|
||||
energyMax = warpcore.get_energy_max()
|
||||
if energyMax == nil then energyMax = 1 end
|
||||
end
|
||||
Show(" Energy = "..math.floor(energy / 1000000).." % ("..energy.."EU)")
|
||||
Show(" Attached players = "..warp.get_attached_players())
|
||||
Show("Dimensions:")
|
||||
|
|
|
@ -50,7 +50,7 @@ public class TileEntityProtocol extends TileEntity implements IPeripheral
|
|||
"set_distance", "set_direction",
|
||||
"get_attached_players", "summon", "summon_all",
|
||||
"get_x", "get_y", "get_z",
|
||||
"get_energy_level", "get_energy_max", "get_energy_required",
|
||||
"get_energy_level", /* "get_energy_max",/**/
|
||||
"do_jump",
|
||||
"get_ship_size",
|
||||
"set_beacon_frequency",
|
||||
|
@ -58,7 +58,7 @@ public class TileEntityProtocol extends TileEntity implements IPeripheral
|
|||
"set_core_frequency",
|
||||
"is_in_space", "is_in_hyperspace",
|
||||
"set_target_jumpgate",
|
||||
"isAttached"
|
||||
"isAttached", "get_energy_required"
|
||||
};
|
||||
|
||||
private int ticks = 0;
|
||||
|
|
Loading…
Reference in a new issue