Fixed some scripted item events, and fixed positioning of scripted items.

This commit is contained in:
Luis C.M committed 2022-05-11 13:30:13 -05:00
1 parent 747730face
commit 11cc46b48f
20 files changed
+231 -146

No files matched your search

@@ -2,6 +2,7 @@ package noppes.npcs.scripted.event;
import net.minecraft.entity.player.EntityPlayer;
import noppes.npcs.controllers.Dialog;
import noppes.npcs.controllers.ScriptController;
import noppes.npcs.scripted.NpcAPI;
import noppes.npcs.scripted.interfaces.IPlayer;
@@ -12,7 +13,7 @@ public class ScriptEventDialog extends ScriptEvent{
public Dialog dialogObj;
public ScriptEventDialog(EntityPlayer player, int dialog, int option, Dialog dialogObj){
this.player = (IPlayer)NpcAPI.Instance().getIEntity(player);
this.player = (IPlayer) ScriptController.Instance.getScriptForEntity(player);
this.dialog = dialog;
this.option = option;
this.dialogObj = dialogObj;