Everything posted by Asweez
-
Packet problem
Wow thanks! That was really helpful. Right now I'm registering that packet in the MagiNetwork whose init method is being called in the initialization event. Should I register that packet in my client proxy?
-
Packet problem
Or not a server version but why is it trying to run on the server?
-
Packet problem
Thanks all, I'm still confused though. If I'm registering the packet on the client side why is it trying to run a server version of it?
-
Packet problem
So I made a syncSkills packet for my extended player and I am getting this error: Caused by: java.lang.RuntimeException: Attempted to load class net/minecraft/client/entity/EntityClientPlayerMP for invalid side SERVER at cpw.mods.fml.common.asm.transformers.SideTransformer.transform(SideTransformer.java:50) ~[forgeSrc-1.7.10-10.13.2.1230.jar:?] at net.minecraft.launchwrapper.LaunchClassLoader.runTransformers(LaunchClassLoader.java:279) ~[launchwrapper-1.11.jar:?] at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:176) ~[launchwrapper-1.11.jar:?] at java.lang.ClassLoader.loadClass(ClassLoader.java:425) ~[?:1.7.0_71] at java.lang.ClassLoader.loadClass(ClassLoader.java:358) ~[?:1.7.0_71] at java.lang.Class.getDeclaredConstructors0(Native Method) ~[?:1.7.0_71] at java.lang.Class.privateGetDeclaredConstructors(Class.java:2585) ~[?:1.7.0_71] at java.lang.Class.getConstructor0(Class.java:2885) ~[?:1.7.0_71] at java.lang.Class.newInstance(Class.java:350) ~[?:1.7.0_71] at cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper.instantiate(SimpleNetworkWrapper.java:113) ~[simpleNetworkWrapper.class:?] at cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper.registerMessage(SimpleNetworkWrapper.java:106) ~[simpleNetworkWrapper.class:?] at com.apmods.magicraft.network.MagiNetwork.registerMessageForServer(MagiNetwork.java:31) ~[MagiNetwork.class:?] at com.apmods.magicraft.network.MagiNetwork.init(MagiNetwork.java:19) ~[MagiNetwork.class:?] at com.apmods.magicraft.main.MagiCraft.init(MagiCraft.java:40) ~[MagiCraft.class:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.7.0_71] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[?:1.7.0_71] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.7.0_71] at java.lang.reflect.Method.invoke(Method.java:606) ~[?:1.7.0_71] at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:513) ~[FMLModContainer.class:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.7.0_71] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[?:1.7.0_71] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.7.0_71] at java.lang.reflect.Method.invoke(Method.java:606) ~[?:1.7.0_71] at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) ~[guava-17.0.jar:?] at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47) ~[guava-17.0.jar:?] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) ~[guava-17.0.jar:?] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304) ~[guava-17.0.jar:?] at com.google.common.eventbus.EventBus.post(EventBus.java:275) ~[guava-17.0.jar:?] at cpw.mods.fml.common.LoadController.sendEventToModContainer(LoadController.java:208) ~[LoadController.class:?] at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:187) ~[LoadController.class:?] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.7.0_71] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[?:1.7.0_71] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.7.0_71] at java.lang.reflect.Method.invoke(Method.java:606) ~[?:1.7.0_71] at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74) ~[guava-17.0.jar:?] at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47) ~[guava-17.0.jar:?] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322) ~[guava-17.0.jar:?] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304) ~[guava-17.0.jar:?] at com.google.common.eventbus.EventBus.post(EventBus.java:275) ~[guava-17.0.jar:?] at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:118) ~[LoadController.class:?] at cpw.mods.fml.common.Loader.initializeMods(Loader.java:691) ~[Loader.class:?] ... 5 more Here is my code MagiNetwork: SyncSkills
-
Making the player swing his arm
I have a packet system set up and when the packet it received I want the player to swing his arm like it does when you hit something or break something. Is this possible?
-
Custom Light not working
I fixed it. All I had to do was remove the if(!world.isRemote)
-
Custom Light not working
No wait it actually worked yesterday and it was full time, like the player was constantly a light source
-
Custom Light not working
No.. It was working a few days ago
- Custom Light not working
-
Custom Light not working
So my light just won't show up. Through the System.out.println() s I know that the event IS being called, the addLight IS being called and the light value IS NOT over 15 (its 9). What am I doing wrong? @SubscribeEvent public void onTick(TickEvent.PlayerTickEvent evt){ if(!evt.player.worldObj.isRemote){ if(evt.player.inventory.getCurrentItem() != null && evt.player.inventory.getCurrentItem().getItem() instanceof ItemWand){ ItemStack wand = evt.player.inventory.getCurrentItem(); System.out.println(wand.stackTagCompound.getBoolean("lumos")); if(wand.stackTagCompound != null && wand.stackTagCompound.getBoolean("lumos") == true){ evt.player.worldObj.updateLightByType(EnumSkyBlock.Block, prevposX, prevposY, prevposZ); this.addLight(evt.player.worldObj, evt.player); System.out.println("add light"); } else if(wand.stackTagCompound != null && wand.stackTagCompound.getBoolean("lumos") == false){ evt.player.worldObj.updateLightByType(EnumSkyBlock.Block, prevposX, prevposY, prevposZ); this.deleteLight(evt.player.worldObj, evt.player); evt.player.worldObj.updateLightByType(EnumSkyBlock.Block, prevposX, prevposY, prevposZ); } } } } private void addLight(World world, EntityPlayer player) { MagiSkills ext = MagiSkills.get(player); world.setLightValue(EnumSkyBlock.Block, (int) player.posX, (int) player.posY, (int) player.posZ, 9+ext.getCurrentSkillLevel(SpellLib.LUMOS)); System.out.println(9+ext.getCurrentSkillLevel(SpellLib.LUMOS)); prevposX = (int)player.posX; prevposY = (int)player.posY; prevposZ = (int)player.posZ; world.markBlockRangeForRenderUpdate((int) player.posX, (int) player.posY, (int) player.posX, 12, 12, 12); world.markBlockForUpdate((int) player.posX, (int) player.posY, (int) player.posZ); // for(int i = 1; i < 6; i++){ // for(int j = 1; j < 6; j++){ // for(int k = 1; k < 4; k++){ // world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 3 + j, (int) player.posY - 2 + k, (int) player.posZ - 3 + i); // } // } world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY - 1, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY - 1, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY - 1, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY - 1, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY - 1, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY - 1, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY - 1, (int) player.posZ-1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY - 1, (int) player.posZ-1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY - 1, (int) player.posZ - 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY + 1, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY + 1, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY + 1, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY + 1, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY + 1, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY + 1, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY + 1, (int) player.posZ - 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY + 1, (int) player.posZ - 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY + 1, (int) player.posZ - 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY, (int) player.posZ + 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY, (int) player.posZ); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX + 1, (int) player.posY, (int) player.posZ - 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX, (int) player.posY, (int) player.posZ - 1); world.updateLightByType(EnumSkyBlock.Block, (int) player.posX - 1, (int) player.posY, (int) player.posZ - 1); // } }
-
[1.7.10] How do I create a status effect?
IEEP is IExtendedEntityProperties btw
-
[SOLVED] 1.7.10 Crafting recipes: Crafting the block crashes my minecraft, help
Well its obvious. You are trying to register the Block after it is in the recipe. Essentially, you have a Block that doesn't exist yet in your crafting recipe. That's why its crashing. Register your ModBlocks before CraftingRegistry
-
How do I get the EntityPlayer on the Server Side?
Dude ash jack had the original question
- Need Help!!
-
Need Help!!
I've been trying to figure this out for days now but I have an Extended Player thing set up and I have a GUI that I want to display these properties. Like the tutorial says, I have to make packets. I know how to work out packets and everything but I'm stuck on the SyncPlayerPropsPacket because all the info on the tutorial is outdated. Any ideas or code that could help?
-
How do I get the EntityPlayer on the Server Side?
Uhh its not my question
-
[1.7.10]Structure Generation
Post your code
-
How do I get the EntityPlayer on the Server Side?
I'm confused does this have anything to do with the original question?
-
How do I get the EntityPlayer on the Server Side?
Where are you using it
-
How do I get the EntityPlayer on the Server Side?
WHERE ARE YOU USING IT? And world.playerEntities is stupid
-
[1.7.10] world.getBlock(x, y, z) [Fixed]
Well it's probably because you are using the client side world. Where is this method?
-
How do I get the EntityPlayer on the Server Side?
Well you never want to use the client side player unless you are on the client(gui, key binding). It is almost always available on the server side. Where do you need an instance of the player?
-
Creating a bot
Dude take a hint! We aren't helping you because what you are trying to do is hacking!!
-
Creating a bot
So you don't actually program using forge and you're basically just asking us experienced modders to make a hacked client for you?
-
Getting Extended Player properties on the Client
How would I do that? I tried doing it like I would in an item/entity (i.e ExtendedPlayer ext = ExtendedPlayer.get(player), then ext.getProperty()) but the client(my GUI) isn't showing any of the properties that are there. I have a basic counter of a level system, and even though the System tells me it is level 2 the GUI says level 0 still. Any help?
IPS spam blocked by CleanTalk.