lucianoGG / tyranobuilder-android

Update Tyrano Builder App Android
10 stars 1 forks source link

When compiling it has many bugs #1

Open staFF6773 opened 2 months ago

staFF6773 commented 2 months ago

Hi I'm staFF6773 and I've been testing this template of this project to adapt a visual novel of tyrano builder to android I think the code is very good but I've seen that the bug has too many errors when passing the app to apk for example when you enter your visual novel you get the message of access denied to save files and load them or ask you the question if you want to save also I noticed that the audio of the game is stuck and I followed all the steps you showed to adapt your visual novel

private boolean checkPermission() {
        int result = ContextCompat.checkSelfPermission(this, android.Manifest.permission.WRITE_EXTERNAL_STORAGE);
        return result == PackageManager.PERMISSION_GRANTED;
    }

    private void requestPermission() {

        if (ActivityCompat.shouldShowRequestPermissionRationale(this, android.Manifest.permission.WRITE_EXTERNAL_STORAGE)) {
            AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder(this);
            alertDialogBuilder
                    .setTitle("Permissão para SAVE")
                    .setMessage("o jogo precisa de permissão para salvar e ler os saves")
                    .setCancelable(false)
                    .setPositiveButton("SIM",
                            (dialog, id) -> {
                                Intent intent = new Intent(Settings.ACTION_APPLICATION_DETAILS_SETTINGS);
                                Uri uri = Uri.fromParts("package", getPackageName(), null);
                                intent.setData(uri);
                                startActivity(intent);
                            })

                    .setNegativeButton("NÃO", (dialog, id) -> dialog.cancel());

            AlertDialog alertDialog = alertDialogBuilder.create();
            alertDialog.show();
        } else {
            ActivityCompat.requestPermissions(this, new String[]{android.Manifest.permission.WRITE_EXTERNAL_STORAGE}, PERMISSION_REQUEST_CODE);
        }
    }

    @Override
    public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
        super.onRequestPermissionsResult(requestCode, permissions, grantResults);
        if (requestCode == PERMISSION_REQUEST_CODE) {
            if (grantResults.length > 0 && grantResults[0] == PackageManager.PERMISSION_GRANTED) {
                Log.e("value", "Permission Granted, Now you can use local drive .");
            } else {
                Toast.makeText(this, "Permissão de acesso negado, você não pode salvar e nem carregar", Toast.LENGTH_LONG).show();
                Log.e("value", "Permission Denied, You cannot use local drive .");
            }
        }
    }

The game ignores the permissions conditions and jumps you at once


Toast.makeText(this, "Permissão de acesso negado, você não pode salvar e nem carregar", Toast.LENGTH_LONG).show();```
lucianoGG commented 2 months ago

@staFF6773 Thank you for reporting this issue, could you provide details of the operating system version and which device model is used, I will do some tests to correct it as soon as possible!

staFF6773 commented 2 months ago

@staFF6773 Thank you for reporting this issue, could you provide details of the operating system version and which device model is used, I will do some tests to correct it as soon as possible!

Well when I did the test of my visual novel I used android 14 and my phone is a pixel 7 I personally tested it on my phone I didn't use the android emulator

lucianoGG commented 2 months ago

@staFF6773 Thank you for reporting this issue, could you provide details of the operating system version and which device model is used, I will do some tests to correct it as soon as possible!

Well when I did the test of my visual novel I used android 14 and my phone is a pixel 7 I personally tested it on my phone I didn't use the android emulator

After reading the Android documentation, accessing data/save does not require a high-level permission request anymore. It has been removed and the package has been updated. Please consider downloading it again and testing. If there are any bugs, I would appreciate it if you could report them again.

staFF6773 commented 2 months ago

@staFF6773 Thank you for reporting this issue, could you provide details of the operating system version and which device model is used, I will do some tests to correct it as soon as possible!

Well when I did the test of my visual novel I used android 14 and my phone is a pixel 7 I personally tested it on my phone I didn't use the android emulator

After reading the Android documentation, accessing data/save does not require a high-level permission request anymore. It has been removed and the package has been updated. Please consider downloading it again and testing. If there are any bugs, I would appreciate it if you could report them again.

Thank you very much for your help I will test if it works correctly with android 14

staFF6773 commented 2 months ago

@lucianoGG

Hello good evening I wanted to inform you that I still have the same error but now is different directly the app or habre here I leave a video to look at the error I have

Link: https://youtu.be/6pnhQ_QkGig?si=w3pwNvugAq164fyc

lucianoGG commented 2 months ago

@lucianoGG

Hello good evening I wanted to inform you that I still have the same error but now is different directly the app or habre here I leave a video to look at the error I have

Link: https://youtu.be/6pnhQ_QkGig?si=w3pwNvugAq164fyc

Thanks for the feedback, I'm testing it now, I exported a recent project again and it's working in the emulator, could you confirm if in the assets folder you have the "data" and "tyrano" folders and the files "index.html" and "tyrano_player.js", the latter being necessary to link the layers

Captura de tela 2024-09-24 225612

staFF6773 commented 2 months ago

@lucianoGG

Hello good evening I wanted to inform you that I still have the same error but now is different directly the app or habre here I leave a video to look at the error I have

Link: https://youtu.be/6pnhQ_QkGig?si=w3pwNvugAq164fyc

Thanks for the feedback, I'm testing it now, I exported a recent project again and it's working in the emulator, could you confirm if in the assets folder you have the "data" and "tyrano" folders and the files "index.html" and "tyrano_player.js", the latter being necessary to link the layers

Captura de tela 2024-09-24 225612

Yes, I was trying to start the project in the emulator but it fails me because of the storage, that's my problem, so I try it with my phone and the game doesn't load. I have all the files that the project needs to work, I even tried to fix the problem by modifying the code but it's still the same.