Jump to content

Recommended Posts

Posted (edited)

Hi,

 

So I was trying to make a custom entity and spawning it in the world and I had some trouble figuring out why the entity wasn't registered. Now it is and I can spawn it using "/summon" and with a spawn egg I made but it loads pretty much every minecraft png around my player and stays there. I'm guessing I have an issue with my entity model but can't find how to solve it.

 

If anyone can help I would be very greatfull, Thank you.

 

Here is my gitHub Repository.

 

This is my EntityInit,

this is my Entity,

this is my EntityRender,

this is my EntityModel,

this is my RenderHandler,

and this is my Main.

 

I don't really see any errors in the Logs whenever I try spawning the Entity but here they are anyways:

Details:
	Minecraft Version: 1.12.2
	Operating System: Windows 10 (amd64) version 10.0
	Java Version: 1.8.0_211, Oracle Corporation
	Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
	Memory: 852072136 bytes (812 MB) / 1038876672 bytes (990 MB) up to 1038876672 bytes (990 MB)
	JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M
	IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
	FML: 
	Loaded coremods (and transformers): 
	GL info: ' Vendor: 'ATI Technologies Inc.' Version: '4.5.13397 Compatibility Profile Context 15.200.1055.0' Renderer: 'AMD Radeon(TM) R3 Graphics'
