Jump to content

ZeroxCorbin

Forge Modder
  • Posts

    13
  • Joined

  • Last visited

Everything posted by ZeroxCorbin

  1. Yeah, no one else has reported an issue, and the user has 30+ mods installed. If it comes up again I will investigation it further. Thanks again for you suggestions.
  2. I have had little success testing with other mods in the development enviroment. I just get a bunch of class missing errors. I look into decompile but did not feel comfortable recompiling someone else's code. Is there a better way to debug with mods you do not have source for?
  3. All of tests I tried did not return the players uuid. The only thing I can think of is another mod has override the getid () method of the player. I told the user who reported the problem that at this time I do not have a solution. I am not going to test with all the mods they have installed. Thank you for you help.
  4. From my testing it seems like the player profile was modified by another mod. The player has no uuid assigned at the time of the error. It is caused when the Village class tries to get the reputation of the player for that village. Since the player profile does not have a UUID, the error occurs.
  5. I posted the wrong function. I was debugging and copied the wrong code. Here is the culprit. if (gameprofile != null) { nbttagcompound1.setString("UUID", gameprofile.getId().toString()); nbttagcompound1.setInteger("S", ((Integer)this.playerReputation.get(s)).intValue()); nbttaglist1.appendTag(nbttagcompound1); }
  6. Line 39: vil.writeVillageDataToNBT(nbt); It could be that another mod has altered or delayed the players gameprofile from being complete? I will wait for the first 5 second delay before calling writeVillageDataToNBT. Maybe this will allow the player profile to be setup before accessing it. I will output the ID with the exception catch. If it is blank. System.out.println("Invalid Argument Exception Occurred. Player ID:" + player.getGameProfile().getId().toString() + "\\n Please report this as an issue at: http://minecraft.curseforge.com/projects/zc-village-information \\n Thank you...");
  7. I am not writing the player NBT I am writing the village NBt to an nearly empty NBTTagCompound. I also do not call the method every tick. Only every 5 seconds calculated by the system time. A player should be available my method is called in this loop; for(EntityPlayer player : ms.getEntityWorld().playerEntities){ The error has to do with the gameprofile of the player. This happens in the Village class of Forge; if (gameprofile != null) { nbttagcompound1.setString("UUID", gameprofile.getId().toString()); nbttagcompound1.setInteger("S", ((Integer)this.playerReputation.get(s)).intValue()); nbttaglist1.appendTag(nbttagcompound1); } java.lang.IllegalArgumentException: Name and ID cannot both be blank at com.mojang.authlib.GameProfile.<init>(GameProfile.java:25) at net.minecraft.server.management.PlayerProfileCache.func_187319_a(SourceFile:81) at net.minecraft.server.management.PlayerProfileCache.func_152655_a(SourceFile:140) at net.minecraft.village.Village.func_82689_b(SourceFile:455) at zc_villages.server.ServerEvents.CreateVillageNBT(ServerEvents.java:39)
  8. It is called from the server tick event; @SubscribeEvent public void onTick(ServerTickEvent event){ if(event.phase == Phase.START){ Maybe I should use a different phase instead of Phase.START?
  9. This is the line that is being called. vil.writeVillageDataToNBT(nbt); Since my method does not pass the player, that is done in the Village class, I wont share all the code. However, if it helps here is how I get the Village; for(Village vil : player.worldObj.villageCollectionObj.getVillageList()) The exception occurs deaper in the code; java.lang.IllegalArgumentException: Name and ID cannot both be blank at com.mojang.authlib.GameProfile.<init>(GameProfile.java:25) at net.minecraft.server.management.PlayerProfileCache.func_187319_a(SourceFile:81) at net.minecraft.server.management.PlayerProfileCache.func_152655_a(SourceFile:140) at net.minecraft.village.Village.func_82689_b(SourceFile:455) at zc_villages.server.ServerEvents.CreateVillageNBT(ServerEvents.java:39)
  10. Hello everyone, I wrote this mod because I could. Hope you like it... Get it here: ZC Entity Information Check out my other mod if you like: ZC Village Information Features Displays a list of entities in the players area. (120 Blocks) Displays the number of entities spawned for each entity type. (Only entities the client is aware of.) Shows the position of each entity with a line. Server OP's can disable the use of entity lines on the player client with a server command. See Commands: In the mod options you can change the text position on the screen. Press the Advanced button. (Values are in pixels) Key Bindings [ - Toggles Entity list on/off. ] - Cycle through list. LCTR + ] - Cycle through list (reverse) Commands "/entitynolines true" or "/entitynolines false" - If you are a level 4 OP you can issue the server command "/entitynolines" to allow or disallow clients to see entity lines. Some may consider this mod a potential cheat on their server. If you would like to control clients that log into your server, load this mod on your server and issue the command "/entitynolines true". The mod does not have to be loaded on the client. You will not receive a mod missing error. Installation This is BETA. Use at your own risk. Copy the .jar file to the mods directory on the client, server, or both. The mod can run on a client without being on the server. The mod can run on a server without being on the client. Requirements 1.10.2 Compiled with Forge version: 1.10.2-12.18.1.2027 1.9.4 Compiled with Forge version: 1.9.4-12.17.0.1987 1.8.9 Compiled with Forge version: 1.8.9-11.15.1.1902-1.8.9 Images
  11. Hello, my mod had an issue reported by a user and I can't figure it out. In the server code I get the village closest to the player. I then write the village to NBT using; private NBTTagCompound CreateVillageNBT(EntityPlayer player, Village vil){ NBTTagCompound nbt = new NBTTagCompound(); nbt.setInteger("MsgType", 1); //Get the players UUID nbt.setString("UUID", player.getGameProfile().getId().toString()); //Get the current server tick time. nbt.setInteger("ServerTime", splitTime); if(vil != null){ try{ vil.writeVillageDataToNBT(nbt); }catch(IllegalArgumentException e){ nbt = new NBTTagCompound(); nbt.setInteger("MsgType", 1); //Get the players UUID nbt.setString("UUID", player.getGameProfile().getId().toString()); //Get the current server tick time. nbt.setInteger("ServerTime", splitTime); System.out.println("Invalid Argument Exception Occured. Please report this as an issue at: http://minecraft.curseforge.com/projects/zc-village-information /n Thank you..."); return nbt; } I put the try/catch in to make sure it was occurring at that location. Here is the dialog I had with the player so far: http://minecraft.curseforge.com/projects/zc-village-information/issues/1 Here is the original error dump: http://pastebin.com/Jm83jTUV I have not seen this error before myself. I suspect a different mod has modified the gameprofile of the player? Or was the village data modified? Was: compiled with Forge 1.10.2-12.18.1.2020 Now: compiled with Forge 1.10.2-12.18.1.2027 Error occurred on 1.10.2-12.18.1.2026 Thank you for any assistance...
  12. Change the name of you static enum MineralzItems or your class MineralzItems. Since they are the same name and contain static properties the compiler can not figure out which one to use. The error tells you. init() is undefined for your enum MineralzItems which is in the class Reference.
  13. Hello everyone, I wrote this mod so I don't have to keep looking at the villages.dat file to see what is happening to my villages. It has expanded from there. Get it here: ZC Village Information Check out my other mod if you like: ZC Entity Information Features Village information is displayed when you are near a village. Message from the server indicating you are inside. outside, or not near a village. Calculated on the server side. Village center location (X Y Z), Village radius. Number of doors in the village. Number of villagers in the village. (Villager cap), Number of iron golems. (Golem cap) Your reputation in the village. Distance to the village center. Calculated on the client side. The time between each server tick. The value is in milliseconds. [*]Village information text color changes when you are inside the village. [*]When you look at a villager, details about that villager will be displayed. [*]Draws a line at the center of the village. [*]Draws a cuboid around the iron golem spawn area. [*]Draws a line at each door location. [*]Draws a line at each villager location. [*]Draws a sphere of dots around the village border. [*]Draws a cuboid around the World spawn area. Key Bindings O - Toggles Village information text. P - Toggles Center Lines and Border Sphere display. First press; Village center line and Golem spawn area. Second Press; Door center lines. Third Press; Border sphere. Forth Press; Display all. [*]L - Toggles Entity Center Lines First press; Villager center lines Second press; Golem center lines [*]K - Toggle World Spawn box First press; World spawn area Second press; Redstone stays functional area Third press; Entity's do not despawn area Forth press; Display All Commands "/villagedistance #" - If you are a level 4 OP you can issue the server command "/villagedistance #" to set the distance from the edge of a village before it is displayed to a player. The default is 128 blocks. Example: /villagedistance 128 Installation This is BETA. Use at your own risk. Copy the .jar file to the mods directory on both the client and server. Requirements 1.10.2 Compiled with Forge version: 1.10.2-12.18.1.2027 1.9.4 Compiled with Forge version: 1.9.4-12.17.0.1987 1.8.9 Compiled with Forge version: 1.8.9-11.15.1.1902-1.8.9 Images
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.