GithubHelp home page GithubHelp logo

l3ger0j / questopia Goto Github PK

View Code? Open in Web Editor NEW

This project forked from seedhartha/questplayer

16.0 0.0 2.0 38.36 MB

Android fork port of Quest Soft Player

License: Apache License 2.0

Java 9.87% C 88.74% C++ 1.10% AIDL 0.02% CMake 0.07% HTML 0.20%
android java qsp

questopia's Introduction

Questopia android-test android-build

Android application for launching text format games QSP

Text game launchers of a similar format, but from other authors:

Desktop

QSP from seedHarta (last commit on 01/22/2020)

QSP from Sonnix (last commit from 09/06/2019)

QSP from Byte (last commit 03/15/2024)

Disclaimer

This fork was made WhoYouAndM3. The original project (hereinafter QuestPlayer) with an no license does not bear any responsibility for this fork Questopia.

Thanks

Links to official communities

Official Telegram chat Official Telegram channel

How to use the Plugin API

At the moment, the Plugin API is still in development! Therefore, in order for your plugin to work successfully with my application, you will need to contact me.

To get started, you will need to create an AIDL interface, be sure to place it on the path "org.qp.android.plugin". Next, you need to fill in this file with the following information:

interface yourInterfaceName {
    String versionPlugin();
    String titlePlugin();
    String authorPlugin();
}

Don't forget to return your AIDL interface with the Stub() parameter in the service class, in the onBind method, and initialize the values, and the framework of your plugin for the application is ready!

questopia's People

Contributors

l3ger0j avatar mrboboface avatar vkremianskii avatar kirillashikhmin avatar shirrumon avatar jineyne avatar

Stargazers

 avatar Alexey Lukashevich avatar  avatar Jioh L. Jung avatar  avatar  avatar  avatar  avatar Aleksey Dolgiy avatar chaihahaha avatar  avatar  avatar  avatar Superbip20 avatar Sergey Shitov avatar Michael avatar

questopia's Issues

File path analysis problem

When I use this version,2.4.0

It can be used normally when there is a case difference in the file path.
such as filename is /xxx/AAA/Abc.jpg can able to be identified as /xxx/aaa/abc.jpg.

but in Questopia,it will report an error

`Add Me!` Support player Sonnix

Describe the bug
Games like Clean State use a slightly different syntax. It would be nice to add this version of the library to the application as well

`Fix Me!` RuntimeException in GameMainFragment

Sentry Issue: ANDROID-B

TransactionTooLargeException: data parcel size 597608 bytes
    at android.os.BinderProxy.transactNative(BinderProxy.java)
    at android.os.BinderProxy.transact(BinderProxy.java:584)
    at android.app.IActivityClientController$Stub$Proxy.activityStopped(IActivityClientController.java:1439)
    at android.app.ActivityClient.activityStopped(ActivityClient.java:96)
    at android.app.servertransaction.PendingTransactionActions$StopInfo.run(PendingTransactionActions.java:135)
...
(8 additional frame(s) were not displayed)