[10:16:45] [main/INFO] [FML]: MinecraftForge v14.23.5.2768 Initialized
[10:16:45] [main/INFO] [FML]: Starts to replace vanilla recipe ingredients with ore ingredients.
[10:16:46] [main/INFO] [FML]: Replaced 1036 ore ingredients
[10:16:47] [main/INFO] [FML]: Searching C:\Users\Dan\Desktop\Minecraft Modding\PixelmonMod\run\.\mods for mods
[10:16:48] [Thread-3/INFO] [FML]: Using alternative sync timing : 200 frames of Display.update took 1219406462 nanos
[10:16:56] [main/INFO] [FML]: Forge Mod Loader has identified 5 mods to load
[10:16:58] [main/INFO] [FML]: Attempting connection with missing mods [minecraft, mcp, FML, forge, pm] at CLIENT
[10:16:58] [main/INFO] [FML]: Attempting connection with missing mods [minecraft, mcp, FML, forge, pm] at SERVER
[10:17:01] [main/INFO] [minecraft/SimpleReloadableResourceManager]: Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:Pixelmon Mod
[10:17:02] [main/INFO] [FML]: Processing ObjectHolder annotations
[10:17:02] [main/INFO] [FML]: Found 1168 ObjectHolder annotations
[10:17:02] [main/INFO] [FML]: Identifying ItemStackHolder annotations
[10:17:02] [main/INFO] [FML]: Found 0 ItemStackHolder annotations
[10:17:03] [main/INFO] [FML]: Configured a dormant chunk cache size of 0
[10:17:03] [Forge Version Check/INFO] [forge.VersionCheck]: [forge] Starting version check at http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions_slim.json
[10:17:03] [main/INFO] [FML]: OBJLoader: Domain pm has been added.
[10:17:03] [main/INFO] [FML]: Applying holder lookups
[10:17:03] [main/INFO] [FML]: Holder lookups applied
[10:17:03] [Forge Version Check/INFO] [forge.VersionCheck]: [forge] Found status: UP_TO_DATE Target: null
[10:17:03] [main/INFO] [FML]: Applying holder lookups
[10:17:03] [main/INFO] [FML]: Holder lookups applied
[10:17:03] [main/INFO] [FML]: Applying holder lookups
[10:17:03] [main/INFO] [FML]: Holder lookups applied
[10:17:04] [main/INFO] [FML]: Applying holder lookups
[10:17:04] [main/INFO] [FML]: Holder lookups applied
[10:17:04] [main/INFO] [FML]: Injecting itemstacks
[10:17:04] [main/INFO] [FML]: Itemstack injection complete
[10:17:23] [Sound Library Loader/INFO] [minecraft/SoundManager]: Starting up SoundSystem...
[10:17:24] [Thread-5/INFO] [minecraft/SoundManager]: Initializing LWJGL OpenAL
[10:17:24] [Thread-5/INFO] [minecraft/SoundManager]: (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)
[10:17:24] [Thread-5/INFO] [minecraft/SoundManager]: OpenAL initialized.
[10:17:24] [Sound Library Loader/INFO] [minecraft/SoundManager]: Sound engine started
[10:18:09] [main/INFO] [FML]: Max texture size: 16384
[10:18:12] [main/WARN] [minecraft/TextureMap]: Texture pm:textures/items/pokeballs/pokeball/greatball.png with size 18x18 will have visual artifacts at mip level 4, it can only support level 1. Please report to the mod author that the texture should be some multiple of 16x16.
[10:18:13] [main/WARN] [minecraft/TextureMap]: Texture pm:textures/items/pokeballs/pokeball/ultraball.png with size 18x18 will have visual artifacts at mip level 4, it can only support level 1. Please report to the mod author that the texture should be some multiple of 16x16.
[10:18:15] [main/INFO] [minecraft/TextureMap]: Created: 512x512 textures-atlas
[10:18:18] [main/WARN] [minecraft/ModelBlock]: Unable to resolve texture due to upward reference: #all in minecraft:models/block/cube_all
[10:18:21] [main/WARN] [minecraft/ModelBlock]: Unable to resolve texture due to upward reference: #all in minecraft:models/block/cube_all
[10:18:26] [main/INFO] [FML]: Applying holder lookups
[10:18:26] [main/INFO] [FML]: Holder lookups applied
[10:18:26] [main/INFO] [FML]: Injecting itemstacks
[10:18:26] [main/INFO] [FML]: Itemstack injection complete
[10:18:27] [main/INFO] [FML]: Forge Mod Loader has successfully loaded 5 mods
[10:18:27] [main/WARN] [minecraft/GameSettings]: Skipping bad option: lastServer:
[10:18:27] [main/INFO] [mojang/NarratorWindows]: Narrator library for x64 successfully loaded
[10:18:30] [Realms Notification Availability checker #1/INFO] [mojang/RealmsClient]: Could not authorize you against Realms server: Invalid session id
[10:21:36] [Server thread/INFO] [minecraft/IntegratedServer]: Starting integrated minecraft server version 1.12.2
[10:21:36] [Server thread/INFO] [minecraft/IntegratedServer]: Generating keypair
[10:21:37] [Server thread/INFO] [FML]: Injecting existing registry data into this server instance
[10:21:38] [Server thread/INFO] [FML]: Registry Block: Found a missing id from the world pm:ore_nether
[10:21:38] [Server thread/INFO] [FML]: Registry Block: Found a missing id from the world pm:ore_overworld
[10:21:38] [Server thread/INFO] [FML]: Registry Block: Found a missing id from the world pm:ore_end
[10:21:41] [Server thread/INFO] [FML]: Applying holder lookups
[10:21:41] [Server thread/INFO] [FML]: Holder lookups applied
[10:21:44] [Server thread/INFO] [FML]: Loading dimension 0 (New World) (net.minecraft.server.integrated.IntegratedServer@5cb11b48)
[10:21:48] [Server thread/INFO] [minecraft/AdvancementList]: Loaded 488 advancements
[10:21:48] [Server thread/INFO] [FML]: Loading dimension -1 (New World) (net.minecraft.server.integrated.IntegratedServer@5cb11b48)
[10:21:49] [Server thread/INFO] [FML]: Loading dimension 1 (New World) (net.minecraft.server.integrated.IntegratedServer@5cb11b48)
[10:21:49] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing start region for level 0
[10:21:52] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing spawn area: 0%
[10:21:53] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing spawn area: 16%
[10:21:54] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing spawn area: 34%
[10:21:55] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing spawn area: 50%
[10:21:56] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing spawn area: 67%
[10:21:57] [Server thread/INFO] [minecraft/MinecraftServer]: Preparing spawn area: 85%
[10:21:59] [Server thread/INFO] [FML]: Unloading dimension -1
[10:21:59] [Server thread/INFO] [FML]: Unloading dimension 1
[10:21:59] [Server thread/INFO] [minecraft/IntegratedServer]: Changing view distance to 2, from 10
[10:22:09] [Netty Local Client IO #0/INFO] [FML]: Server protocol version 2
[10:22:09] [Netty Server IO #1/INFO] [FML]: Client protocol version 2
[10:22:09] [Netty Server IO #1/INFO] [FML]: Client attempting to join with 5 mods : [email protected],[email protected],[email protected],[email protected],[email protected]
[10:22:09] [Server thread/WARN] [minecraft/MinecraftServer]: Can't keep up! Did the system time change, or is the server overloaded? Running 2398ms behind, skipping 47 tick(s)
[10:22:09] [Netty Local Client IO #0/INFO] [FML]: [Netty Local Client IO #0] Client side modded connection established
[10:22:09] [Server thread/INFO] [FML]: [Server thread] Server side modded connection established
[10:22:09] [Server thread/INFO] [minecraft/PlayerList]: Player459[local:E:00bc6c5e] logged in with entity id 197 at (224.7461617830892, 64.0, 213.11517458230804)
[10:22:09] [Server thread/INFO] [minecraft/MinecraftServer]: Player459 joined the game
[10:22:17] [Server thread/INFO] [minecraft/IntegratedServer]: Saving and pausing game...
[10:22:25] [Server thread/INFO] [minecraft/MinecraftServer]: Saving chunks for level 'New World'/overworld
[10:22:26] [pool-2-thread-1/WARN] [mojang/YggdrasilMinecraftSessionService]: Couldn't look up profile properties for com.mojang.authlib.GameProfile@15ee4109[id=9e4b41fd-b698-3086-96f0-585499a2673a,name=Player459,properties={},legacy=false]
com.mojang.authlib.exceptions.AuthenticationException: The client has sent too many requests within a certain amount of time
	at com.mojang.authlib.yggdrasil.YggdrasilAuthenticationService.makeRequest(YggdrasilAuthenticationService.java:79) ~[YggdrasilAuthenticationService.class:?]
	at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService.fillGameProfile(YggdrasilMinecraftSessionService.java:180) [YggdrasilMinecraftSessionService.class:?]
	at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService$1.load(YggdrasilMinecraftSessionService.java:60) [YggdrasilMinecraftSessionService$1.class:?]
	at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService$1.load(YggdrasilMinecraftSessionService.java:57) [YggdrasilMinecraftSessionService$1.class:?]
	at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3716) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2424) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2298) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2211) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache.get(LocalCache.java:4154) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4158) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5147) [guava-21.0.jar:?]
	at com.google.common.cache.LocalCache$LocalLoadingCache.getUnchecked(LocalCache.java:5153) [guava-21.0.jar:?]
	at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService.fillProfileProperties(YggdrasilMinecraftSessionService.java:170) [YggdrasilMinecraftSessionService.class:?]
	at net.minecraft.client.Minecraft.getProfileProperties(Minecraft.java:3181) [Minecraft.class:?]
	at net.minecraft.client.resources.SkinManager$3.run(SkinManager.java:138) [SkinManager$3.class:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [?:1.8.0_211]
	at java.util.concurrent.FutureTask.run(Unknown Source) [?:1.8.0_211]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [?:1.8.0_211]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [?:1.8.0_211]
	at java.lang.Thread.run(Unknown Source) [?:1.8.0_211]
[10:22:28] [main/INFO] [minecraft/AdvancementList]: Loaded 2 advancements
[10:22:31] [Server thread/WARN] [minecraft/MinecraftServer]: Can't keep up! Did the system time change, or is the server overloaded? Running 2959ms behind, skipping 59 tick(s)
[10:22:32] [Server thread/INFO] [minecraft/IntegratedServer]: Saving and pausing game...
[10:22:33] [Server thread/INFO] [minecraft/MinecraftServer]: Saving chunks for level 'New World'/overworld
[10:32:00] [Server thread/INFO] [minecraft/IntegratedServer]: Saving and pausing game...
[10:32:00] [Server thread/INFO] [minecraft/MinecraftServer]: Saving chunks for level 'New World'/overworld

 

And this is what it looks like in game:

 

 

2019-04-26_10.33.13.png

2019-04-26_10.33.20.png

Edited by Thegametutor101
Posted
13 hours ago, V0idWa1k3r said:

This is the method you need to call to bind the texture and you need to do this before rendering the model

It still doesn't work.. Am I doing it correctly?

 

	@Override
	protected boolean bindEntityTexture(P25Pikachu entity) {
		return super.bindEntityTexture(entity);
	}

 

Posted
3 hours ago, V0idWa1k3r said:

I explicitly told you NOT to override the method, but CALL it before rendering the model, yet you decide to override it anyway and not call it

Oh..sorry you didn't say not to override it..but ok i'll change it.

So do I leave it as is and simply remove the Override tag?

Posted (edited)
On 4/27/2019 at 6:17 PM, V0idWa1k3r said:

This is the method you need to call to bind the texture and you need to do this before rendering the model

This means "call the method; that's it".

You were not told to override anything at any point.

 

25 minutes ago, Thegametutor101 said:

So do I leave it as is and simply remove the Override tag?

That would still be overriding the method.

Delete your bindEntityTexture completely.

Call the already existing method before you render the model.

 

Unrelated:

10 hours ago, Thegametutor101 said:

 


	@Override
	protected boolean bindEntityTexture(P25Pikachu entity) {
		return super.bindEntityTexture(entity);
	}

 

This does nothing, as you are basically returning the result from the super method.

The point of overriding is to do something different from its super method.

Edited by DavidM

Some tips:

Spoiler

Modder Support:

Spoiler

1. Do not follow tutorials on YouTube, especially TechnoVision (previously called Loremaster) and HarryTalks, due to their promotion of bad practice and usage of outdated code.

2. Always post your code.

3. Never copy and paste code. You won't learn anything from doing that.

4. 

Quote

Programming via Eclipse's hotfixes will get you nowhere

5. Learn to use your IDE, especially the debugger.

6.

Quote

The "picture that's worth 1000 words" only works if there's an obvious problem or a freehand red circle around it.

Support & Bug Reports:

Spoiler

1. Read the EAQ before asking for help. Remember to provide the appropriate log(s).

2. Versions below 1.11 are no longer supported due to their age. Update to a modern version of Minecraft to receive support.

 

 

Posted
2 minutes ago, DavidM said:

This means "call the method; that's it".

You were not told to override anything at any point.

 

That would still be overriding the method.

Delete your bindEntityTexture completely.

Call the already existing method before you render the model.

 

Unrelated:

This does nothing, as you are basically returning the result from the super method.

But that was the already existing method I don't understand what you mean..?

What do I replace it by exactly? 

Could you show me how, please?

Posted

@DavidM

Ok so now am I doing it correctly?

    @Override
    public void doRender(P25Pikachu entity, double x, double y, double z, float entityYaw, float partialTicks) {
    	bindEntityTexture(entity);
    	bindTexture(TEXTURES);
        model.render(entity, 0F, 0F, 0F, 0F, 0F, 1F);
    }

this is in my renderEntity Class..

Posted
On 4/27/2019 at 6:17 AM, V0idWa1k3r said:

This is the method you need to call to bind the texture and you need to do this before rendering the model

@V0idWa1k3r It worked!! Really sorry if I annoyed you..Thank you!

Took me some time to understand but now the model is loading completely and with the correct texture! Thank you!

 

I was wondering if you knew a post that talks about using a .obj model for the entity.. That's my next objective! :)

Again sorry if I was rude before, i really wasn't sure what to do..

 

    @Override
    public void doRender(P25Pikachu entity, double x, double y, double z, float entityYaw, float partialTicks) {
    	GlStateManager.pushMatrix();
		GlStateManager.translate(x, y, z);
		GlStateManager.rotate(180, 1, 0, 0);
        GlStateManager.rotate(entity.rotationPitch, 1, 0, 0);
		GlStateManager.translate(0, -1.5, 0);
		this.bindEntityTexture(entity);
		this.model.render(entity, 0.0F, 0.0F, -0.1F, entity.rotationYaw, entity.rotationPitch, 0.0625F);
		GlStateManager.popMatrix();
		super.doRender(entity, x, y, z, entityYaw, partialTicks);
    }

 

2019-04-30_13.04.42.png

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Im trying to build my mod using shade since i use the luaj library however i keep getting this error Reason: Task ':reobfJar' uses this output of task ':shadowJar' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. So i try adding reobfJar.dependsOn shadowJar  Could not get unknown property 'reobfJar' for object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler. my gradle file plugins { id 'eclipse' id 'idea' id 'maven-publish' id 'net.minecraftforge.gradle' version '[6.0,6.2)' id 'com.github.johnrengelman.shadow' version '7.1.2' id 'org.spongepowered.mixin' version '0.7.+' } apply plugin: 'net.minecraftforge.gradle' apply plugin: 'org.spongepowered.mixin' apply plugin: 'com.github.johnrengelman.shadow' version = mod_version group = mod_group_id base { archivesName = mod_id } // Mojang ships Java 17 to end users in 1.18+, so your mod should target Java 17. java.toolchain.languageVersion = JavaLanguageVersion.of(17) //jarJar.enable() println "Java: ${System.getProperty 'java.version'}, JVM: ${System.getProperty 'java.vm.version'} (${System.getProperty 'java.vendor'}), Arch: ${System.getProperty 'os.arch'}" minecraft { mappings channel: mapping_channel, version: mapping_version copyIdeResources = true runs { configureEach { workingDirectory project.file('run') property 'forge.logging.markers', 'REGISTRIES' property 'forge.logging.console.level', 'debug' arg "-mixin.config=derp.mixin.json" mods { "${mod_id}" { source sourceSets.main } } } client { // Comma-separated list of namespaces to load gametests from. Empty = all namespaces. property 'forge.enabledGameTestNamespaces', mod_id } server { property 'forge.enabledGameTestNamespaces', mod_id args '--nogui' } gameTestServer { property 'forge.enabledGameTestNamespaces', mod_id } data { workingDirectory project.file('run-data') args '--mod', mod_id, '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/') } } } sourceSets.main.resources { srcDir 'src/generated/resources' } repositories { flatDir { dirs './libs' } maven { url = "https://jitpack.io" } } configurations { shade implementation.extendsFrom shade } dependencies { minecraft "net.minecraftforge:forge:${minecraft_version}-${forge_version}" implementation 'org.luaj:luaj-jse-3.0.2' implementation fg.deobf("com.github.Virtuoel:Pehkui:${pehkui_version}") annotationProcessor 'org.spongepowered:mixin:0.8.5:processor' minecraftLibrary 'luaj:luaj-jse:3.0.2' shade 'luaj:luaj-jse:3.0.2' } // Example for how to get properties into the manifest for reading at runtime. tasks.named('jar', Jar).configure { manifest { attributes([ 'Specification-Title' : mod_id, 'Specification-Vendor' : mod_authors, 'Specification-Version' : '1', // We are version 1 of ourselves 'Implementation-Title' : project.name, 'Implementation-Version' : project.jar.archiveVersion, 'Implementation-Vendor' : mod_authors, 'Implementation-Timestamp': new Date().format("yyyy-MM-dd'T'HH:mm:ssZ"), "TweakClass" : "org.spongepowered.asm.launch.MixinTweaker", "TweakOrder" : 0, "MixinConfigs" : "derp.mixin.json" ]) } rename 'mixin.refmap.json', 'derp.mixin-refmap.json' } shadowJar { archiveClassifier = '' configurations = [project.configurations.shade] finalizedBy 'reobfShadowJar' } assemble.dependsOn shadowJar reobf { re shadowJar {} } publishing { publications { mavenJava(MavenPublication) { artifact jar } } repositories { maven { url "file://${project.projectDir}/mcmodsrepo" } } }  
    • All versions of Minecraft Forge suddenly black screen even without mods (tried reinstalling original Minecraft, Java, updating drivers doesn't work)
    • When i join minecraft all ok, when i join world all working fine, but when i open indentity menu, i get this The game crashed whilst unexpected error Error: java.lang.NullPointerException: Cannot invoke "top.ribs.scguns.common.Gun$Projectile.getDamage()" because "this.projectile" is null crash report here https://paste.ee/p/0vKaf
  • Topics

×
×
  • Create New...

Important Information

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