當前位置: 首頁>>代碼示例>>Java>>正文


Java RenderGameOverlayEvent.Chat方法代碼示例

本文整理匯總了Java中net.minecraftforge.client.event.RenderGameOverlayEvent.Chat方法的典型用法代碼示例。如果您正苦於以下問題:Java RenderGameOverlayEvent.Chat方法的具體用法?Java RenderGameOverlayEvent.Chat怎麽用?Java RenderGameOverlayEvent.Chat使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在net.minecraftforge.client.event.RenderGameOverlayEvent的用法示例。


在下文中一共展示了RenderGameOverlayEvent.Chat方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: renderChat

import net.minecraftforge.client.event.RenderGameOverlayEvent; //導入方法依賴的package包/類
protected void renderChat(int width, int height)
{
    mc.mcProfiler.startSection("chat");

    RenderGameOverlayEvent.Chat event = new RenderGameOverlayEvent.Chat(eventParent, 0, height - 48);
    if (MinecraftForge.EVENT_BUS.post(event)) return;

    GlStateManager.pushMatrix();
    GlStateManager.translate((float) event.getPosX(), (float) event.getPosY(), 0.0F);
    persistantChatGUI.drawChat(updateCounter);
    GlStateManager.popMatrix();

    post(CHAT);

    mc.mcProfiler.endSection();
}
 
開發者ID:F1r3w477,項目名稱:CustomWorldGen,代碼行數:17,代碼來源:GuiIngameForge.java

示例2: renderChat

import net.minecraftforge.client.event.RenderGameOverlayEvent; //導入方法依賴的package包/類
protected void renderChat(int width, int height)
{
    field_73839_d.field_71424_I.func_76320_a("chat");

    RenderGameOverlayEvent.Chat event = new RenderGameOverlayEvent.Chat(eventParent, 0, height - 48);
    if (MinecraftForge.EVENT_BUS.post(event)) return;

    GL11.glPushMatrix();
    GL11.glTranslatef((float)event.posX, (float)event.posY, 0.0F);
    field_73840_e.func_146230_a(field_73837_f);
    GL11.glPopMatrix();

    post(CHAT);

    field_73839_d.field_71424_I.func_76319_b();
}
 
開發者ID:SchrodingersSpy,項目名稱:TRHS_Club_Mod_2016,代碼行數:17,代碼來源:GuiIngameForge.java

示例3: renderChat

import net.minecraftforge.client.event.RenderGameOverlayEvent; //導入方法依賴的package包/類
protected void renderChat(int width, int height)
{
    mc.mcProfiler.startSection("chat");

    RenderGameOverlayEvent.Chat event = new RenderGameOverlayEvent.Chat(eventParent, 0, height - 48);
    if (MinecraftForge.EVENT_BUS.post(event)) return;

    GL11.glPushMatrix();
    GL11.glTranslatef((float)event.posX, (float)event.posY, 0.0F);
    persistantChatGUI.drawChat(updateCounter);
    GL11.glPopMatrix();

    post(CHAT);

    mc.mcProfiler.endSection();
}
 
開發者ID:alexandrage,項目名稱:CauldronGit,代碼行數:17,代碼來源:GuiIngameForge.java

示例4: onRenderGameOverlay

import net.minecraftforge.client.event.RenderGameOverlayEvent; //導入方法依賴的package包/類
@SubscribeEvent
public void onRenderGameOverlay(RenderGameOverlayEvent.Chat event) {
	Minecraft mc = Minecraft.getMinecraft();
	if (mc.player != null && isKnockedOut && mc.currentScreen != null) {
		prevChatHeight = mc.gameSettings.chatHeightFocused;
		mc.gameSettings.chatHeightFocused = 0.1f;
	}
}
 
開發者ID:blay09,項目名稱:HardcoreRevival,代碼行數:9,代碼來源:ClientProxy.java

示例5: chatEvent

import net.minecraftforge.client.event.RenderGameOverlayEvent; //導入方法依賴的package包/類
@SubscribeEvent
public static void chatEvent(RenderGameOverlayEvent.Chat event)
{
	if(gui != null && !Minecraft.getMinecraft().player.isCreative())
	{
		event.setPosY(event.getPosY() - 10);
	}
}
 
開發者ID:Lemonszz,項目名稱:Anima-Mundi,代碼行數:9,代碼來源:GuiShield.java


注:本文中的net.minecraftforge.client.event.RenderGameOverlayEvent.Chat方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。