-
Posts
1689 -
Joined
-
Last visited
-
Days Won
1
Everything posted by SanAndreaP
-
Add -XX:PermSize=512m -XX:MaxPermSize=512m to your parameters and try again
-
Can't start custom modpack. MC Crashes.
SanAndreaP replied to socksmacguffin's topic in Support & Bug Reports
Update to 1.7+ as 1.6.4 is no longer supported, 9 months is long enough. -
First part: You need to create an Item class which extends ItemBlock and override addInformation in there. After that, bind this class to your block instance when registering your block with the GameRegistry: https://github.com/SanAndreasP/EnderStuffPlus/blob/master/java/de/sanandrew/mods/enderstuffplus/registry/ModBlockRegistry.java#L109-L111 Second, this:
-
Minecraft 1.7.10 cannot connect to the server
SanAndreaP replied to chunkkit's topic in Support & Bug Reports
Yes, it is necessary to have Forge installed on your client when connecting to a Forge-modded server (preferably the same version as the server). On the other hand, you can connect to a vanilla server with a Forge-modded client. The same goes for mods. You need the mods the server has on your client, but you can have more mods on your client than the server has (they simply aren't working in Multiplayer). Why? The Server does all the work. If the client does not know exactly what the server does / can do, then there will simply be discrepancies (for example the server includes a new hostile entity, client doesn't know because the mod isn't installed, Player gets killed by it and doesn't know why, because he couldn't see it). -
Look at this: http://www.minecraftforge.net/forum/index.php/topic,19692.msg99738.html#msg99738 It was a PITA to figure out everything, but it works quite well. I'll also do a PR when I get time.
-
[1.6.4]Effects On Collision With Custom Block Help?
SanAndreaP replied to RetsuWolf's topic in Modder Support
Check if the entity variable is an instance of the EntityLivingBase class and if true, cast to it, not to Object. -
I've included a hook in my coremod. I will do a PR however when I get time (by the way, it's a PITA to recode the horse armor stuff for horses, EVERYTHING is hardcoded in there). For anyone who's interested: Item class: https://github.com/SanAndreasP/SAPManagerPack/blob/master/java/de/sanandrew/core/manpack/util/ItemHorseArmor.java Transformer: https://github.com/SanAndreasP/SAPManagerPack/blob/master/java/de/sanandrew/core/manpack/transformer/TransformHorseArmor.java
-
[SOLVED] [1.6.4] Spawn custom EntityFX on server side
SanAndreaP replied to BlackCrafer666's topic in Modder Support
You need to send a packet. For tutorials on how, google it, there are a ton of tutorials out there. -
To control where the mob spawns, override getCanSpawnHere and return wheter it should spawn (true) or not (false) To check a radius, do this: Math.abs(spawnX - entityX) >= 500 && Math.abs(spawnZ - entityZ) >= 500 will check if it's not in a 500x500 squared perimeter around the spawn Math.sqrt(Math.pow(spawnX - entityX, 2) >= 500 && Math.pow(spawnZ - entityZ, 2)) >= 500 will check if it's not in a circle perimeter with radius 500 around the spawn (I think the math is right, don't count me on that, though)
-
You can use the TextureStitchEvent.Pre event to register a new icon independent of a block / an item. To do it, register to that event. You also need a field somewhere to hold the icon instance (e.g. public static IIcon sun ). Check if the texture type of the map (the map is a field in the event) represents the type of the icon. Check if it's 0 for blocks or 1 for items. Icon texture files registered as item icons belong next to the "actual" item icon files, same for blocks. Use map.registerIcon like you would register an icon in a block/item, like sun = event.map.registerIcon("enderstuffp:sun"); . After that, you can reference the field anywhere you see fit. No need for ResourceLocations here.
-
You could be more specific... All your Item/Block registration must go into the FMLPreInitializationEvent
-
[SOLVED] [1.7.2]Forge fails to initialize the game
SanAndreaP replied to Chocolate_with's topic in Modder Support
Remove the ${} in both, version and mcversion, since those characters aren't supposed to be there. Also I recommend the formatting "MCVERSION-MODVERSION" (e.g. "1.7.2-0.0.2a" - "a" is for alpha, "b" would be for beta) in your version field. -
Why not use the PlayerInteractEvent? Check if the type is RIGHT_CLICK_BLOCK and it'll have the block coords of the block right-clicked. Check if the player has flint and steel and do your custom code if all conditions are met.
-
[1.7.2] Block.blocksList [Update 1.6.4->1.7.2] Question
SanAndreaP replied to SantacreeperLP's topic in Modder Support
localBlock is never assigned to a value. Remove the definition of it and rename the id variable to localBlock -
Jup, using it for my custom ForgeGradle helper program: http://files.minecraftforge.net/maven/net/minecraftforge/forge/json
-
You should not learn Java by modding Minecraft. You will only learn things common in Minecraft, but if there's a problem, you don't know what to do (best example is this thread). I suggest read some basic Java tutorials and make a standalone program yourself first before attempt to mod Minecraft.
-
Partially wrong. You need to feed it the full qualified class name, which is the package path of the class with its name. rootpacket.subpacket.classname
-
Or, you know, just override moveFlying and call the super method with a different 3rd parameter: moveFlying(par1, par2, par3) { if isInWater then par3 = aCustomValue super.moveFlying(par1, par2, par3) } No need to copy-paste this monstrosity for a tiny change like this.
-
This was the case pre-1.7. Look here: http://puu.sh/8Sq6V.png Either there's something missing or the vanilla renderer has exceptions for specific blocks (like the stained glass) EDIT: looking at it again, if the renderBlockPass is > 0, it uses blend (look at the doRender method, line 124 in class RenderItem) BTW: Always add @Override to methods you intend to override! It shows you errors if you, for example, made a typo somewhere or the method signature changed.
-
[1.6.4] How to make mining code account for Silk Touch
SanAndreaP replied to hotrods20's topic in Modder Support
Use EnchantmentHelper#getEnchantmentLevel(enchId, itemStack) where enchId is the ID of the enchantment (e.g. Enchantment#fortune#effectId) and itemStack is the ItemStack you want to check (in your case the stack passed as parameter in your method). The method returns 0 if it isn't enchanted, else it returns the level of the enchantment. -
[SOLVED][1.6.4] Setting tile entity in unloaded chunk
SanAndreaP replied to target.san's topic in Modder Support
You need to override readFromNBT and writeToNBT and save/load you properties there. Also don't forget to call the super method! -
***looking for blast resistant ores MOD***
SanAndreaP replied to Mutagenic's topic in General Discussion
A mod like that is veeeeeery easy to make, you literally only need 1 class. But if you really don't wanna start learning java first, then I could make one really quick... -
Your pastebin was removed... also it's called authorsList