This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import requests as r | |
| from base64 import urlsafe_b64decode as b64decode | |
| from typing import List, Optional | |
| import json | |
| 订阅服务器 = "*" | |
| def query(url: str) -> Optional[str]: | |
| resp = r.get(url, timeout=30) | |
| if resp.status_code == 200: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| typedef unsigned long number_t; | |
| const char *SMALL_NUMBERS[] = {"zero", "one", "two", "three", | |
| "four", "five", "six", "seven", | |
| "eight", "nine", "ten", "eleven", | |
| "twelve", "thirteen", "fourteen", "fifteen", | |
| "sixteen", "seventeen", "eighteen", "nineteen"}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Unofficial | |
| [[mapnames]] | |
| name_zh = "2019 II:Metal Gear Blart" | |
| name = "2019 II:合金装备" | |
| maps = [ | |
| "2019ii_fourth_plaza", | |
| "2019ii_fourth_streets", | |
| "2019ii_blart_battle", | |
| "2019ii_fourth_outside", | |
| "2019ii_fourth_getup", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import asyncio | |
| import logging | |
| from asyncio import Queue | |
| from dataclasses import dataclass | |
| from random import randint | |
| from uuid import UUID, uuid4 | |
| from sys import stdout | |
| logging.basicConfig(level=logging.DEBUG, filename="main.log") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import logging | |
| from argparse import ArgumentParser | |
| from pathlib import Path | |
| from sys import exit | |
| from win32com.client import Dispatch, CDispatch | |
| logging.basicConfig(level="INFO") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //! ```toml | |
| //! # cargo.toml | |
| //! [package] | |
| //! name = "screenoff" | |
| //! version = "0.1.0" | |
| //! edition = "2021" | |
| //! description = "通过 Windows API 关闭电脑显示屏" | |
| //! # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |
| //! | |
| //! [dependencies] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # 将地图文件拆分成两份(vtf 或 非 vtf) | |
| # 地图文件需要提前解包并重命名 | |
| # 依赖工具: | |
| # 1. https://github.com/ValvePython/vpk vpk 解包 | |
| # 2. Left 4 Dead 2 Authoring Tools vpk.exe 打包 | |
| from argparse import ArgumentParser | |
| from pathlib import Path | |
| from subprocess import run | |
| from vpk import open as open_vpk |
OlderNewer