Skip to content
Merged

Dev #28

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .vitepress/sidebar/zh_CN.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ export const zhSidebar: DefaultTheme.Sidebar = {
'/zh_CN/': [
{ text: '主页', link: '/zh_CN' },
{ text: '下载', link: '/zh_CN/download' },
{ text: '捐赠', link: '/zh_CN/donate' },
{
text: '使用文档', items: [
{ text: '快速开始', link: '/zh_CN/docs/manual/quick-start' },
Expand Down
37 changes: 37 additions & 0 deletions .vitepress/theme/components/AfdianCard.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<template>
<iframe
ref="afdianIframe"
src="https://afdian.com/leaflet?slug=sanmusen214"
:width="iframeWidth"
height="200"
scrolling="no"
frameborder="0"
></iframe>
</template>

<script setup>
import { ref, onMounted, onUnmounted } from 'vue'

const afdianIframe = ref(null)
const iframeWidth = ref('100%')

const updateWidth = () => {
iframeWidth.value = document.body.clientWidth < 700 ? '100%' : '640'
}

onMounted(() => {
updateWidth()
window.addEventListener('resize', updateWidth)
})

onUnmounted(() => {
window.removeEventListener('resize', updateWidth)
})
</script>

<style scoped>
iframe {
display: block;
margin: 0 auto;
}
</style>
13 changes: 9 additions & 4 deletions .vitepress/theme/components/DownloadLink.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,14 @@
<div v-if="platform === 'windows'">
<a href="https://github.com/BlueArchiveArisHelper/BAAH/releases" class="VPButton medium brand">{{
texts.githubRelease }}</a>
<a href="https://pan.quark.cn/s/319faf23496c" class="VPButton medium alt">{{ texts.quarkDownload }}</a>
<a href="https://pan.quark.cn/s/49fab9d220ec?pwd=W3dc" class="VPButton medium alt" :title="texts.quarkExtractionCode">{{
texts.quarkDownload }}</a>
<a href="https://mirrorchyan.com/zh/projects?rid=BAAH" class="VPButton medium alt">{{ texts.mirrorChyanDownload
}}</a>
}}</a>
<a href="https://api.blockhaity.qzz.io/docs/#/api-doc/getbaah" class="VPButton medium alt">{{
texts.blockhaityapi }}</a>
<a href="https://cnb.cool/BlockHaity/BAAH-releases/-/releases" class="VPButton medium alt">{{ texts.cnbDownload
}}</a>
</div>

<div v-else-if="platform === 'mac'">
Expand Down Expand Up @@ -63,8 +66,9 @@ export default {
currentVersion: '当前最新版本:',
releaseContent: '发布内容',
quarkDownload: '夸克网盘下载',
quarkExtractionCode: '提取码:W3dc',
mirrorChyanDownload: 'Mirror酱下载(需要CDK)',
githubDirectDownload: 'GitHub直链下载',
cnbDownload: 'Cloud Native Build',
githubRelease: 'GitHub Release',
viewSourceTutorial: '查看源码部署教程',
dockerDeploy: 'Docker部署',
Expand All @@ -80,8 +84,9 @@ export default {
currentVersion: 'Current Latest Version: ',
releaseContent: 'Release Content',
quarkDownload: 'Quark Cloud Download',
quarkExtractionCode: 'Extraction Code: W3dc',
mirrorChyanDownload: 'MirrorChyan Download (CDK Required)',
githubDirectDownload: 'GitHub Direct Download',
cnbDownload: 'Cloud Native Build',
githubRelease: 'GitHub Release',
viewSourceTutorial: 'View Source Deployment Tutorial',
linuxDeployMessage: 'Your OS is Linux, you can use the following deployment methods',
Expand Down
1 change: 1 addition & 0 deletions .vitepress/theme/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export default {
enhanceApp({ app }) {
app.component('DownloadLink', defineAsyncComponent(() => import('./components/DownloadLink.vue')));
app.component('LanguageWarn', defineAsyncComponent(() => import('./components/LanguageWarn.vue')));
app.component('AfdianCard',defineAsyncComponent(() => import('./components/AfdianCard.vue')));
enhanceAppWithTabs(app)
app.component('LiteTree', LiteTree)
},
Expand Down
14 changes: 11 additions & 3 deletions edge-functions/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

const supportedLanguages = [
{ code: 'en', name: 'English', path: '/en_US/' },
{ code: 'zh', name: '中文', path: '/zh_CN/' },
{ code: 'en', name: 'English', path: '/en_US' },
{ code: 'zh', name: '中文', path: '/zh_CN' },
]

// 获取浏览器语言偏好
Expand Down Expand Up @@ -35,11 +35,19 @@ export default async function onRequest(context) {
try {
const acceptLanguage = context.request.headers.get('accept-language') || ''
const browserLanguage = getBrowserLanguage(acceptLanguage)

// 解析URL获取target参数
const url = new URL(context.request.url)
const target = url.searchParams.get('target') || '/'

// 构建重定向路径
const redirectPath = target ? `${browserLanguage.path}${target}` : browserLanguage.path

// 返回重定向响应
return Response.redirect(browserLanguage.path, 302)
return Response.redirect(redirectPath, 302)
} catch (error) {
// 错误处理:重定向到默认语言(中文)
return Response.redirect(supportedLanguages[1].path, 302)
}
}

10 changes: 8 additions & 2 deletions src/en_US/docs/manual/quick-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ description: Complete BlueArchive Aris Helper deployment in 3 steps! MuMu emulat
- **Games** -> **EX Skill Effects** -> **Off**
- **Graphics** -> **Battle Screen Vertical Letterbox** -> **Off**
- Manually raise the camera view in the cafe to the highest position, preferably stacking all furniture on the far right side of the screen.
3. Additional Game Settings for Steam Global Version
3. Additional Game Settings for PC Version
- **Graphics** -> **Display Mode** -> **Windowsed**
- **Graphics** -> **Aspect Ratio** -> **16:9**
- **Control** -> **Display Shortcut Icon** -> **Off**
- Close software that displays frame rate and usage in the game window, as they may block the UI.
## Deployment
Expand All @@ -42,7 +44,11 @@ Double-click BAAH.exe to open the interface.

In Server Configuration, select your BA server.

In Emulator Configuration, modify the port number to your emulator's ADB debugging port. (If you are using an emulator)
If you are using an emulator, modify the port number to your emulator's ADB debugging port in the Emulator Configuration.

If you're using an emulator and want to auto-start it, enter the emulator path in the Emulator Configuration.

If you're using the Japanese Server PC version and want to auto-start the game, enter the game path (typically at ...\YostarGames\BlueArchive_JP\BlueArchive.exe) in the Emulator Configuration.

In Task Execution Order, enable the task flow or click the Quick Call Task button to run tasks.

Expand Down
25 changes: 25 additions & 0 deletions src/en_US/donate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Donate

If you really like BAAH and want to buy the developer a milk tea (or something else), please read on.

## Paid Donation

You can purchase Mirror-chan CDK and use it for downloads and updates. This not only allows the developer to receive a commission, but also enables high-speed downloads/updates.

## Free Donation

Here are the payment codes or Afdian links for the developers.

::: warning
This is a donation, and there is no obligation for the developers to refund it, either legally or morally.

<p style="color:red;font-weight: bold">Please pay with caution</p>

<p style="color:red;font-weight: bold">Please pay with caution</p>

<p style="color:red;font-weight: bold">Please pay with caution</p>
:::

::: details sanmusen214
<AfdianCard />
:::
2 changes: 1 addition & 1 deletion src/en_US/download.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ You can join one of the following QQ groups for usage help

== Windows

<a href="https://pan.quark.cn/s/319faf23496c" class="VPButton medium brand">Quark Cloud Download</a>
<a href="https://pan.quark.cn/s/49fab9d220ec" class="VPButton medium brand" title="Extraction Code: W3dc">Quark Cloud Download</a>
<a href="https://mirrorchyan.com/en/projects?rid=BAAH" class="VPButton medium alt">MirrorChyan Download (CDK Required)</a>
<a href="https://github.com/BlueArchiveArisHelper/BAAH/releases" class="VPButton medium alt">GitHub Release</a>
<a href="https://api.blockhaity.qzz.io/docs/#/api-doc/getbaah" class="VPButton medium alt">BlockHaity's API</a>
Expand Down
Binary file modified src/public/img/sweep-level/area_2.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions src/zh_CN/docs/manual/introduction/assault.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@
该功能可以使用总力战1号队使用助战学生,请提前在队伍中空出一个学生位置。

1. 来到游戏配队界面,进入借用学生的界面。
2. 选择点击`总力战助战学生`按钮。
2. 选择点击 `总力战助战学生` 按钮。
![助战学生](/img/assault/assault_helper_1.webp)
3. 在弹出的窗口中,使用鼠标左键框起需要借用的学生。
![选择学生](/img/assault/assault_helper_2.webp)

> :memo: **注:** 如果需要借用的是后排学生,请勾选`总力战助战学生是否是后排角色` 启用此功能。仅需在后排空出一个学生位置,并且圈起的学生为需要借用的后排学生即可。
> :memo: **注:** 如果需要借用的是后排学生,请勾选 `总力战助战学生是否是后排角色` 启用此功能。仅需在后排空出一个学生位置,并且圈起的学生为需要借用的后排学生即可。

14 changes: 10 additions & 4 deletions src/zh_CN/docs/manual/quick-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ description: 3 步完成 BlueArchive Aris Helper 部署!MuMu 模拟器设置
- **游戏** -> **技能动画** -> **关**
- **画面** -> **战斗时上下黑边** -> **关**
- 咖啡厅的摄像机视角手动拉到了最高,最好将家具全堆在屏幕最右侧。
3. 国际服 Steam 版游戏本体附加设置
3. PC 版游戏本体附加设置
- **画面** -> **画面模式** -> **视窗模式**
- **画面** -> **画面比例** -> **16:9**
- **操作** -> **快捷键图示显示** -> **关**
- 关闭在游戏窗口显示帧率占用等功能的软件,它们很可能会挡住UI。

Expand All @@ -39,10 +41,14 @@ description: 3 步完成 BlueArchive Aris Helper 部署!MuMu 模拟器设置

双击 BAAH.exe 打开界面。

在服务器设置中,选择你游玩的ba服务器
在服务器设置中,选择你游玩的 BA 服务器

如果使用的是模拟器,请在模拟器设置中,修改端口号为你的模拟器adb调试端口。

如果使用的是模拟器,并且希望自动打开模拟器,请在模拟器设置中填写模拟器路径。

如果使用的是日服 PC 版,并且希望能自动打开游戏,请在模拟器设置中填写游戏路径(通常为…\YostarGames\BlueArchive_JP\BlueArchive.exe)。

在任务执行顺序设置中,启用任务流或点击快速执行按钮运行任务。


Expand Down Expand Up @@ -159,9 +165,9 @@ docker run -d --name BAAH -p 8000:8000 ghcr.io/BlueArchiveArisHelper/baah:latest

随后打开浏览器,打开 `http://<your-server-ip>:8000`

在服务器设置中,选择你游玩的ba服务器
在服务器设置中,选择你游玩的 BA 服务器

如果使用的是模拟器,请在模拟器设置中,修改端口号为你的模拟器adb调试端口
如果使用的是模拟器,请在模拟器设置中,修改端口号为你的模拟器adb调试端口

在任务执行顺序设置中,启用任务流或点击快速执行按钮运行任务。

Expand Down
25 changes: 25 additions & 0 deletions src/zh_CN/donate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# 捐赠

如果你真的很喜欢BAAH,且想要请开发者一杯奶茶(或其他)的话,请往下看。

## 有偿捐赠

你可以购买Mirror酱CDK,并在下载和更新中使用它,这不仅可以让开发者获得分成,而且还可以实现高速下载/更新。

## 无偿捐赠

这里列出了开发者们的收款码或爱发电,

::: warning
这属于捐赠,无论是从法律上还是道德上都没有让开发者退还的义务。

<p style="color:red;font-weight: bold">请谨慎付款</p>

<p style="color:red;font-weight: bold">请谨慎付款</p>

<p style="color:red;font-weight: bold">请谨慎付款</p>
:::

::: details sanmusen214
<AfdianCard />
:::
3 changes: 2 additions & 1 deletion src/zh_CN/download.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,11 @@ description: 免费获取 BlueArchive Aris Helper 自动化脚本!Windows 推

== Windows

<a href="https://pan.quark.cn/s/319faf23496c" class="VPButton medium brand">夸克网盘下载</a>
<a href="https://pan.quark.cn/s/49fab9d220ec?pwd=W3dc" class="VPButton medium brand">夸克网盘下载</a>
<a href="https://mirrorchyan.com/zh/projects?rid=BAAH" class="VPButton medium alt">Mirror酱下载(需要CDK)</a>
<a href="https://github.com/BlueArchiveArisHelper/BAAH/releases" class="VPButton medium alt">GitHub Release</a>
<a href="https://api.blockhaity.qzz.io/docs/#/api-doc/getbaah" class="VPButton medium alt">BlockHaity's API</a>
<a href="https://cnb.cool/BlockHaity/BAAH-releases/-/releases" class="VPButton medium alt">Cloud Native Build</a>

== macOS

Expand Down