86 lines
1.4 KiB
Markdown
86 lines
1.4 KiB
Markdown
# lastz-giftcenter-cli
|
||
|
||
Last-Z Gift Center 的命令列工具,支援查詢帳號資訊、兌換禮品碼,以及查看玩家資料、遊戲公告等。
|
||
|
||
## 安裝
|
||
|
||
```bash
|
||
pip install -r requirements.txt
|
||
```
|
||
|
||
## 設定
|
||
|
||
在專案根目錄建立 `.env` 檔案,填入你的 UID:
|
||
|
||
```
|
||
UID=your_uid_here
|
||
```
|
||
|
||
或在執行指令時以 `--uid` 旗標直接指定。
|
||
|
||
## 使用方式
|
||
|
||
### 查詢帳號資訊
|
||
|
||
```bash
|
||
python giftcenter.py login
|
||
```
|
||
|
||
輸出範例:
|
||
|
||
```
|
||
登入成功
|
||
名稱 : 玩家名稱
|
||
UID : 1234567890
|
||
SID : S001
|
||
國家 : TW
|
||
等級 : 50
|
||
```
|
||
|
||
### 兌換禮品碼
|
||
|
||
```bash
|
||
python giftcenter.py redeem <禮品碼>
|
||
```
|
||
|
||
### 查看完整玩家資料
|
||
|
||
```bash
|
||
python giftcenter.py profile
|
||
```
|
||
|
||
輸出範例:
|
||
|
||
```
|
||
名稱 : LoTimmy
|
||
UID : 1234567890
|
||
總部等級 : 29
|
||
戰力 : 160278330
|
||
點贊量 : 1586
|
||
殺敵數量 : 38984
|
||
送禮等級 : 8
|
||
稱王次數 : 3
|
||
聯盟 : 1945-Govs
|
||
聯盟縮寫 : 45GV
|
||
```
|
||
|
||
### 遊戲公告與下載資訊(免 UID)
|
||
|
||
```bash
|
||
python giftcenter.py news # 遊戲版本公告
|
||
python giftcenter.py info # 地區與最新 APK 下載連結
|
||
```
|
||
|
||
### 指定 UID(覆蓋 .env)
|
||
|
||
```bash
|
||
python giftcenter.py --uid <uid> login
|
||
python giftcenter.py --uid <uid> redeem <禮品碼>
|
||
python giftcenter.py --uid <uid> profile
|
||
```
|
||
|
||
## 依賴套件
|
||
|
||
- [requests](https://docs.python-requests.org/)
|
||
- [python-dotenv](https://github.com/theskumar/python-dotenv)
|