Veille and Mastarius / Ingg / Gelk Bosses should be giving GP after they died but the player just get AP.
How can i add GP to these bosses??
Thx already for any help!
Imgur: The most awesome images on the Internet
Veille and Mastarius / Ingg / Gelk Bosses should be giving GP after they died but the player just get AP.
How can i add GP to these bosses??
Thx already for any help!
Imgur: The most awesome images on the Internet
you shoul make ai
some code and
Code:handleDied() { AbyssPointsService.addGp(player, 1000); }
Thx for this i'll try to make one.
Can you post a full code with the mob ID? just that i can see. thx
mmm)
take some ai of some mob where you will find "AbyssPointsService" make a search through ai...and check how that already done
take that ai redone for your mob. AbyssPointsService - already give ap it means it will give GP.
like that AbyssPointsService.addGp(player, 1000);
1000 - gp
search through the npc ai "handleDied"
under "handleDied" post
AbyssPointsService.addGp(player, 1000);
put ai at npc_templates.xml finito
Can you show me a full example i'm kind of a noob programmer.
If is not much with the npc and all the codes thx.
\scripts\system\handlers\ai
create folder yayaya_ai
put there
yayaya_ai.java
ggg) should work!?))))Code:package ai.yayaya_ai; import ai.AggressiveNpcAI2; import com.aionemu.gameserver.ai2.AIName; import com.aionemu.gameserver.ai2.NpcAI2; import com.aionemu.gameserver.model.gameobjects.Creature; import com.aionemu.gameserver.model.gameobjects.Npc; import com.aionemu.gameserver.services.abyss.AbyssPointsService; import com.aionemu.gameserver.utils.PacketSendUtility; @ainame("yayaya_ai") public class yayaya_ai extends AggressiveNpcAI2 { @Override protected void handleDied() { AbyssPointsService.addGp(player, 1000); super.handleDied(); } }
i'll test it thx bud
- - - Updated - - -
I get this error making your way and making mine. http://imgur.com/a/icGh6
if u can check this file: https://mega.nz/#!79IFUbyS!u7qPfEQuPW88Q9Jdo-CWXZ13wg4XZ_JnG23rj_jC1MY
Code:package ai.yayaya_ai; import ai.AggressiveNpcAI2; import com.aionemu.gameserver.ai2.AIName; import com.aionemu.gameserver.ai2.NpcAI2; import com.aionemu.gameserver.model.gameobjects.Creature; import com.aionemu.gameserver.model.gameobjects.player.Player; import com.aionemu.gameserver.model.gameobjects.Npc; import com.aionemu.gameserver.services.abyss.AbyssPointsService; import com.aionemu.gameserver.utils.PacketSendUtility; import com.aionemu.gameserver.world.World; import com.aionemu.gameserver.world.WorldMapType; import com.aionemu.gameserver.world.knownlist.Visitor; @ainame("yayaya_ai") public class yayaya_ai extends AggressiveNpcAI2 { @Override protected void handleDied() { giveRewardPlayers(); super.handleDied(); } protected void giveRewardPlayers() { World.getInstance().doOnAllPlayers(new Visitor<Player>() { @Override public void visit(Player player) { AbyssPointsService.addGp(player, 1500); } }); } }
- - - Updated - - -
but that will make all people that in the world gets GP))) if you kill all received!!!
rest of that you may check in the sieges... how there are rewarding system works.Code:WorlgetInstance().doOnAllPlayers(new Visitor<Player>()
Last edited by podpol; 30-12-16 at 10:23 PM.
I did this and get this error.
I put in this folder C:\Users\PC\Desktop\DB 4.7.5\AC-Game\data\scripts\system\handlers\ai\yayaya
Imgur: The most awesome images on the Internet
Imgur: The most awesome images on the Internet
name of folder "yayaya_ai" not "yayaya"