Forum rules: Do not post bugs or feature requests here! Report bugs to our Issue Tracker and suggestions to Suggest a Feature.

This site is not for solicitation of services or 'purchasing' development. Please do not post requesting side mods/plugins and so on. Your thread will be removed, and you will receive a warning.
User avatar
By Elrol
#199486 I am not too sure if this is where I should be posting this, but I didnt see a better place to put it.

I am currently working on a plugin, and I am trying to see if there is a way to tell if a battle has been started by catching a pokemon using one of the rods. At the moment, I am checking if the pokemon is a water type and if the item in the players hand is an instance of the ItemFishingRod (from pixelmon) is there a better way to do this so that players cant run around holding the rod and catching pokemon in the water normally?

User avatar
By Elrol
#199488 Is there a way to get the source for it, so that i can look in the files and find this kind of stuff. atm all the files say "Source not found" etc.

And is there a way to get the BattleController for a battle after the pokemon was caught (atm i have the CaptureEvent.SuccessfulCapture event as the way to check if a pokemon was caught. I want to see if that pokemon was caught in a battle that was started by fishing.
)

ok, so i found that I can do this:
event.getPokemon().battleController.wasFishing

I just want to make sure that would be the best way to tell if a pokemon that was caught, was caught in a battle that was started by fishing.
User avatar
By Some Body
#199489 The Pixelmon source is not public and there are no plans to make it so.

Your best bet would be to join Pixelmon's Discord to ask about making plugins and sidemods.
User avatar
By Elrol
#199490 ok, thank you. I will join it and see what they can tell me. I used the: event.getPokemon().battleController.wasFishing and it crashed, so I will need to have that sorted. Thanks for the help
JOIN THE TEAM