aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/core
diff options
context:
space:
mode:
authorDraknyte1 <Draknyte1@hotmail.com>2017-03-04 10:09:37 +1000
committerDraknyte1 <Draknyte1@hotmail.com>2017-03-04 10:09:37 +1000
commitba89972a22a316030f8c3bd99974f915b1d7aefc (patch)
tree59c314b6dbc38ba05945c5ef401339fbade5ef6b /src/Java/gtPlusPlus/core
parentf12ae9f471ed1c8ff0e52954eef9c8d293de0676 (diff)
downloadGT5-Unofficial-ba89972a22a316030f8c3bd99974f915b1d7aefc.tar.gz
GT5-Unofficial-ba89972a22a316030f8c3bd99974f915b1d7aefc.tar.bz2
GT5-Unofficial-ba89972a22a316030f8c3bd99974f915b1d7aefc.zip
$ Further fixed PlayerAPI related content, using COMPAT_PlayerAPI.java which was created for the purpose of isolation. Much better than just adding some if checks to ClientProxy.java
Diffstat (limited to 'src/Java/gtPlusPlus/core')
-rw-r--r--src/Java/gtPlusPlus/core/proxy/ClientProxy.java20
1 files changed, 12 insertions, 8 deletions
diff --git a/src/Java/gtPlusPlus/core/proxy/ClientProxy.java b/src/Java/gtPlusPlus/core/proxy/ClientProxy.java
index 6b61515fa1..3648bfa080 100644
--- a/src/Java/gtPlusPlus/core/proxy/ClientProxy.java
+++ b/src/Java/gtPlusPlus/core/proxy/ClientProxy.java
@@ -1,8 +1,8 @@
package gtPlusPlus.core.proxy;
import gtPlusPlus.GTplusplus;
-import gtPlusPlus.core.common.BasePlayer;
import gtPlusPlus.core.common.CommonProxy;
+import gtPlusPlus.core.common.compat.COMPAT_PlayerAPI;
import gtPlusPlus.core.handler.events.SneakManager;
import gtPlusPlus.core.handler.render.FirepitRender;
import gtPlusPlus.core.lib.LoadedMods;
@@ -12,15 +12,13 @@ import net.minecraft.client.Minecraft;
import net.minecraft.client.particle.EntityFX;
import net.minecraft.entity.Entity;
import net.minecraftforge.common.MinecraftForge;
-import api.player.client.ClientPlayerAPI;
import cpw.mods.fml.client.registry.ClientRegistry;
import cpw.mods.fml.client.registry.RenderingRegistry;
+import cpw.mods.fml.common.Optional;
import cpw.mods.fml.common.event.*;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
-import cpw.mods.fml.common.Optional;
-@SideOnly(Side.CLIENT)
public class ClientProxy extends CommonProxy{
/*private final HashSet<String> mCapeList = new HashSet<String>();
@@ -42,7 +40,7 @@ public class ClientProxy extends CommonProxy{
GTplusplus.loadTextures();
//We boot up the sneak manager.
if (LoadedMods.PlayerAPI){
- MinecraftForge.EVENT_BUS.register(SneakManager.instance);
+ init_PlayerAPI_PRE();
}
}
@@ -51,7 +49,7 @@ public class ClientProxy extends CommonProxy{
// TODO Auto-generated method stub
if (LoadedMods.PlayerAPI){
- playerAPIStuff();
+ init_PlayerAPI_INIT();
}
super.init(e);
@@ -120,9 +118,15 @@ public class ClientProxy extends CommonProxy{
}*/
@Optional.Method(modid = "PlayerAPI")
- private void playerAPIStuff(){
+ private void init_PlayerAPI_PRE(){
+ //Register player instance
+ COMPAT_PlayerAPI.clientProxy.initPre();
+ }
+
+ @Optional.Method(modid = "PlayerAPI")
+ private void init_PlayerAPI_INIT(){
//Register player instance
- ClientPlayerAPI.register("SneakManager", BasePlayer.class);
+ COMPAT_PlayerAPI.clientProxy.Init();
}