Skip to content

Commit

Permalink
Eliminate raw OpenGL calls
Browse files Browse the repository at this point in the history
  • Loading branch information
ACGaming committed Oct 6, 2024
1 parent cf6491c commit 40ce4f7
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
package com.progwml6.natura.library.client.renderer.monster;

import org.lwjgl.opengl.GL11;

import com.progwml6.natura.entities.entity.monster.EntityBabyHeatscarSpider;
import com.progwml6.natura.library.Util;

import net.minecraft.client.model.ModelSpider;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.client.renderer.entity.RenderLiving;
import net.minecraft.client.renderer.entity.RenderManager;
import net.minecraft.util.ResourceLocation;
Expand Down Expand Up @@ -37,6 +36,6 @@ protected ResourceLocation getEntityTexture(EntityBabyHeatscarSpider entity)
@Override
protected void preRenderCallback(EntityBabyHeatscarSpider entity, float partialTickTime)
{
GL11.glScalef(0.85f, 0.85f, 0.85f);
GlStateManager.scale(0.85f, 0.85f, 0.85f);
}
}
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
package com.progwml6.natura.library.client.renderer.monster;

import org.lwjgl.opengl.GL11;

import com.progwml6.natura.entities.entity.monster.EntityHeatscarSpider;
import com.progwml6.natura.library.Util;

import net.minecraft.client.model.ModelSpider;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.client.renderer.entity.RenderLiving;
import net.minecraft.client.renderer.entity.RenderManager;
import net.minecraft.util.ResourceLocation;
Expand Down Expand Up @@ -37,6 +36,6 @@ protected ResourceLocation getEntityTexture(EntityHeatscarSpider entity)
@Override
protected void preRenderCallback(EntityHeatscarSpider entity, float partialTickTime)
{
GL11.glScalef(2.0F, 2.0F, 2.0F);
GlStateManager.scale(2.0F, 2.0F, 2.0F);
}
}
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
package com.progwml6.natura.library.client.renderer.passive;

import org.lwjgl.opengl.GL11;

import com.progwml6.natura.entities.entity.passive.EntityImp;
import com.progwml6.natura.library.client.model.passive.ModelImp;
import com.progwml6.natura.library.Util;

import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.client.renderer.entity.RenderLiving;
import net.minecraft.client.renderer.entity.RenderManager;
import net.minecraft.util.ResourceLocation;
Expand Down Expand Up @@ -37,6 +36,6 @@ protected ResourceLocation getEntityTexture(EntityImp entity)
@Override
protected void preRenderCallback(EntityImp entity, float partialTickTime)
{
if (entity.isChild()) GL11.glScalef(0.5F, 0.5F, 0.5F);
if (entity.isChild()) GlStateManager.scale(0.5F, 0.5F, 0.5F);
}
}

0 comments on commit 40ce4f7

Please sign in to comment.