AltimitSystems / mv-android-client

RPG Maker MV unofficial Android client
http://www.hbgames.org/forums/viewtopic.php?f=48&t=79391
Apache License 2.0
115 stars 36 forks source link

Implement new codes in the project #21

Open RakuenZero opened 4 years ago

RakuenZero commented 4 years ago

Hi, again guys! I want to add new codes to my project. I already add a few things, but I'm not sure how to this properly. I don't want you to implement it for me. I just want to learn and contribute with the project and the community ^^ So, for example, if I want to add this code to make the players rate the app(with the proper import, of course):

public void rateMe(View v) { try { startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + "PackageNameInPlayStore"))); } catch (ActivityNotFoundException e) { startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("http://play.google.com/store/apps/details?id=" + getPackageName()))); } } Where exaclty I have to add it? In the file WebPlayerActivity? 1 - "app/java/system.altimitrpgmakermv/WebPlayerActivity ?

I notice that for google play to work you made a thing call "handler" that I guess that this code is the bridge to google play work with script calls inside rpgmaker mv.

If I want to add this code to rate the app, I have no other choice but to make an interface too? Or can I simply put it inside the WebPlayerActivity and call the code with script call? Like an android toast for example?

I already have read several articles in the google play developers, but can't find a way to simply add new things =/ Hope you guys can show me the way!^^''