RuntimeException: android.os.TransactionTooLargeException: data parcel size 597608 bytes
Bundle stats:
  android:viewHierarchyState [size=1988]
    android:views [size=1940]
  androidx.lifecycle.BundlableSavedStateRegistry.key [size=594736]
    android:support:activity-result [size=119748]
      KEY_COMPONENT_ACTIVITY_REGISTERED_KEYS [size=113664]
      KEY_COMPONENT_ACTIVITY_REGISTERED_RCS [size=5724]
    android:support:fragments [size=474612]
      fragment_fac0f6ab-fa57-4921-9b7e-96b3f6dca2a4 [size=474228]
        childFragmentManager [size=388064]
          fragment_6cb3cdb3-2b7e-4c0d-a1a9-ba12e9f37df5 [size=1076]
          fragment_1d12de2a-eccc-477a-bd94-a0bb18969787 [size=1104]
          fragment_bfb5e44c-687a-4b5c-a4dc-0bd38a455532 [size=1104]
          fragment_54e8ca66-592a-4263-85c9-263a649870bc [size=1188]
          fragment_92cbc9a0-02ca-4f5d-bbce-ca70b1116e3c [size=1104]
          fragment_4d162f9b-8751-414d-b6ff-2d95b457dac1 [size=1104]
          fragment_76fa3e6e-6985-47ae-83d1-83cb0f97c06d [size=1104]
          fragment_059f8bb1-a669-4930-b3dd-9b0dba82553c [size=1076]
          fragment_0662a90a-2874-4a3a-a2a9-d5d66fda3e57 [size=1076]
          fragment_db510b44-71bd-4fe5-97b5-95fc55dc6d93 [size=1104]
          fragment_3eabd19e-78ac-4977-92a6-1f68df5e4960 [size=1104]
          fragment_5e962f68-9478-464c-90ab-dddac26d9079 [size=1076]
          fragment_7ec9696c-79f0-4a4c-b2c1-94f9d73a260e [size=1104]
          fragment_a3f50a2d-c6b3-4706-8062-555172f3c6f1 [size=1104]
          fragment_5549ed39-2b27-41b1-94e5-a13dcffeec1c [size=1104]
          fragment_924fd43b-2583-4eb5-8b23-48ecc31d2f54 [size=1188]
          fragment_29bb31ef-13c5-409e-a1fe-07ef772d6ad8 [size=1076]
          fragment_07a6fc9e-1719-4680-94c9-026908210430 [size=1104]
          fragment_22e32852-bbeb-4dd2-8503-31d9f447bc4c [size=1104]
          fragment_c734bf5d-1ab1-47b3-823c-0db262f888dc [size=1076]
          fragment_e2467471-1e8a-44da-b66a-963b5c0df892 [size=1076]
          fragment_33b761b8-ea09-4971-9c0e-b90f229925d6 [size=1104]
          fragment_a9283ecb-b0bc-4050-a897-bd58421ba38a [size=1104]
          fragment_8a003e03-f335-4347-8b06-0becd0a9b7d5 [size=1104]
          fragment_f0c7b0b0-c6cb-4441-bd8c-a554ae137824 [size=1104]
          fragment_58f56fb2-c196-4fc2-9c74-70a17d700490 [size=1104]
          fragment_7d1b6356-2f5c-4085-bc04-f986f3b3c2d3 [size=1076]
          fragment_2f38bfae-fb2d-4caa-aebe-42c00e92c148 [size=1188]
          fragment_e1e2b661-94b7-4986-8dd4-ad7d53b3bda7 [size=1076]
          fragment_add51b6a-707b-4fc4-b537-cfb8dfe1d6aa [size=1104]
          fragment_3d9bc48a-8c71-40e5-8466-ef4df4771560 [size=1188]
          fragment_686f1971-0bce-4518-ac72-05a56485db1d [size=1076]
          fragment_a4b13d31-9c56-4a7d-ac4b-524166ad82d9 [size=1104]
          fragment_345b5742-1e39-4bbd-ba69-fdbedf12faa7 [size=1076]
          fragment_edb6db39-3d6d-4b00-83a3-5719bd601189 [size=1188]
          state [size=166004]
          fragment_6f3285a6-d048-4381-9f6e-f7fffe535c87 [size=1104]
          fragment_9d51e20d-239a-4804-9ea0-51790305cdec [size=1104]
          fragment_fbc23287-aefc-4c29-9dd1-e959d8b6989d [size=1104]
          fragment_367bd858-a0ce-4196-839b-21f934fa1c2b [size=1104]
          fragment_edb89d26-c73e-48c4-9d0a-9e77eb59e641 [size=1076]
          fragment_7148511a-e8fc-4bf3-93af-0c1a17f3b02a [size=1104]
          fragment_a8dd66b5-c73a-477c-9b20-ae04a0ba2808 [size=1104]
          fragment_9192fcd1-6a80-46d7-bd06-7fb905f4d3c0 [size=1076]
          fragment_197010e1-648f-4df4-bccd-418fd5b95327 [size=1104]
          fragment_73fe3d0e-27f8-448f-bc95-d7dff9851ed2 [size=1104]
          fragment_25d3b6b4-47fa-41a3-83d7-297879085e19 [size=1104]
          fragment_2d49adb5-fe4f-4e1e-86ad-ea2cfcf69992 [size=1104]
          fragment_6a2d7dcd-fa54-4a32-944a-dd47f16cae6b [size=1104]
          fragment_190bd2a6-2569-4446-b4e7-837f0429e054 [size=1188]
          fragment_05d995c6-1ed3-4a37-9853-6f1e243a4bcc [size=1076]
          fragment_69ae2ca4-31c3-4970-a3ac-60748e0b47cd [size=1076]
          fragment_466bf55b-c71d-426d-89e0-e5b2a17e8927 [size=1188]
          fragment_1f19c016-2340-481e-8454-4fac8d64c9af [size=1104]
          fragment_b659d8ba-7f53-4e6a-b123-9f659c7c08fe [size=1076]
          fragment_c80b2b80-547b-44ad-873c-94ba2471ee0b [size=1104]
          fragment_7b377f57-2219-46ce-ab50-82007acc7242 [size=1104]
          fragment_c30da488-8dbc-4936-84fa-ceeb93c74938 [size=1076]
          fragment_61ae8e39-d835-4c3e-a2ee-0f74903b0ff0 [size=1104]
          fragment_fc222378-9604-426c-92e2-ec92f597767e [size=1104]
          fragment_b97c03f0-d5d9-4742-9a43-b43941f4b005 [size=1076]
          fragment_b61b0f03-8474-4e19-a849-ffa61f21bc79 [size=1104]
          fragment_ee6a760f-7c9a-478c-beb0-d0ad3d53180a [size=1104]
          fragment_3da98964-23f9-4d80-bc5a-af21659baf59 [size=1104]
          fragment_f5ec0e88-2bcf-4d21-938a-3e889cecc023 [size=1076]
          fragment_f344e064-fc62-4723-8d7f-9e41717a6b42 [size=1104]
          fragment_6e2439fc-35aa-4ed7-b74b-cb182798d95c [size=1104]
          fragment_438521c7-88e4-4d98-8d8f-45be98834c21 [size=1104]
          fragment_96d75ff7-888f-4be1-9be2-b01f8b753031 [size=1104]
          fragment_80333a61-dcc7-4bd7-89bc-65b0a056be86 [size=1104]
          fragment_cc25f901-0e5e-4980-9d99-a3168037189a [size=1076]
          fragment_ac32b047-b712-423c-a1cc-ff5e516ed7f4 [size=1076]
          fragment_afd37105-1c32-4d0a-8e80-4f5e70ebcc49 [size=1104]
          fragment_69911822-39ec-4571-88c8-b8f2b933c70b [size=1076]
          fragment_9fee9fbd-0eec-4337-8a45-4f1b2efa73a0 [size=1104]
          fragment_72eb7a4e-dc31-4b0c-9106-4a29b13e3a38 [size=1076]
          fragment_e51960b2-1202-4f9e-bec4-7b98ba02c422 [size=1104]
          fragment_ff314bfd-a438-4889-a444-46775096e8fa [size=1104]
        registryState [size=85620]
          androidx.lifecycle.BundlableSavedStateRegistry.key [size=85496]
            android-support-nav:fragment:navControllerState [size=85076]
              android-support-nav:controller:backStack [size=84972]
