Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

port #1

Merged
merged 4 commits into from
Aug 29, 2024
Merged
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
34 changes: 34 additions & 0 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build

on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true

- name: Setup JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
gradle-version: 8.1.1

- name: Run build
run: gradle build

- name: Upload files
uses: actions/upload-artifact@v4
with:
name: build and source jars
path: build/libs/*.jar
retention-days: 7
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ public class AttackConfig {
ForgeConfigSpec.Builder builder = new ForgeConfigSpec.Builder();
builder.push("Potion Level Fix").comment("These settings will only apply when you first enter the world. Subsequently, you can control the attributes in-game.");
PROBABILITY = builder
.comment("The larger this number, the higher the probability of a subsequent attack. Range:0~100, default: 30")
.comment("The larger this number, the higher the probability of a subsequent attack. Range:0~100, default: 15.0")
.define("Attack Again Probability", 15.0);
DAMAGE = builder
.comment("The damage percentage of a subsequent attack, default: 1")
.define("Damage Percentage", 0.35);
.comment("The damage percentage of a subsequent attack, default: 0.35")
.define("Attack Again Percentage", 0.35);
FREQUENCY = builder
.comment("The frequency of subsequent attacks")
.define("Damage Frequency", 1.0);
.comment("The frequency of subsequent attacks, default: 1.0")
.define("Attack Again Frequency", 1.0);
builder.pop();
CONFIG = builder.build();
}
Expand Down
5 changes: 5 additions & 0 deletions src/main/resources/assets/attack_again/lang/en_us.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"attribute.name.attack_again.attack_probability": "Attack Again Probability",
"attribute.name.attack_again.attack_damage": "Attack Again Percentage",
"attribute.name.attack_again.attack_frequency": "Attack Again Frequency"
}
5 changes: 5 additions & 0 deletions src/main/resources/assets/attack_again/lang/zh_cn.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"attribute.name.attack_again.attack_probability": "追击概率",
"attribute.name.attack_again.attack_damage": "追击伤害",
"attribute.name.attack_again.attack_frequency": "追击次数"
}
Loading