Team based challenges are now handled differently from the normal ones.
When the game or challenge starts, instead of spawning all players
with the default team spawn method, they are teleported according
to their team. For example, if a player is on the blue team, he
will be teleported on the blue side of the map. Moreover, teams
are now generated properly, by diving the total number of players by
two. One drawback, that will be fixed in a next commit, is that team
challenges require an even amount of players.
+Added better schematic support
+Fixed schematics not sending block updates to nearby players
+Added win room schematics
*Tweaked some of the win rooms
+Added sounds to the Lava Trap win effect.
Previously, a new thread was created to display the description
of a challenge. Instead of creating a new one, only a single
bukkit runnable is now created. With that change, when the challenge
is skipped, the correct description will show up instantaneously.
Beastmaster wolf spawning suffered from the same issue as the Wizards
"Summon Wolves" spell: spigot has an issue when setting an owner to a
wolf or ocelot without a previous owner. See SpigotUtil for details.
Elo and Division should be displaying properly
Cleaned the code up a bit
Added endElo() to Game.java to handle team Elo code
Added event listener to check for GameState.End in TDM to call endElo()
This fixes the Summon Wolves spell in Wizards.
Explanation:
- Wolves keep track of their most recent owner.
- When a wolf is assigned a new owner, it updates the data
watcher with the new owner's UUID
- During this process, the old owner's UUID is checked
against the new one
- If the wolf didn't have a previous owner, the old owner's
UUID is the empty string.
- UUID.fromString() is called on the empty string, and throws
an exception.
The new challenge selection system, picks a random challenge from
the list as a starting point. Once the challenge is ended, the next
one in the list will be selected. That process continues, until the
index is out of bounds, and from that point, a new starting point
will be selected. During that process, any challenge that is picked,
is also reviewed to make sure it's suitable according to the player
count. If that's not the case, the selection process will continue
until one challenge is found. If there is no appropriate challenge,
the game will be ended.
In addition to those changes, there are a couple of bug fixes and changes.
At first, some methods that keep track of player lists were renamed and
secondly, the enchantment lore is now hidden on challenges that use items.
Consequently, elo code is actually being called now
Bukkit.broadcastMessage calls have shown where things are breaking
handleElo() added to EloManager to facilitate movement of team elo code
preparing to use EloManager's getNewRatings() method to
calculate team elos
+ Support for relative copy position from with //copy from worledit in
schematics
+ Better block selection in bounding box in UtilBlock
+ Goal selector utils for entities
+ Global hide and show methods for players
+ Win effects and game modifiers
+ Tweaked player disguises
+ Added clean room generator to arcade games, previously normal flat
world
+ Animation utils
* Edited some particles, hats and death animations
Previously, a player would erratically become a spectator if s/he
spammed the "spectate next player" action between rounds (i.e.
left-click while spectating a player).
EloRanking turned on for Domination, Team Deathmatch, Turf Wars, CTF
Database QoL changes made to EloManager and EloRepository
--Unfortunately, Database still seems to not be updating properly
--Something on my end, or something to do with the queries? Unsure.
Players that die during a challenge have the ability to fly
around as spectators. Although, once the challenge was ended
their fly mode was removed and they would fall for a very short
amount of time, which was noticeable. With that fix, players
now get reset once they are teleported to the spawn locations
of the next challenge. That happened because during the player
reset and spawn teleportation, the map would be generated, as a
result, causing a very small notable delay.
Moreover, win placement was fixed. In the previous version, the
third player would appear as second and the second player would
appear as the third one. The cause of this issue was that, after
the second and the third player is added to the winner list, the
last player that is remaining alive is added as first. To fix that,
I've implemented a swap method that changes the location of the
second with the third player.