PersistableBundle stats:
  [null]
    at android.app.servertransaction.PendingTransactionActions$StopInfo.run(PendingTransactionActions.java:146)
    at android.os.Handler.handleCallback(Handler.java:958)
    at android.os.Handler.dispatchMessage(Handler.java:99)
    at android.os.Looper.loopOnce(Looper.java:205)
    at android.os.Looper.loop(Looper.java:294)
...
(4 additional frame(s) were not displayed)

`Refactor Me!` It is necessary to provide a constant way to display the date and time of compilation of the QSP library.

Sentry Issue: ANDROID-1J

RuntimeException: Must be called from the main thread
    at org.qp.android.model.libQP.LibQpProxyImpl.runOnQspThread
    at org.qp.android.model.libQP.LibQpProxyImpl.getCompiledDateTime
    runOnQspThread(this::getCompiledDateTime);
    at org.qp.android.model.libQP.LibQpProxyImpl.lambda$runOnQspThread$0
    runnable.run();
    at org.qp.android.model.libQP.LibQpProxyImpl.$r8$lambda$U8sU58XlFILArW_WeH290iVCylA
    at org.qp.android.model.libQP.LibQpProxyImpl.lambda$start$1
...
(12 additional frame(s) were not displayed)

`Add Me!` It is necessary to create a multifunctional, modular simulation of the QSP library

For further development and transition of the project to the "Stable, suitable for everyday use" stage, it is necessary to create an imitation of the QSP library in the C++ or Rust programming language, which will include the capabilities of both QSP 5.7.0 authored by Byte, and a later variation of QSP 5.7.0 authored by Sonnix, as well as the current QSP 5.8.0 from Byte.

