comment cleanup 1, test commit

This commit is contained in:
Sen 2025-03-11 00:48:54 +01:00
parent 22186c33b9
commit c528157a0e
3 changed files with 1 additions and 82 deletions

View file

@ -159,13 +159,6 @@ public class Game implements IThreadListener {
Game.getGame().resize(value);
}
}
// public static class DebugFunction implements BoolFunction {
// public void apply(BoolVar cv, boolean value) {
// if(Game.getGame().getAudioInterface() != null)
// Game.getGame().getAudioInterface().alSetDebug(value);
// }
// }
public static class DistanceFunction implements IntFunction {
public void apply(IntVar cv, int value) {
@ -174,12 +167,6 @@ public class Game implements IThreadListener {
Game.getGame().distance(value);
}
}
// private static class BuildTimeFunction implements IntFunction {
// public void apply(IntVar cv, int value) {
// SKC.buildtime(value);
// }
// }
public static final int LOG_BUFFER = 32768;
@ -196,12 +183,10 @@ public class Game implements IThreadListener {
private boolean quarternary;
public boolean jump;
public boolean sneak;
// public boolean hideGUI;
public boolean debugCamEnable;
public boolean debugWorld;
public boolean zooming;
public boolean sprint;
// public boolean overlay;
public boolean renderOutlines;
public boolean setGamma;
public boolean nickChanged;
@ -210,8 +195,6 @@ public class Game implements IThreadListener {
public boolean itemCheat;
public boolean dayCycle = true;
// public int displayWidth = 1280;
// public int displayHeight = 800;
private int leftClickCounter;
private int rightClickTimer;
private int chunkLoadTimer;
@ -271,9 +254,6 @@ public class Game implements IThreadListener {
@Variable(name = "win_sync", category = CVarCategory.WINDOW, min = -1, max = 16384, callback = SyncFunction.class)
public int sync = 0;
// public int fb;
// public int fbtex;
public int width;
public int height;
@ -289,9 +269,6 @@ public class Game implements IThreadListener {
public int saved_ypos = 0x80000000;
public int fb_x;
public int fb_y;
// public Gui queue;
@Variable(name = "phy_sensitivity", category = CVarCategory.PHYSICS, min = 0.01f, max = 10.0f, display = "Mausempfindlichkeit", precision = 2, unit = "%")
public float sensitivity = 1.0f;
@ -342,31 +319,12 @@ public class Game implements IThreadListener {
public int port = 26666;
public int bind = -1;
// @Variable(name = "mid_play_unknown", category = CVarCategory.SOUND, display = "Unbekannte Banken")
// public boolean midiUnknownBanks = true;
// @Variable(name = "mid_keep_notes", category = CVarCategory.SOUND, display = "Stimmen behalten")
// public boolean midiKeepNotes = false;
// @Variable(name = "mid_dont_fade", category = CVarCategory.SOUND, display = "Nicht ausklingen")
// public boolean midiNoWait = false;
// @Variable(name = "mid_debug_events", category = CVarCategory.SOUND, callback = DebugFunction.class, display = "MIDI-Debug")
// public boolean midiDebug = false;
// @Variable(name = "mid_velocity_func", category = CVarCategory.SOUND, min = -128, max = 127, display = "Anschlag")
// public int midiVeloFunc = 1;
// @Variable(name = "mid_opl_voices", category = CVarCategory.SOUND, min = 4, max = 192, display = "OPL-Stimmen")
// public int midiVoices = 64;
// @Variable(name = "mid_opl_bank", category = CVarCategory.SOUND, display = "OPL-Bank")
// public OPL3Bank midiBank = OPL3Bank.DMX_DMX;
@Variable(name = "snd_device_type", category = CVarCategory.SOUND, display = "Tonausgabe")
public boolean soundEnabled = true;
// @Variable(name = "snd_sample_rate", category = CVarCategory.SOUND, display = "Abtastrate")
// public SampleRate soundSampleRate = SampleRate.DAT;
@Variable(name = "snd_buffer_size", category = CVarCategory.SOUND, min = 0, max = 1048576, display = "Puffergröße")
public int soundBufferSize = 2048;
@Variable(name = "snd_frame_size", category = CVarCategory.SOUND, min = 2, max = 8192, display = "PCM-Intervall")
public int soundFrameSize = 32;
// @Variable(name = "snd_sample_format", category = CVarCategory.SOUND, display = "Sample-Format")
// public SampleFormat soundSampleFormat = SampleFormat.S16LE;
private Server server;
private AudioInterface audio;
@ -380,14 +338,7 @@ public class Game implements IThreadListener {
private final Bind[] keyBindsHotbar = new Bind[] {
Bind.SELECT1, Bind.SELECT2, Bind.SELECT3, Bind.SELECT4, Bind.SELECT5, Bind.SELECT6, Bind.SELECT7, Bind.SELECT8, Bind.SELECT9
};
// this.gm.launchIntegratedServer(null, "Debug");
// this.gm.launchIntegratedServer(dir, user);
// }
// this.gm.displayGuiScreen(new GuiConnecting(this.gm, server));
private Game() {
}
@ -420,12 +371,6 @@ public class Game implements IThreadListener {
this.connection = connection;
}
// public void convert(String folder, String user)
// {
// SKC.info("Welt '" + folder + "' wird konvertiert");
// Converter.convertMapFormat(new File(folder), user, null);
// }
public void connectToIntegrated(Server server, String user) {
this.debugWorld = server.getFolder() == null;
this.displayGuiScreen(null);
@ -437,23 +382,16 @@ public class Game implements IThreadListener {
this.connection = connection;
}
// public void disconnected(String reason) {
// SKC.disconnected(reason);
// }
public void unloadWorld() {
NetHandlerPlayClient netHandler = this.getNetHandler();
if(netHandler != null)
netHandler.cleanup();
// if(this.server != null)
// this.server.shutdown();
this.debugWorld = false;
this.viewEntity = null;
this.connection = null;
this.theWorld = null;
this.thePlayer = null;
this.soundManager.stopSounds();
// SKC.loaded(false);
}
public void refreshResources()
@ -472,11 +410,7 @@ public class Game implements IThreadListener {
{
this.textureManager = new TextureManager();
this.textureManager.onReload();
// if(!Region.SAVE_DIR.exists()) {
// Region.SAVE_DIR.mkdirs();
// }
this.soundManager = new SoundManager(this);
// FontRenderer.setTextureManager(this.textureManager);
Colorizer.reload();
GlState.enableTexture2D();
GlState.shadeModel(7425);
@ -509,7 +443,6 @@ public class Game implements IThreadListener {
EntityTexManager.loadNpcTextures();
this.effectRenderer = new EffectRenderer(this.theWorld, this.textureManager);
new File("skins").mkdirs();
// this.displayGuiScreen(new GuiEmpty());
}
public void start()