Add some of the model subsystem to the server. The part that doesn't require openGL. This allows for systems that dual models as collision/selection boxes etc.
This commit is contained in:
parent
92923a3521
commit
7208c2c059
5 changed files with 92 additions and 0 deletions
10
patches/minecraft/net/minecraft/src/ModelBase.java.patch
Normal file
10
patches/minecraft/net/minecraft/src/ModelBase.java.patch
Normal file
|
@ -0,0 +1,10 @@
|
|||
--- ../src_base/minecraft/net/minecraft/src/ModelBase.java
|
||||
+++ ../src_work/minecraft/net/minecraft/src/ModelBase.java
|
||||
@@ -7,7 +7,6 @@
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public abstract class ModelBase
|
||||
{
|
||||
public float onGround;
|
18
patches/minecraft/net/minecraft/src/ModelBox.java.patch
Normal file
18
patches/minecraft/net/minecraft/src/ModelBox.java.patch
Normal file
|
@ -0,0 +1,18 @@
|
|||
--- ../src_base/minecraft/net/minecraft/src/ModelBox.java
|
||||
+++ ../src_work/minecraft/net/minecraft/src/ModelBox.java
|
||||
@@ -3,7 +3,6 @@
|
||||
import cpw.mods.fml.common.Side;
|
||||
import cpw.mods.fml.common.asm.SideOnly;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class ModelBox
|
||||
{
|
||||
/**
|
||||
@@ -99,6 +98,7 @@
|
||||
/**
|
||||
* Draw the six sided box defined by this ModelBox
|
||||
*/
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
public void render(Tessellator par1Tessellator, float par2)
|
||||
{
|
||||
TexturedQuad[] var3 = this.quadList;
|
44
patches/minecraft/net/minecraft/src/ModelRenderer.java.patch
Normal file
44
patches/minecraft/net/minecraft/src/ModelRenderer.java.patch
Normal file
|
@ -0,0 +1,44 @@
|
|||
--- ../src_base/minecraft/net/minecraft/src/ModelRenderer.java
|
||||
+++ ../src_work/minecraft/net/minecraft/src/ModelRenderer.java
|
||||
@@ -7,7 +7,6 @@
|
||||
import java.util.List;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class ModelRenderer
|
||||
{
|
||||
/** The size of the texture file's width in pixels. */
|
||||
@@ -117,7 +116,8 @@
|
||||
this.rotationPointY = par2;
|
||||
this.rotationPointZ = par3;
|
||||
}
|
||||
-
|
||||
+
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
public void render(float par1)
|
||||
{
|
||||
if (!this.isHidden)
|
||||
@@ -207,6 +207,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
public void renderWithRotation(float par1)
|
||||
{
|
||||
if (!this.isHidden)
|
||||
@@ -245,6 +246,7 @@
|
||||
/**
|
||||
* Allows the changing of Angles after a box has been rendered
|
||||
*/
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
public void postRender(float par1)
|
||||
{
|
||||
if (!this.isHidden)
|
||||
@@ -289,6 +291,7 @@
|
||||
/**
|
||||
* Compiles a GL display list for this model
|
||||
*/
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
private void compileDisplayList(float par1)
|
||||
{
|
||||
this.displayList = GLAllocation.generateDisplayLists(1);
|
|
@ -0,0 +1,10 @@
|
|||
--- ../src_base/minecraft/net/minecraft/src/PositionTextureVertex.java
|
||||
+++ ../src_work/minecraft/net/minecraft/src/PositionTextureVertex.java
|
||||
@@ -3,7 +3,6 @@
|
||||
import cpw.mods.fml.common.Side;
|
||||
import cpw.mods.fml.common.asm.SideOnly;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class PositionTextureVertex
|
||||
{
|
||||
public Vec3 vector3D;
|
10
patches/minecraft/net/minecraft/src/TexturedQuad.java.patch
Normal file
10
patches/minecraft/net/minecraft/src/TexturedQuad.java.patch
Normal file
|
@ -0,0 +1,10 @@
|
|||
--- ../src_base/minecraft/net/minecraft/src/TexturedQuad.java
|
||||
+++ ../src_work/minecraft/net/minecraft/src/TexturedQuad.java
|
||||
@@ -3,7 +3,6 @@
|
||||
import cpw.mods.fml.common.Side;
|
||||
import cpw.mods.fml.common.asm.SideOnly;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class TexturedQuad
|
||||
{
|
||||
public PositionTextureVertex[] vertexPositions;
|
Loading…
Reference in a new issue