Various Changes (#533)

* Add Shield Blocking Emote For Two NPC's

* Fix KARAMBWAN HP Restore Amount

* Add Link Command To Discord Bot

* Github Actions Update
This commit is contained in:
Josh Shippam
2022-08-22 05:22:00 +01:00
committed by GitHub
parent 7514826803
commit 5dea59f903
6 changed files with 38 additions and 7 deletions
+13 -4
View File
@@ -1,4 +1,4 @@
# This workflow will build a Java project with Maven
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Java CI with Maven
@@ -11,9 +11,7 @@ on:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 1.8
@@ -21,4 +19,15 @@ jobs:
with:
java-version: 1.8
- name: Build with Maven
run: mvn -B clean install
id: build
run: |
mvn -B clean package
mkdir -p ~/artifacts
cp "2006Scape Client/target/client-1.0-jar-with-dependencies.jar" ~/artifacts/Client.jar
cp "2006Scape Server/target/server-1.0-jar-with-dependencies.jar" ~/artifacts/Server.jar
cp -r "2006Scape Server/data" ~/artifacts/
- name: Publish build to GH Actions
uses: actions/upload-artifact@v2
with:
path: ~/artifacts/*
name: 2006Scape-Build
@@ -11,8 +11,9 @@ import com.rs2.game.players.Player;
public enum NpcEmotes {
MAN(new int[] {1, 2, 3, 4, 5, 6}, 422, 1834, 836),
AL_KHARID_WARRIOR(new int[] {18}, 451, 404, 836),
GUARD(new int[] {9, 10}, 412, 404, 836),
AL_KHARID_WARRIOR(new int[] {18}, 451, 1156, 836),
GUARD(new int[] {9}, 412, 1156, 836),
GUARD_NO_SHIELD(new int[] {10}, 412, 404, 836),
GARGOYLE(new int[] {1610, 1611}, 1517, 1519, 1518),
SKELETAL_WYVERN(new int[] {3068}, 2989, 2988, 2987),
BAT(new int[] {412, 78}, 30, 31, 36),
@@ -24,7 +24,7 @@ public class Food {
MANTA(391, 22, "Manta Ray", 0, "Food", false),
SHARK(385, 20, "Shark", 0, "Food", false),
LOBSTER(379, 12, "Lobster", 0, "Food", false),
KARAMBWAN(3144, 2 + Misc.random(4), "Karambwan", 0, "Food", false),
KARAMBWAN(3144, 18, "Karambwan", 0, "Food", false),
TROUT(333, 7, "Trout", 0, "Food", false),
SALMON(329, 9, "Salmon", 0, "Food", false),
SWORDFISH(373, 14, "Swordfish", 0, "Food", false),
@@ -32,6 +32,7 @@ public class JavaCord {
api.addListener(new Forum());
api.addListener(new Hiscores());
api.addListener(new Issues());
api.addListener(new Link());
api.addListener(new Online());
api.addListener(new Players());
api.addListener(new Vote());
@@ -11,6 +11,8 @@ public class Commands implements MessageCreateListener {
Message message = event.getMessage();
if (message.getContent().equalsIgnoreCase(JavaCord.commandPrefix + " commands")) {
event.getChannel().sendMessage("```fix"
+ System.lineSeparator() +
"::link"
+ System.lineSeparator() +
"::forum/::forums"
+ System.lineSeparator() +
@@ -0,0 +1,18 @@
package com.rs2.integrations.discord.commands;
import org.javacord.api.entity.message.Message;
import org.javacord.api.entity.user.User;
import org.javacord.api.event.message.MessageCreateEvent;
import org.javacord.api.listener.message.MessageCreateListener;
public class Link implements MessageCreateListener {
@Override
public void onMessageCreate(MessageCreateEvent event) {
Message message = event.getMessage();
User user = message.getAuthor().asUser().get();
if (message.getContent().equalsIgnoreCase("::link")) {
event.getChannel().sendMessage(user.getMentionTag() + ", Please check your DM's to continue.");
user.sendMessage("Please copy/paste the following in-game to link your Discord account: \n ```::link " + user.getIdAsString() + "```");
}
}
}