-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release 1.1 (still no points limit but who asked?)
Ayo it's working! I think... Ok we're gonna say it is!
- Loading branch information
Showing
28 changed files
with
954 additions
and
53 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
## config.yml | ||
The default config. | ||
A config for 4 players on the map in [Towers_Map.zip](https://github.com/GhostCode920/Towers/blob/main/librairies/Towers_Map.zip) | ||
|
||
## GameAPI.jar | ||
The API I created and used to make the game. | ||
You don't need to install it to use the plugin. | ||
|
||
## lombok.jar | ||
Used to have the @Getter, @Setter, @AllArgsConstructor... classes and make the code cleaner. | ||
You will need it if you want to edit the code. | ||
|
||
## spigot.jar | ||
The spigot build I use. It is 1.8.8. | ||
|
||
## Towers.jar | ||
It contains the compiled plugin. | ||
All librairies are already in (GameAPI too, you don't need it on your server for it to works) | ||
|
||
## Towers_Map.zip | ||
The Map used for the Game with the [default config](https://github.com/GhostCode920/Towers/blob/main/librairies/config.yml). |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
game-config: | ||
max-players: 4 | ||
map-name: "Towers" | ||
first-timer: | ||
min-players: 2 # for 2 players, just put 3 here, so it isn't called | ||
seconds: 60 | ||
fast-timer: | ||
min-players: 4 | ||
seconds: 10 | ||
|
||
|
||
locations: | ||
waiting-spawn: | ||
x: 0.5 | ||
y: 201.0 | ||
z: 0.5 | ||
yaw: 90.0 | ||
pitch: 0.0 | ||
spawn-protection-radius: 4 # nobody can break/place blocks in that radius (radius of the cube lol) | ||
blues-spawn: | ||
x: -83.5 | ||
y: 92.0 | ||
z: 0.5 | ||
yaw: -90.0 | ||
pitch: 0.0 | ||
reds-spawn: | ||
x: 84.5 | ||
y: 92.0 | ||
z: 0.5 | ||
yaw: 90.0 | ||
pitch: 0.0 | ||
|
||
goals: | ||
block-type: ENDER_PORTAL_FRAME # all avaible blocks here: https://helpch.at/docs/1.8.8/org/bukkit/Material.html; Don't put an item or it won't work | ||
check-radius: 1 # 0 = only the block, 1 = all blocks around (not above and under), 2 = all blocks around and all the blocks around the blocks... | ||
no-block-radius: 3 # same as above but with all possible y | ||
blue-goal: # The middle block of where the blues need to go to goal | ||
x: 84 | ||
y: 100 | ||
z: 0 | ||
red-goal: # The middle block of where the reds need to go to goal | ||
x: -84 | ||
y: 100 | ||
z: 0 | ||
|
||
build-height-limit: 140 | ||
|
||
number-of-instances: 1 | ||
|
||
# this can be modified or totally deleted using the API included in the plugin | ||
bungeecord: | ||
enabled: true | ||
if-enabled: | ||
return-server: lobby | ||
else: | ||
return-world: lobby | ||
|
||
|
||
|
||
messages: | ||
prefix: "§c[Towers] " | ||
join: "§a+ %name% §7(%online%/%max%)" | ||
leave: "§c- %name% §7(%online%/%max%)" | ||
leave-in-game: "%color%%name% §cdisconnected! He may rejoin later." | ||
team-select: "§aYou joined the %color%%team% Team§a!" | ||
no-game: "§cThere is no game avaible now. Please try later." | ||
joining: "§bAdding you into a game..." | ||
players-only: "§cThis command is reserved to players." | ||
died-unknown: "%color%%name% §edied." | ||
died-player: "%color%%name% §ewas killed by %killer%." | ||
no-build: "§cYou cannot build here!" | ||
score: "%color%%name% §escore a point! §9%bluepoints%§7-§c%redpoints%" | ||
build-height-limit: "§cYou cannot build that high." | ||
countdown-cancelled: "§cCountdown cancelled. Not enough players to start the game." | ||
countdown-multiple: "§aStarting in §e§l%timer% seconds§a." | ||
countdown-one-second: "§aStarting in §e§l1 second§a." | ||
countdown-zero: "§2Game started! GLHF" | ||
teams: # it isn't recommanded to change teams color right now (example: from blue to yellow), because the armor color WON'T change. Thanks! | ||
blue: | ||
name: "Blue" | ||
color: "§9" | ||
red: | ||
name: "Red" | ||
color: "§c" | ||
scoreboard: | ||
title: "§c§lTowers" | ||
blue-points: "%color%%team% Points§7: §b%bluepoints%" | ||
red-points: "%color%%team% Points§7: §b%redpoints%" | ||
current-team: "§7Your team: %color%%team%" | ||
kills: "§7Kills: §b%kills%" | ||
deaths: "§7Deaths: §b%deaths%" | ||
server-ip: "§bBy GhostCode#1832 (big ad)" |
Binary file not shown.
Binary file not shown.
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package dev.ghosty.gameapi; | ||
|
||
import dev.ghosty.gameapi.config.Config; | ||
|
||
public interface Game { | ||
|
||
public GameInfo getGameInfo(); | ||
|
||
public Config getConfiguration(); | ||
|
||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
package dev.ghosty.gameapi; | ||
|
||
import javax.annotation.Nonnegative; | ||
|
||
public interface GameInfo { | ||
|
||
/** | ||
* <p>The game name | ||
* <p>Example: Bedwars | ||
*/ | ||
public String gameName(); | ||
|
||
/** | ||
* <p>The maximum of players that can be in the game | ||
* <p>Example: 16 | ||
*/ | ||
@Nonnegative | ||
public int maxPlayers(); | ||
|
||
/** | ||
* <p>The minimum of players to get the slow timer starting | ||
* <p>Example: 8 | ||
* @see GameInfo#slowTimer() | ||
*/ | ||
@Nonnegative | ||
public int minPlayersForSlowTimer(); | ||
/** | ||
* <p>The timer for when there is {@link GameInfo#minPlayersForSlowTimer() X} players in the game | ||
* <p>Example: 90 | ||
* <p>The returned value must be in seconds | ||
* @see GameInfo#minPlayersForSlowTimer() | ||
*/ | ||
@Nonnegative | ||
public int slowTimer(); | ||
/** | ||
* <p>The minimum of players to get the fast timer starting | ||
* <p>Example: 12 | ||
* @see GameInfo#fastTimer() | ||
*/ | ||
@Nonnegative | ||
public int minPlayersForFastTimer(); | ||
/** | ||
* <p>The fast timer for when there is {@link GameInfo#minPlayersForFastTimer() X} players in the game | ||
* <p>Example: 15 | ||
* <p>The returned value must be in seconds | ||
* @see GameInfo#minPlayersForFastTimer() | ||
*/ | ||
@Nonnegative | ||
public int fastTimer(); | ||
|
||
@Nonnegative | ||
public int numberOfInstances(); | ||
|
||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package dev.ghosty.gameapi.config; | ||
|
||
import org.bukkit.configuration.file.FileConfiguration; | ||
|
||
public final class Config extends Configuration { | ||
|
||
public Config(String pluginName) { | ||
super("plugins/"+pluginName+"/config.yml"); | ||
} | ||
|
||
public Config(FileConfiguration config) { | ||
super(config); | ||
} | ||
|
||
} |
Oops, something went wrong.