finkOS Posted December 7, 2009 Posted December 7, 2009 How to make npc what it attacked faction? (l2jserver gracia final) Tried to put in L2AttackableAi.java: if (target instanceof L2PcInstance && ((L2PcInstance) target).getFactionId () != 1) if (target instanceof L2PcInstance && ((L2PcInstance) target).getFactionId () == 1) But npc all the same does not attack. I use faction mod by Laikeriz
0 finkOS Posted December 8, 2009 Author Posted December 8, 2009 please help.Really not who does not know as to make?
0 Intrepid Posted December 8, 2009 Posted December 8, 2009 you want an npc which take agro effect against a type of faction right?
0 finkOS Posted December 8, 2009 Author Posted December 8, 2009 yes. I would want that they stood on spawn to a zone and did not allow to kill players at once
0 Intrepid Posted December 8, 2009 Posted December 8, 2009 to have that you need to edit the ai i guess or the L2GuardInstance pm to horus he have something like that so maybe he can help you
0 Horus Posted December 8, 2009 Posted December 8, 2009 Make a new instance. Make a new KnownList for that Instance and make it only add targets who are on the opposite faction. Also change the boolean isAutoAttackable.
0 finkOS Posted December 8, 2009 Author Posted December 8, 2009 Tried that that to make hour so there is nothing and did not leave. I do not know java = \
0 Horus Posted December 8, 2009 Posted December 8, 2009 Sorry. I'm here to help not to give you free features. If you want to make a Faction based Server than I advice you to learn Java.
0 Setekh Posted December 9, 2009 Posted December 9, 2009 Sorry. I'm here to help not to give you free features. If you want to make a Faction based Server than I advice you to learn Java. -beep- Yeah xD Anyway its easyer to do this from attackable ai ^^
0 Horus Posted December 9, 2009 Posted December 9, 2009 -beep- Yeah xD Anyway its easyer to do this from attackable ai ^^ Yes it is. I adviced him to change the KnownList so that he could understand a bit better how NPCs work ^^ But he ain't going to do it so lool..
0 finkOS Posted December 10, 2009 Author Posted December 10, 2009 Make a new instance. Make a new KnownList for that Instance and make it only add targets who are on the opposite faction. Also change the boolean isAutoAttackable. Many thanks! Thanks to your helps I have made that that wanted! The theme can be closed
Question
finkOS
How to make npc what it attacked faction? (l2jserver gracia final)
Tried to put in L2AttackableAi.java:
if (target instanceof L2PcInstance && ((L2PcInstance) target).getFactionId () != 1)
if (target instanceof L2PcInstance && ((L2PcInstance) target).getFactionId () == 1)
But npc all the same does not attack. I use faction mod by Laikeriz
12 answers to this question
Recommended Posts