Skip to content

Instantly share code, notes, and snippets.

View LunNova's full-sized avatar
🌐
worldbuilding in progress

Luna LunNova

🌐
worldbuilding in progress
View GitHub Profile
@LunNova
LunNova / RenderBlocks.java
Created May 12, 2012 11:06
net.minecraft.src.RenderBlocks fix
package net.minecraft.src;
import net.minecraft.client.Minecraft;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
//Spout start
import org.spoutcraft.client.config.ConfigReader;
import com.pclewis.mcpatcher.mod.Colorizer;
//Spout end
interface MFSCallback{
void onSuccess(Object data);
void onError(Exception e);
}
//(EXAMPLE CALLS)
mfs.getDB("DBname", new MFSCallback{void onSuccess(Object d){/*Do something with the data - you know what type it is already.*/} void onError(){/*Do something to handle the error.*/}});
Nallar_: Proxed, put back the dwarfclasspick spell
» ryan removed it
» going through it.
» It looks like you're missing a lot of spells for DvZ... LIST, HELP, DWARFCLASSPICK, SummonDwarf are all missing - haven't checked any more.
» Is it working correctly for OPs though?
» If so, it's a permissions issue instead - or a magicspells configuration issue
@LunNova
LunNova / gist:2702603
Created May 15, 2012 15:22
I just don't know what went wrong
16:18:24 [SEVERE] Unable to create controller for the type: org.spout.vanilla.controller.VanillaControllerType@50b7114a
16:18:24 [SEVERE] Unable to create controller for the type: org.spout.vanilla.controller.VanillaControllerType@50b7114a
16:18:24 [SEVERE] Unable to create controller for the type: org.spout.vanilla.controller.VanillaControllerType@50b7114a
16:18:25 [SEVERE] Error while pulsing thread SpoutRegion{ ( 6, 0, 0), World: SpoutWorld{ world UUID: 1a101d4b-4db6-4cf9-8756-2bfbf532bd69 Age: 0}} Thread: null
java.lang.NullPointerException
at org.spout.engine.world.SpoutChunk.preSnapshot(SpoutChunk.java:807)
at org.spout.engine.world.SpoutRegion.preSnapshotRun(SpoutRegion.java:629)
at org.spout.engine.world.SpoutRegionManager.preSnapshotRun(SpoutRegionManager.java:70)
at org.spout.engine.util.thread.coretasks.PreSnapshotTask.call(PreSnapshotTask.java:39)
at org.spout.engine.util.thread.ThreadAsyncExecutor.executeTask(ThreadAsyncExecutor.java:162)
/*
* This file is part of Vanilla.
*
* Copyright (c) 2011-2012, SpoutDev <http://www.spout.org/>
* Vanilla is licensed under the SpoutDev License Version 1.
*
* Vanilla is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
Spout/org/spout/engine/world/SpoutWorld.java: this.getRegionFromBlock(x, y, z).unloadChunk(x, y, z, save);
Spout/org/spout/engine/world/SpoutChunk.java: WorldFiles.saveChunk(this, blockStore.getBlockIdArray(), blockStore.getDataArray(), skyLight, blockLight, this.parentRegion.getChunkOutputStream(this));
Spout/org/spout/engine/world/SpoutWorld.java: this.getRegionFromBlock(x, y, z).saveChunk(x, y, z);
@LunNova
LunNova / gist:2790410
Created May 25, 2012 20:31
Java command line args
-server -XX:+AggressiveOpts -XX:-DisableExplicitGC -XX:CompileThreshold=100 -XX:+UseFastAccessorMethods -XX:+UseCompressedOops
org.jdom.IllegalNameException: The name "-path" is not legal for JDOM/XML elements: XML names cannot begin with the character "-".
at org.jdom.Element.setName(Element.java:207)
at org.jdom.Element.<init>(Element.java:141)
at org.jdom.Element.<init>(Element.java:153)
at org.jetbrains.idea.maven.utils.MavenJDOMUtil$1.startTag(MavenJDOMUtil.java:82)
at com.intellij.psi.impl.source.parsing.xml.XmlBuilderDriver.processTagNode(XmlBuilderDriver.java:184)
at com.intellij.psi.impl.source.parsing.xml.XmlBuilderDriver.processTagNode(XmlBuilderDriver.java:195)
at com.intellij.psi.impl.source.parsing.xml.XmlBuilderDriver.processTagNode(XmlBuilderDriver.java:195)
at com.intellij.psi.impl.source.parsing.xml.XmlBuilderDriver.processTagNode(XmlBuilderDriver.java:195)
at com.intellij.psi.impl.source.parsing.xml.XmlBuilderDriver.processTagNode(XmlBuilderDriver.java:195)
@LunNova
LunNova / gist:2835728
Created May 30, 2012 11:41
Startup script for Grichecth
#!/bin/sh
while true
do
screen -t "MinecraftServer" -S "lk20" bash -c 'java -Xms17000M -Xmx17000M -jar bukkit.jar nogui ; exit' &
screen_pid=$!
wait $screen_pid
echo "If you want to completely stop the server process now, press Ctrl+C before the time is up!"
echo "Rebooting in:"
for i in 5 4 3 2 1
do
<nallar> Will just make onDestroy(Block block) final so it can't be accidentally overriden, and have it call onDestroy(block, 1.0).
* Darsstar1 has quit (Quit: Leaving.)
<nallar> Zidane, does it need to be called VanillaBlockChangeEvent? Can't it just be called BlockChangeEvent since it's in a different package. Not sure if that's confusing.
<Zidane> BlockChangeEvent is API
<Zidane> it would be confusing
<nallar> Zidane: https://github.com/VanillaDev/Vanilla/pull/220
<Zidane> erm nallar...blockchangeevent isn't just block breaking
<Zidane> if a dirt becomes grass...that is block change
<Zidane> You need to provide an appropriate source
<nallar> Which is done when the event is used? new VanillaBlockChangeEvent(block, new BlockSnapshot(block, this, getData()), block.getSource(), drops);