[Suggestion] Trying to make mts compact with CustomNPCs
Woody-0w0 opened this issue · 5 comments
Im trying to make mts compact with CustomNPCs
change code in ItemTicket.class as below:
public boolean func_111207_a(final ItemStack stack, final EntityPlayer player, final EntityCustomNpc target, final EnumHand hand) {
if (!player.field_70170_p.field_72995_K && hand.equals((Object)EnumHand.MAIN_HAND)) {
if (target instanceof EntityCustomNpc && target instanceof EntityCustomNpc) {
final NBTTagCompound tag = new NBTTagCompound();
tag.func_74768_a("entityID", target.func_145782_y());
player.func_184614_ca().func_77982_d(tag);
WrapperNetwork.sendToPlayer((APacketBase)new PacketPlayerChatMessage("interact.ticket.linked"), (EntityPlayerMP)player);
}
else {
WrapperNetwork.sendToPlayer((APacketBase)new PacketPlayerChatMessage("interact.ticket.notnpc"), (EntityPlayerMP)player);
}
}
return true;
}
but it dont work.
click on EntityCustomNpc with ticket make nothing happen
can anyone help?
by the way
change "INpc" to "EntityLiving" can make pigs sat on car, interesting.
but this method seems not applicable to EntityCustomNpc as entities in Mods
Not sure what that code does, as you have all the names obfuscated. I haven't seen code like that since 1.5... I'm pretty sure CNPCs extend iNPC, but I also know that when you click a CNPC, no matter what, they open their GUI and don't do item code. I'm changing how tickets work in V19, so this issue will likely be moot, but we shall see.
@Woody-0w0 So V19 dropped, can you check if the new ticket system works? As to other entities, you can actually make animals sit in vehicles via a lead. Just lead em up and click the seat to put em in.
@Jimmy805 Not sure where you heard that. ;) That being said, I do eventually need to get this guy out of 1.12.2, and 1.15 seems like a good starting place. That being said, I don't plan on dropping 1.12.2. Not for a while, anyways. I have some crafty ways to get out of having to worry about such things, provided they work. If you can't log-in to Curse, there's always the Discord. I'm far more active on there. Though if you really want to log-in to Curse, try logging in to Twitch first. I can never get Curse to work for me out of the box, but if I'm logged-in to Twitch, then it seems to behave.
Hello DonBruce! I'm very glad to see your update in V19! You worked hard. By the way, I heard that you will update this mod to 1.15, so I wonder if you will continue to update the version of 1.12 in the future?( I'm sorry to ask you here but I can't log in curseforge, though I can enter the curseforge)