Why do I think so? Because here it will not be possible to do with minor changes in the library code due to the fact that this can lead to a situation that is the reverse of the one in which the project is currently located (that is, some games will work correctly, and some will not).

In summary, for further development, the project needs to modify the QSP library in order to ensure support for the launch of many existing and existing game projects.

Revise the language selection system, make it more encapsulated and independent of any view

The current language system looks like this:

in LanguageUtil

    private static String currentLanguage = Locale.getDefault().getLanguage();

    public static String getCurrentLanguage() {
        return currentLanguage;
    }

    public static void setLocaleOnContext(Context context, String lang) {
        if (!currentLanguage.equals(lang)) {
            var locale = new Locale(lang);
            var res = context.getResources();
            var dm = res.getDisplayMetrics();
            var conf = res.getConfiguration();
            conf.locale = locale;
            currentLanguage = locale.getLanguage();
            res.updateConfiguration(conf , dm);
        }
    }

    public static void setLocaleOnActivity(Activity activity, String languageCode) {
        if (!currentLanguage.equals(languageCode)) {
            Locale locale = new Locale(languageCode);
            Locale.setDefault(locale);
            var resources = activity.getResources();
            var config = resources.getConfiguration();
            config.setLocale(locale);
            resources.updateConfiguration(config , resources.getDisplayMetrics());
            currentLanguage = locale.getLanguage();
        }
    }

in class-consumer (e.g. SettingsActivity)

    private String currentLanguage = Locale.getDefault().getLanguage();

    private void loadLocale() {
        setLocale(this, settingsController.language);
        currentLanguage = settingsController.language;
    }

    @Override
    protected void onResume() {
        super.onResume();
        settingsController = SettingsController.newInstance().loadSettings(this);
        updateLocale();
    }
    private void updateLocale() {
        if (currentLanguage.equals(settingsController.language)) return;
        setLocale(this, settingsController.language);
        currentLanguage = settingsController.language;
    }

Problems caused by using this system:

  1. The problem with determining the current language is because the Locale method.getDefault() returns the value defined at startup;
  2. The problem associated with creating something using a subset of R.string;
  3. The problem with portability and code volume.

The solution is to switch to the Language API

`Fix Me!` The playback of some games

Sentry Issue: ANDROID-3

SIGSEGV: Segfault
  ?, in qspPreprocessData
  ?, in qspOpenQuestFromData
  ?, in QSPLoadGameWorldFromData
  ?, in Java_org_qp_android_model_libQP_NativeMethods_QSPLoadGameWorldFromData
  ?
...
(25 additional frame(s) were not displayed)

`Fix Me!` RuntimeException in GameActivity

Sentry Issue: ANDROID-5

NullPointerException: Attempt to invoke virtual method 'android.net.Uri androidx.documentfile.provider.a.l()' on a null object reference
    at org.qp.android.ui.game.GameActivity.onCreate
    at org.qp.android.ui.game.GameActivity.onCreate
    gameViewModel = new ViewModelProvider(this).get(GameViewModel.class);
...
(24 additional frame(s) were not displayed)

InvocationTargetException: None
    at org.qp.android.ui.game.GameActivity.onCreate
    at org.qp.android.ui.game.GameActivity.onCreate
    gameViewModel = new ViewModelProvider(this).get(GameViewModel.class);
...
(22 additional frame(s) were not displayed)

RuntimeException: Cannot create an instance of class o6.v
    at org.qp.android.ui.game.GameActivity.onCreate
    at org.qp.android.ui.game.GameActivity.onCreate
    gameViewModel = new ViewModelProvider(this).get(GameViewModel.class);
...
(20 additional frame(s) were not displayed)

RuntimeException: Unable to start activity ComponentInfo{org.qp.android/org.qp.android.ui.game.GameActivity}: java.lang.RuntimeException: Cannot create an instance of class o6.v
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3833)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3970)
    at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:101)
    at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
    at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
...
(8 additional frame(s) were not displayed)

The in-game save loading does not work

Perhaps the problem is related to the fact that now the contents of the file are obtained not through direct access via a link like "file:///", but with the help of a content provider and a link like "content://".

Also, inside the library, a possibly valid byte stream turns into the same set of characters of the form "l\u0000fffd".

At this point in time, I do not know how to solve this problem.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.