Everything posted by Ernio
-
Mod not working on Server
If you could just give error log, would be helpful ;p
-
[1.8] everyting has become white and green, is a limit for textures ?<Solved>
I'd go with standard debugging procedure. Comment out everything in your mod (at most basic level - registy) and add one after another. 1st I'd check events (if you use any) then go with item registration and rendering. There is not much to say to help you, are you sure you are not using anything in RenderGameOverlay? How are you drawing your gui?
-
[1.8] Rendering Projectile? [Solved]
No wonder if you are putting NULL to RenderItem: Code: public RenderSnowball(RenderManager p_i46137_1_, Item p_i46137_2_, RenderItem p_i46137_3_) You: new RenderSnowball(Minecraft.getMinecraft().getRenderManager(), ItemReg.bomb, null) You need to Minecraft.getMinecraft().getRenderItem()
-
[1.8] everyting has become white and green, is a limit for textures ?<Solved>
You must have done something REALLY bad in rendering code. What rendering events are you using? Codes? Probably forgot to reset GL state or some blending mode.
-
[1.7.10][Solved] Cancel mouse input possible?
On client? MouseEvent and event.setCanceled()
-
Messages
Chat message? player.addChatMessage(new ChatComponentText("Text")); or any other component.
-
[1.7.10] Lighting glitch with Hovering Text
Make sure you are enabling/disabling all GL states to state they should be (were before drawing). I'd need code to tell you exacly where (it's all about order).
-
Disabling keyboard and mouse
I know you are very HAPPY to KILL, but that doesn't mean you need to DESTROY everything My input: Better use events (as diesieben said).
-
[SOLVED] Detect if you hit a player (Client mod)
I was looking into it some time ago, so it might have been changed, but it might be the server that actually decides about your attack. Cancelling it on client won't do anything since server still receives packet that you clicked mouse in particular direction, and the server will manage that click on it's own, so you will still attack. You would have to intercept MouseEvent get entity under mouse (MovingObjectPosition I think) and cancel MouseEvent client-side before anything happens.
-
[1.8][CLOSED] Is IExtendedEntityPorperties disallowing using SideOnly?
"there is nothing wrong with you using it, provided with you knowing what you are doing." I know how it works, I simply don't want to store useless values on server side. SanAndreas - this is exacly what I needed to know (that you can't initialize those values). This closes issue
-
[1.8][CLOSED] Is IExtendedEntityPorperties disallowing using SideOnly?
Consider this: I am using per-entity client value to make per-entity smooth health bar transition. Clearly getting error: Caused by: java.lang.NoSuchFieldError: lastTickHealth When mod is ran on Dedicated server (on client works just fine). My question is - what "fact" (piece of code) is not allowin this to be? IEEP clearly doesn't like SideOnly, but why? EDIT: Oh and SideOnly on methods is perfectly fine, IEEP only crashes when SideOnly is used on FIELDS (like in exception I have above).
-
[1.7.10][SOLVED] Deal damage to an entity
Damagesource is damagesource: target.attackEntityFrom(DamageSource.fall, 10.0F); This will deal 10 fall damage. You can use vanilla damagesources or make your own.
-
[1.7.10] How to render a gui over another gui?
Main idea is: You save fields inside your own storage (event class for example). Initialize them inside GuiScreenEvent.InitGuiEvent by checking if event.gui is instance of gui desired. And then draw those elements in GuiScreenEvent.DrawScreenEvent, do button actions in GuiScreenEvent.ActionPerformedEvent.
-
[1.7.10][SOLVED] Deal damage to an entity
I didn't read your code, BUT: You don't need events for CUSTOM things, events are to change vanilla behaviour. If you have your own sword class (which I assume you do) you can override a method hitEntity(ItemStack stack, EntityLivingBase target, EntityLivingBase attacker). Oh, and since that doesn't answer your main question, here it is: target.attackEntityFrom(source, amount)
-
minecraft source
I have no idea what you are talking about. I am almost certain you setup your workspace incorrectly: Check this out: http://www.minecraftforge.net/forum/index.php/topic,14048.0.html#post_update_forge Short: Download forge src and run setupDecompWorkspace then eclipse (or other)
-
[1.7.10] Get client's locale
61352151511 Thanks, that removes one packet and command from my mod The more you know. First time I saw someone correcting Diesieben
-
[1.7.10] [solved] How would you get an entities UUID to persist after setDead
The statement should be other way around: When entity is setDead() the instance is being removed and it's NBT won't be saved to world's data. Could you please provide FULL code. Github would be nice. SAving data to something that won't be saved is radical and will not work.
-
[1.8][SOLVED]Memory leaking
On server you can cast EntityPlayer to MP. On client you use Minecraft.getMinecraft() instead. (obvious unnecessity is obvious).
-
[1.8] is this mod causing lag when run in server ??
Reading your posts always leaves me thinking - who taught you english (because of gramma) Anyway - to test mod you can simply launcher offline mode server and 2 clients from your eclipse (with different nicks). As to your guns - you are probably not using NBT values, but Item singleton values or using some packets that cause everything to screw up. Remember - never use global values if you want effect to be per-player.
-
[1.8][SOLVED]Memory leaking
What you did is really unnecessary and shouldn't be done. It's literally reinventing the wheel. Use IMessage and MessageHandlers. Diesiebens tutorial covers it perfectly. For some examples and explanation (longer tut) http://www.minecraftforum.net/forums/mapping-and-modding/mapping-and-modding-tutorials/2137055-1-7-x-1-8-customizing-packet-handling-with
-
[1.7.10] How do I create a status effect?
Well, if you don't want to use PotionEffect then you will certainly need to make your own. Obviously - subscribe to events that suppost to launch your effect - e.g player tick, make IEEP which will hold map of effects and run them everytime you want. For fatigue - probably subscribe to some mining speed event, check there if IEEP of given player has your effect and increast time needed to mine block.
-
Base code editing
Forge will ONLY run on clean version of MC. Using Forge = only base edits you can do is ASM/Reflection. If you want to make a private mod you can simply setup an MCP without forge, but then it will be not compatybile with Forge (obviously).
-
[1.8] Can't get value from entity
http://www.minecraftforum.net/forums/mapping-and-modding/mapping-and-modding-tutorials/2137055-1-7-2-customizing-packet-handling-with OR simple/short: http://www.minecraftforge.net/forum/index.php/topic,20135.0.html IMPORTANT In 1.8 there are 4 threads (not 2 like in pre-1.. Server, Client and two netty (for server and client). Because of that you might have problems if e.g server constructs entity and will send packet to client, but client won't be able to apply changes on entity because it hasn't constructed it yet. To avoid that create new Runnable and throw it into mc main thread: Minecraft.getMinecraft().addScheduledTask(Runnable);
-
[1.8] [SOLVED] Creating entities renderer requires RenderManager. Where?
You don't need .json - this is if you wanted to make some models maybe. You need to learn OpenGL. This is strictly java, not forge stuff, so without proper preparation I wouldn't ask here for others to write code for you. If you don't want to you can copy arrow and bind its textures to your own, OR just use arrow renderer.
-
How to make data 'visible' to all players
http://www.minecraftforum.net/forums/mapping-and-modding/mapping-and-modding-tutorials/2137055-1-7-2-customizing-packet-handling-with Probably all you need to know. Also - to store data about player - use IEEP: (2nd post in thread): http://www.minecraftforum.net/forums/mapping-and-modding/mapping-and-modding-tutorials/1571567-1-7-2-1-6-4-eventhandler-and
IPS spam blocked by CleanTalk.