Skip to content

Commit

Permalink
translate some words Chinese to English
Browse files Browse the repository at this point in the history
Use OpenJDK instead of OracleJDK(will have less performance)
............
A waste of time!!!
  • Loading branch information
SnowNF committed Oct 2, 2020
1 parent 02618da commit b8d70fa
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 20 deletions.
6 changes: 4 additions & 2 deletions AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@
package="net.zhuoweizhang.boardwalk"
android:versionCode="10"
android:versionName="1.9">
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="28" />
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="22" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

<application android:label="@string/app_name" android:largeHeap="true"
<application
android:usesCleartextTraffic="true"
android:label="@string/app_name" android:largeHeap="true"
android:icon="@drawable/ic_launcher" android:theme="@style/BoardwalkTheme">
<activity android:name="MainActivity"
android:label="@string/app_name"
Expand Down
Binary file not shown.
4 changes: 2 additions & 2 deletions res/layout/launcher_layout.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:singleLine="true"
android:hint="内存"
android:hint="RAM(less than 1024MB)"
android:inputType="number"/>

<Button
Expand All @@ -46,7 +46,7 @@
android:id="@+id/launcher_root_mode_button"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="root模式(非必须,用于安卓6+)"/>
android:text="use root.(used for Android6+)"/>

<Button
android:id="@+id/launcher_import_resource_pack_button"
Expand Down
13 changes: 6 additions & 7 deletions res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Boardwalk</string>
<string name="login_username_hint">用户名</string>
<string name="login_username_hint">Username(offline)</string>
<string name="login_is_demo_account">This account doesn\'t seems to have a Minecraft user linked to it. Did you buy Minecraft? You can play the Demo version with the "Play Demo" button below.</string>
<string name="login_logging_in">登录&#8230;</string>
<string name="login_error">无法登录:</string>
<string name="login_button">没什么用...</string>
<string name="login_extra_info_text">Boardwalk build for Android 6+ \n 使用前请在终端输入:\n setenforce 0 \n am restart
</string>
<string name="login_import_resource_pack">解压runtime(初次使用请点击)</string>
<string name="login_button">nothing...</string>
<string name="login_extra_info_text">Boardwalk build for Android 6+ \nhttps://github.com/SnowNF/boardwalk\nIf can\'t play,please try \"use root\" or reduce ram.</string>
<string name="login_import_resource_pack">extra runtime</string>


<string name="play_offline">离线游玩</string>
<string name="play_demo">Play</string>
<string name="play_regular">启动minecraft</string>
<string name="convert_populating_working_directory">Populating working directory</string>
<string name="convert_downloading">下载中...</string>
<string name="convert_converting">转换中...</string>
<string name="convert_downloading">正在下载...</string>
<string name="convert_converting">正在转换...</string>
<string name="convert_preparing_to_launch_minecraft">正在准备启动Minecraft....</string>


Expand Down
8 changes: 4 additions & 4 deletions src/net/zhuoweizhang/boardwalk/LauncherActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -135,22 +135,22 @@ public void onClick(View v) {
if(f.exists()){
doPreLaunch();
}else{
Toast.makeText(this,"未解压runtime,请解压",Toast.LENGTH_LONG).show();
Toast.makeText(this,"runtime is not extracted,please extract runtime.",Toast.LENGTH_LONG).show();
}

} else if (v == RootModeButton) {
doRoot();
} else if (v == importResourcePackButton) {
//doBrowseForResourcePack();
Toast.makeText(this,"正在解压...",Toast.LENGTH_LONG).show();
Toast.makeText(this,"extraing...",Toast.LENGTH_LONG).show();
extractThread = new Thread(new ExtractRuntime(this));
extractThread.start();
}
}
public void doRoot(){
AlertDialog.Builder root_note = new AlertDialog.Builder(LauncherActivity.this);
root_note.setTitle("提示");
root_note.setMessage("root模式实际上是关闭SELinux,软重启后才能生效,请注意保存重要数据\n 你也可以手动软重启 \n 执行的命令为: \n setenforce 0 (关闭SELinux) \n am restart (软重启) \n PS:用了多线程,请等待root软件授权完毕");
root_note.setTitle("注意");
root_note.setMessage("root模式实际上是关闭SELinux,软重启后才能生效,请注意保存正在运行的软件数据\n 你也可以手动软重启 \n 执行的命令为: \n setenforce 0 (关闭SELinux) \n am restart (软重启) \n PS:用了多线程,请等待root软件授权完毕");
root_note.setPositiveButton("关闭SELinux并软重启", new DialogInterface.OnClickListener(){

@Override
Expand Down
6 changes: 3 additions & 3 deletions src/net/zhuoweizhang/boardwalk/potato/ExtractRuntime.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public void run() {
String[] link = new String[]{"ln","-s",libDir+"libbusybox.so",runtimeDirPath+"/busybox"};
doExec(link);
//extractAsset("busybox");
extractTar("oraclejdk8-arm-202.tgz", new File(runtimeDirPath).getAbsolutePath());
extractTar("openjdk_8u265b01.tgz", new File(runtimeDirPath).getAbsolutePath());
extractTar("glibc.tgz", new File(runtimeDirPath).getAbsolutePath());
extractAsset("libboardwalk_preload.so");
extractAsset("liblwjgl.so");
Expand All @@ -43,12 +43,12 @@ public void run() {
extractAsset("lwjgl_util.jar");
extractAsset("librarylwjglopenal-20100824.jar");
Looper.prepare();
Toast.makeText(context,"解压成功",Toast.LENGTH_LONG).show();
Toast.makeText(context,"extra runtime successfully",Toast.LENGTH_LONG).show();
Looper.loop();
} catch (Exception e) {
e.printStackTrace();
Looper.prepare();
Toast.makeText(context,"解压失败:"+e.toString()+"\n 请尝试切换到root模式",Toast.LENGTH_LONG).show();
Toast.makeText(context,"fail to extra runtime: "+e.toString()+"\n please try to use root.",Toast.LENGTH_LONG).show();
Looper.loop();
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/net/zhuoweizhang/boardwalk/potato/LoadMe.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public static void exec(String mcClassPath, String[] backArgs) {
setenv("LIBGL_ES","1");

setenv("LD_PRELOAD", runtimePath + "/libboardwalk_preload.so");
setenv("OVERRIDE_PROC_SELF_EXE", runtimePath + "/jre/bin/java");
setenv("OVERRIDE_PROC_SELF_EXE", runtimePath + "/jdk8u265-b01-jre/bin/java");

setenv("LIBGL_MIPMAP", "3");
setenv("HOME", "/sdcard/boardwalk");
Expand All @@ -44,7 +44,7 @@ public static void exec(String mcClassPath, String[] backArgs) {
String[] frontArgs = {runtimePath + "/newglibc/lib/ld-linux-armhf.so.3",
"--library-path",
runtimePath + "/newglibc/lib:" + runtimePath,
runtimePath + "/jre/bin/java",
runtimePath + "/jdk8u265-b01-jre/bin/java",
"-client", "-Xms64M", "-Xmx"+LauncherActivity.getRAM().toString()+"M",
"-cp", mcClassPath,
"-Djava.library.path=" + runtimePath};
Expand Down

1 comment on commit b8d70fa

@Malaska678
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not my fault. I said u can keep it

Please sign in to comment.