diff --git a/HMCL/build.gradle b/HMCL/build.gradle index 70c0bcf70..a1a5cc879 100755 --- a/HMCL/build.gradle +++ b/HMCL/build.gradle @@ -26,7 +26,7 @@ if (!hasProperty('mainClass')) { ext.mainClass = 'org.jackhuang.hellominecraft.launcher.Main' } -def buildnumber = System.getenv("BUILD_NUMBER") == null ? ".10" : "."+System.getenv("BUILD_NUMBER") +def buildnumber = System.getenv("BUILD_NUMBER") == null ? ".233" : "."+System.getenv("BUILD_NUMBER") String mavenGroupId = 'HMCL' String mavenVersion = '2.4.0' + buildnumber diff --git a/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.form b/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.form index 5a690f733..6351c990b 100644 --- a/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.form +++ b/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.form @@ -16,17 +16,23 @@ - + + + + + - + + + @@ -51,12 +57,19 @@ - + + + + + + + + diff --git a/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.java b/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.java index 9dd3f55d9..f66e9c008 100644 --- a/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.java +++ b/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackDescriptionPanel.java @@ -61,6 +61,7 @@ public class ModpackDescriptionPanel extends javax.swing.JPanel { jScrollPane1 = new javax.swing.JScrollPane(); txtDescription = new javax.swing.JTextPane(); jButton1 = new javax.swing.JButton(); + lblTitle = new javax.swing.JLabel(); txtDescription.addCaretListener(new javax.swing.event.CaretListener() { public void caretUpdate(javax.swing.event.CaretEvent evt) { @@ -69,26 +70,33 @@ public class ModpackDescriptionPanel extends javax.swing.JPanel { }); jScrollPane1.setViewportView(txtDescription); - jButton1.setText(C.i18n("ui.button.test")); // NOI18N + jButton1.setText(C.i18n("ui.button.preview")); // NOI18N jButton1.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton1ActionPerformed(evt); } }); + lblTitle.setText(C.i18n("modpack.desc")); // NOI18N + javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this); this.setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) - .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 400, Short.MAX_VALUE) + .addComponent(jScrollPane1) .addGroup(layout.createSequentialGroup() .addGap(0, 0, Short.MAX_VALUE) .addComponent(jButton1)) + .addGroup(layout.createSequentialGroup() + .addComponent(lblTitle) + .addGap(0, 0, Short.MAX_VALUE)) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() - .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 270, Short.MAX_VALUE) + .addComponent(lblTitle) + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) + .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 250, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jButton1)) ); @@ -101,18 +109,19 @@ public class ModpackDescriptionPanel extends javax.swing.JPanel { private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed try { Object msgs[] = new Object[2]; - msgs[0] = C.i18n("ui.button.test"); + msgs[0] = C.i18n("ui.button.preview"); msgs[1] = new WebPage(new Markdown4jProcessor().process(txtDescription.getText())); ((WebPage) msgs[1]).setPreferredSize(new Dimension(800, 350)); JOptionPane.showOptionDialog(null, msgs, (String) msgs[0], JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE, null, null, null); } catch (Exception e) { - MessageBox.Show(StrUtils.getStackTrace(e), "Error", MessageBox.WARNING_MESSAGE); + MessageBox.Show(StrUtils.getStackTrace(e), C.i18n("message.error"), MessageBox.WARNING_MESSAGE); } }//GEN-LAST:event_jButton1ActionPerformed // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JButton jButton1; private javax.swing.JScrollPane jScrollPane1; + private javax.swing.JLabel lblTitle; private javax.swing.JTextPane txtDescription; // End of variables declaration//GEN-END:variables } diff --git a/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackInitializationPanel.java b/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackInitializationPanel.java index 8102fb949..535219303 100644 --- a/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackInitializationPanel.java +++ b/HMCL/src/main/java/org/jackhuang/hellominecraft/launcher/ui/modpack/ModpackInitializationPanel.java @@ -177,8 +177,12 @@ public class ModpackInitializationPanel extends javax.swing.JPanel { fc.setMultiSelectionEnabled(false); fc.setFileFilter(new FileNameExtensionFilter(C.i18n("modpack") + "(*.zip)", "zip")); fc.showSaveDialog(this); - if (fc.getSelectedFile() != null) - txtModpackLocation.setText(fc.getSelectedFile().getAbsolutePath()); + if (fc.getSelectedFile() != null) { + String path = fc.getSelectedFile().getAbsolutePath(); + if (!path.endsWith(".zip")) + path += ".zip"; + txtModpackLocation.setText(path); + } }//GEN-LAST:event_cboModpackLocationActionPerformed private void txtModpackLocationCaretUpdate(javax.swing.event.CaretEvent evt) {//GEN-FIRST:event_txtModpackLocationCaretUpdate diff --git a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.lang b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.lang index 7de8ae97d..1b85fb90b 100755 --- a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.lang +++ b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.lang @@ -149,6 +149,7 @@ ui.button.clear=清除 ui.button.close=关闭 ui.button.explore=浏览 ui.button.test=测试 +ui.button.preview=预览 button.cancel=取消 button.ok=确定 @@ -235,7 +236,7 @@ modpack.incorrect_format.no_json=整合包格式错误,pack.json丢失 modpack.incorrect_format.no_jar=整合包格式错误,pack.json丢失jar字段 modpack.cannot_read_version=读取游戏版本失败 modpack.not_a_valid_location=不是一个有效整合包位置 -modpack.warning=在制作整合包前,请您确认您选择的版本可以正常启动,
并保证您的Minecraft是正式版而非快照版,
而且不应当将不允许非官方途径传播的Mod纳入整合包。 +modpack.warning=在制作整合包前,请您确认您选择的版本可以正常启动,
并保证您的Minecraft是正式版而非快照版,
而且不应当将不允许非官方途径传播的Mod、材质包等纳入整合包。 modpack.name=整合包名称 modpack.not_a_valid_name=整合包名称不能为空 diff --git a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.properties b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.properties index 5380bab72..defe65308 100755 --- a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.properties +++ b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N.properties @@ -149,6 +149,7 @@ ui.button.clear=\u6e05\u9664 ui.button.close=\u5173\u95ed ui.button.explore=\u6d4f\u89c8 ui.button.test=\u6d4b\u8bd5 +ui.button.preview=\u9884\u89c8 button.cancel=\u53d6\u6d88 button.ok=\u786e\u5b9a @@ -235,7 +236,7 @@ modpack.incorrect_format.no_json=\u6574\u5408\u5305\u683c\u5f0f\u9519\u8bef\uff0 modpack.incorrect_format.no_jar=\u6574\u5408\u5305\u683c\u5f0f\u9519\u8bef\uff0cpack.json\u4e22\u5931jar\u5b57\u6bb5 modpack.cannot_read_version=\u8bfb\u53d6\u6e38\u620f\u7248\u672c\u5931\u8d25 modpack.not_a_valid_location=\u4e0d\u662f\u4e00\u4e2a\u6709\u6548\u6574\u5408\u5305\u4f4d\u7f6e -modpack.warning=\u5728\u5236\u4f5c\u6574\u5408\u5305\u524d\uff0c\u8bf7\u60a8\u786e\u8ba4\u60a8\u9009\u62e9\u7684\u7248\u672c\u53ef\u4ee5\u6b63\u5e38\u542f\u52a8\uff0c
\u5e76\u4fdd\u8bc1\u60a8\u7684Minecraft\u662f\u6b63\u5f0f\u7248\u800c\u975e\u5feb\u7167\u7248\uff0c
\u800c\u4e14\u4e0d\u5e94\u5f53\u5c06\u4e0d\u5141\u8bb8\u975e\u5b98\u65b9\u9014\u5f84\u4f20\u64ad\u7684Mod\u7eb3\u5165\u6574\u5408\u5305\u3002 +modpack.warning=\u5728\u5236\u4f5c\u6574\u5408\u5305\u524d\uff0c\u8bf7\u60a8\u786e\u8ba4\u60a8\u9009\u62e9\u7684\u7248\u672c\u53ef\u4ee5\u6b63\u5e38\u542f\u52a8\uff0c
\u5e76\u4fdd\u8bc1\u60a8\u7684Minecraft\u662f\u6b63\u5f0f\u7248\u800c\u975e\u5feb\u7167\u7248\uff0c
\u800c\u4e14\u4e0d\u5e94\u5f53\u5c06\u4e0d\u5141\u8bb8\u975e\u5b98\u65b9\u9014\u5f84\u4f20\u64ad\u7684Mod\u3001\u6750\u8d28\u5305\u7b49\u7eb3\u5165\u6574\u5408\u5305\u3002 modpack.name=\u6574\u5408\u5305\u540d\u79f0 modpack.not_a_valid_name=\u6574\u5408\u5305\u540d\u79f0\u4e0d\u80fd\u4e3a\u7a7a diff --git a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.lang b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.lang index 7c529d805..0337a4ddb 100755 --- a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.lang +++ b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.lang @@ -149,6 +149,7 @@ ui.button.clear=Clear ui.button.close=Close ui.button.explore=Explore ui.button.test=Test +ui.button.preview=Preview button.cancel=Cancel button.ok=OK diff --git a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.properties b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.properties index 60bfd3e01..f1a44050a 100755 --- a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.properties +++ b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_en.properties @@ -149,6 +149,7 @@ ui.button.clear=Clear ui.button.close=Close ui.button.explore=Explore ui.button.test=Test +ui.button.preview=Preview button.cancel=Cancel button.ok=OK diff --git a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.lang b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.lang index ed6227856..08dc12d42 100755 --- a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.lang +++ b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.lang @@ -149,6 +149,7 @@ ui.button.clear=清除 ui.button.close=關閉 ui.button.explore=瀏覽 ui.button.test=測試 +ui.button.preview=預覽 button.cancel=取消 button.ok=確定 @@ -235,7 +236,7 @@ modpack.incorrect_format.no_json=懶人包格式錯誤,pack.json丟失 modpack.incorrect_format.no_jar=懶人包格式錯誤,pack.json丟失jar字段 modpack.cannot_read_version=讀取遊戲版本失敗 modpack.not_a_valid_location=不是一个有效懒人包位置 -modpack.warning=在製作懶人包前,請您確認您選擇的版本可以正常啟動,​​
並保證您的Minecraft是正式版而非快照版,
而且不應當將不允許非官方途徑傳播的Mod納入整合包。 +modpack.warning=在製作懶人包前,請您確認您選擇的版本可以正常啟動,​​
並保證您的Minecraft是正式版而非快照版,
而且不應當將不允許非官方途徑傳播的Mod、材質包等納入整合包。 modpack.name=懶人包名稱 modpack.not_a_valid_name=懶人包名稱不能為空 diff --git a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.properties b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.properties index 20a0d7942..cb6081a11 100755 --- a/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.properties +++ b/HMCLAPI/src/main/resources/org/jackhuang/hellominecraft/lang/I18N_zh_TW.properties @@ -149,6 +149,7 @@ ui.button.clear=\u6e05\u9664 ui.button.close=\u95dc\u9589 ui.button.explore=\u700f\u89bd ui.button.test=\u6e2c\u8a66 +ui.button.preview=\u9810\u89bd button.cancel=\u53d6\u6d88 button.ok=\u78ba\u5b9a @@ -235,7 +236,7 @@ modpack.incorrect_format.no_json=\u61f6\u4eba\u5305\u683c\u5f0f\u932f\u8aa4\uff0 modpack.incorrect_format.no_jar=\u61f6\u4eba\u5305\u683c\u5f0f\u932f\u8aa4\uff0cpack.json\u4e1f\u5931jar\u5b57\u6bb5 modpack.cannot_read_version=\u8b80\u53d6\u904a\u6232\u7248\u672c\u5931\u6557 modpack.not_a_valid_location=\u4e0d\u662f\u4e00\u4e2a\u6709\u6548\u61d2\u4eba\u5305\u4f4d\u7f6e -modpack.warning=\u5728\u88fd\u4f5c\u61f6\u4eba\u5305\u524d,\u8acb\u60a8\u78ba\u8a8d\u60a8\u9078\u64c7\u7684\u7248\u672c\u53ef\u4ee5\u6b63\u5e38\u555f\u52d5,\u200b\u200b
\u4e26\u4fdd\u8b49\u60a8\u7684Minecraft\u662f\u6b63\u5f0f\u7248\u800c\u975e\u5feb\u7167\u7248,
\u800c\u4e14\u4e0d\u61c9\u7576\u5c07\u4e0d\u5141\u8a31\u975e\u5b98\u65b9\u9014\u5f91\u50b3\u64ad\u7684Mod\u7d0d\u5165\u6574\u5408\u5305\u3002 +modpack.warning=\u5728\u88fd\u4f5c\u61f6\u4eba\u5305\u524d,\u8acb\u60a8\u78ba\u8a8d\u60a8\u9078\u64c7\u7684\u7248\u672c\u53ef\u4ee5\u6b63\u5e38\u555f\u52d5,\u200b\u200b
\u4e26\u4fdd\u8b49\u60a8\u7684Minecraft\u662f\u6b63\u5f0f\u7248\u800c\u975e\u5feb\u7167\u7248,
\u800c\u4e14\u4e0d\u61c9\u7576\u5c07\u4e0d\u5141\u8a31\u975e\u5b98\u65b9\u9014\u5f91\u50b3\u64ad\u7684Mod\u3001\u6750\u8cea\u5305\u7b49\u7d0d\u5165\u6574\u5408\u5305\u3002 modpack.name=\u61f6\u4eba\u5305\u540d\u7a31 modpack.not_a_valid_name=\u61f6\u4eba\u5305\u540d\u7a31\u4e0d\u80fd\u70ba\u7a7a