Commit Graph

527 Commits

Author SHA1 Message Date
cmastudios
12b5f8350f Handle deaths after they have been counted and rewarded.
This prevents a problem where players could be rewarded after the game ends
2013-09-10 18:11:21 -05:00
cmastudios
dbac21aa44 Add MySQL kill/death logging support. Closes gh-658
War now logs kills and deaths to a MySQL database. Records are created for
every player at the end of each round with the current date and amount of
times the player killed and was killed for the entire round. It has built
in support for automatic & configurable log clearing past a certain date
(default is 1 week).
2013-09-10 17:51:30 -05:00
cmastudios
0dc7ac837f Added configurable airstrikes, based on work from @grinning. 2013-09-10 17:51:03 -05:00
cmastudios
26ec11f46c Allow the use of multiple items in rewards.
This also allows the use of XP and points as rewards.
2013-09-10 17:51:02 -05:00
cmastudios
17aef5e162 Add base for configurable KS rewards. Fixes gh-506
Killstreak rewards can be configured in the set.war.killstreak section of
war.yml. Rewards will only be applied to players if the team/warzone has
KILLSTREAK set to true.

The configuration section will get populated on generation of war.yml, or
may be manually added to older configurations.

Currently the system supports messaging the entire warzone and just the
attacker. It only supports rewards of items and health at the moment; more
are expected to arrive.

This commit also moves XPKILLMETER into the team-specific section of the
config.
2013-09-10 17:51:02 -05:00
cmastudios
c66120c4fa Fixes gh-611, gh-612 - Add kill count system and kill meters with XP.
The killstreak counter shows a message if the player has more than 5
kills. I have also added an example reward system with points, but did not
enable it yet (needs discussion).

Through the warzone option xpkillmeter the XP level will get updated with
your current kill streak amount. This gets reset every time you die and
is added to every time you kill a player. If this option is enabled,
players cannot gain XP in the warzone.
2013-09-10 17:50:40 -05:00
cmastudios
2738d2e358 Add scoreboard features and configuration options. Fixes gh-623, gh-45
With the new warzone configuration property "scoreboard", zone makers can
set the type of scoreboard to be used. This may be "none", "points", or
"lifepool". If the scoreboard type is not "none", then a scoreboard will
be shown on the right side of the screen in the warzone. The shown
scoreboard will display the configured option.

Also, 3-year-old feature request COMPLETED! Use the command
/zone <warzone-name> scoreboard to view a scoreboard from anywhere.
2013-09-10 17:27:05 -05:00
cmastudios
b367cc53ad Add ability to bypass warzone lobby. Fixes gh-669
If a zone has the property autojoin & autoassign set to true, then
players will be directly assigned to a team when they go through the
Warhub portal for the zone and brought back to the Warhub when they
leave the zone.
2013-09-07 18:10:23 -05:00
cmastudios
890e78fd5d TeamKind cleanup, warning fixes, closes gh-631
TeamKind has been changed to store colors in a DyeColor object instead
of using a byte value store. This improves readability and makes the
code future-proof.

All listeners are now unregistered when the plugin gets unloaded. This
removes the need for listeners to check if War is loaded and prevents
duplicate registration. I would prefer if the ability to unload and load
the War plugin was completely removed, however, as there are plugins out
there such as PlugMan that are dedicated to cleanly reloading plugins.

The main purpose of this was to clean up all issues and problems
reported by the eclipse java IDE. 0 warnings are shown by the IDE now.
2013-09-04 23:27:27 -05:00
cmastudios
ea0df4f22b Store loadouts using bukkit stack seriliazer. 2013-08-09 18:45:27 -05:00
cmastudios
5a571e7329 Add support for multiple spawn points. Closes gh-628.
/setteam <color> now will add an additional spawn point if the team already
exists.

When a player joins a team in a warzone, they will be sent to any one of
their teams spawn points, picked at random.

This change required major modifications to the underlying teams subsystem
in order to support multiple spawn points for the team.
2013-08-08 23:27:09 -05:00
cmastudios
200ae92e0f Remove "Can't re-enter spawn" task.
This test task is incompatible with additions to War regarding teams.

This method of preventing players of receiving spawn protection is
currently extremely buggy and there has to be a better way to fix the issue
at hand.

@taoneill please email me if there is any serious reason this task is
needed, otherwise it just deteoriates from the War experience. Numerous
times I have played War, I have been bumped out of a warzone even due to
this. There seems to be no need for it. I can revert this commit if needed.

One possible solution could be disabling all protections for anyone who
returns to their spawn, such as like how loadout switching is prevented
after leaving spawn. Another solution could be preventing multiple teams
from taking a flag while another flag is on the run.

Please leave your ideas in the comments or email me.
2013-08-08 23:19:00 -05:00
cmastudios
c56fac6c34 Make invisible spawns hidden. Closes gh-627 2013-08-08 17:25:15 -05:00
cmastudios
bf3795ded1 Minecraft 1.6 compatibility.
Update health references to use double-precision floating point numbers instead
of integers due to minecraft spec change. Update Java to 1.6. Update bukkit
version.
2013-07-26 22:22:27 -10:00
cmastudios
fb375002de Fixes gh-239. Add joinmidbattle zonecfg option.
With this option set to false, new players cannot join the zone if the
zone already has enough players on all teams necessary to play.
2013-07-13 17:00:56 -05:00
cmastudios
ebd95a4e16 Fixes gh-410. Prevent /join in autoassign zones. 2013-07-13 16:32:21 -05:00
taoneill
756ca37a82 Merge pull request #641 from cmastudios/weselection
Create zones with WorldEdit cuboid selections. Closes #411. Thanks @cmastudios!
2013-07-01 10:41:54 -07:00
taoneill
bf7e1a9847 Merge pull request #638 from cmastudios/hotfix-cslotsteal
Fix item smuggling and game end bugs. Thanks @cmastudios!
2013-07-01 10:31:00 -07:00
cmastudios
13396f85a4 Fixes gh-645, gh-643 - Load player armor when using playerloadoutasdefault 2013-06-29 23:31:01 -05:00
cmastudios
c4b268910b Refresh player tags anytime players leave a zone
This fixes a bug where player tags are not reset when a zone ends normally
or when the zone is reset.
2013-06-11 23:28:26 -05:00
cmastudios
5c954a19b4 Make sure the selection is a cuboid 2013-06-11 23:11:25 -05:00
cmastudios
21688ba4d0 Create zones with WorldEdit cuboid selections
The WorldEdit API is utilized to allow the use of WorldEdit selections
when creating or modifying a warzone. If the current player has a
WorldEdit selection when the /setzone command is used, this selection will
be used for the zone's corners.
2013-06-08 22:55:35 -05:00
cmastudios
728111217e Fix game end TP bugs caused by a5cd846
Remove players from team before teleporting them back to lobby or
rallypoint.
2013-05-31 17:03:36 -05:00
cmastudios
3b0b0c6720 Fixes gh-630. Close open inventories before reset.
This fixes issues with item smuggling via crafting inventories. The
player's inventory is closed before they are kicked from the zone or a
respawn.
2013-05-30 19:09:10 -05:00
taoneill
da14a8fc4d Merge pull request #635 from cmastudios/multiworld-loadout-hotfix
Fix incompabilities with per-world inventories.
2013-05-20 15:24:23 -07:00
cmastudios
a5cd846b2a Fixes gh-533
Prevents players from teleporting or moving out of a warzone in play.
2013-05-18 16:49:53 -05:00
cmastudios
423654d21e Fix incompabilities with per-world inventories.
War saved a player's state before they were teleported into the warzone.
This causes issues if the lobby is in another world and the server is
using plugins to manage per-world inventories. Essentially, the player is
getting their inventory from world A saved, teleported to warzone in world
B, their state being restored in B, then teleported to A. Per-world
inventory plugins save and restore inventories on every
cross-world-teleport. This causes blank inventories when a player joins a
warzone and the player gets the items from the zone when they leave.

This issue is easily fixed by teleporting players to the warzone's world
before saving their state. This is merely a standardization of state
save/restore order.
2013-05-18 16:47:21 -05:00
taoneill
e3e20fc704 Merge pull request #610 from cmastudios/colored-names
Add TagAPI support to War
2013-05-04 10:07:47 -07:00
taoneill
856d697d79 Merge pull request #587 from cmastudios/fix-colored-armor
Fix loadout issues + permission-restricted loadouts, thanks @cmastudios!!!
2013-05-04 10:02:49 -07:00
taoneill
4317b2fc8c Merge pull request #579 from cmastudios/zone-permissions
Add team-based permission requirement
2013-05-04 09:53:39 -07:00
taoneill
2d91b3cf90 Updating version to 1.8-PREVIEW (Nimitz) 2013-05-04 12:48:56 -04:00
cmastudios
d724f5a382 Closes gh-617, gh-609, gh-514, gh-319, tag gh-589. Add support for
permission specific loadouts.

Loadouts can be defined with a permission which can limit who can access
the loadout, in mostly the same manner as I did in the zone-permissions
commits. The permission can be used to only allow say VIP and above to get
a certain loadout (for donation benefits) or to allow the server's lower
ranks a class only (to allow lower ranks to survive faced with the server's
experienced players).

This is controlled by an additional argument to /zonecfg.
Example: /zonecfg loadout:vip:server.ranks.VIP - allow only VIP players
access to the vip loadout.
To remove the permission, re-make the loadout without the permission
parameter.
Example: /zonecfg loadout:vip - remove the permission requirement for the
vip loadout.

To allow a lower rank access to a loadout only, you can use your permission
manager's feature of negating a permission (if supported by the plugin).
Example: /pex group recruit add server.loadout.noob, /pex group builder add
-server.loadout.noob - allow only recruits to have access to a loadout
which requires the permission "server.loadout.noob" (with PermissionsEX).
2013-03-22 22:33:38 -05:00
cmastudios
e6c1e64fef Add support for new loadout system to base classes and configuration
subsystem.
2013-03-22 22:09:29 -05:00
cmastudios
dd88a5ccbe Add new loadout class support to the existing loadout subsystem. 2013-03-22 22:01:02 -05:00
cmastudios
0955df7503 Added new classes to manage loadouts instead of the hashmap method. 2013-03-22 21:59:03 -05:00
cmastudios
ce72ba36fa Add permission based access to warzones
Adds a team default permission configuration option. Default is
war.player. It is modifiable at the zone level and the team level. In
autoassign zones where there is a mix of teams that some players have
access to and some that they don't, the player will only ever be placed
in a team he can access. You can't /join a team you don't have
permission to join.
2013-03-21 17:15:45 -05:00
taoneill
e83c53061d Update version to 1.7.4.
Updated Bukkit dependency to 1.4.7-R1.0.
2013-03-12 22:41:14 -04:00
taoneill
101bff45c5 Merge pull request #586 from cmastudios/patch-1
Fixed inability to download spout from maven. Thanks @cmastudios.
2013-03-12 19:32:11 -07:00
cmastudios
8dac3f4ea9 Fixes gh-608 - loadout "first" will be given on join and each battle after
When a player joins a warzone for the first time, they will be given a
loadout called "first" instead of the default loadout. After they have died
once, they will receive the default loadout. Players will also be assigned
the "first" loadout every battle if they are on the default loadout when
the battle ends.

I do not know how servers will deal with players who might constantly leave
and rejoin the zone in order to get the loadout back. This could be fixed
with a war change if it becomes necessary (maybe remember the player until
the battle ends). But, as always, if a server does not want to have a
"first" loadout in a warzone, they do not have to create one.
2013-03-07 18:13:39 -06:00
cmastudios
6b35645150 Prevent players from smuggling items into warzones with ender chests.
This is mainly for servers such as the Warhub, where most players can make
their own warzones. Inexperienced zone makers may place ender chests in
zones which makes their zone susceptible to smuggling items.

This may also apply for zones which would like to use ender chests for
aesthetics.

Hopefully this change shouldn't be a problem. I cannot think of any way
that an ender chest would be used inside of a warzone.
2013-03-07 17:17:06 -06:00
cmastudios
0fbf381748 gh-604 Add TagAPI support to War.
Used for changing color of player names while playing a match of War.
http://dev.bukkit.org/server-mods/tag/
2013-03-06 16:50:11 -06:00
cmastudios
a3f73b5fe7 Fixes gh-594 - blockheads:off now results in a colored helmet 2013-02-09 12:47:11 -06:00
cmastudios
9ca2ed1f46 Fixed anvil names not being saved to loadout.
I also fixed "lore" too, but I do not know what it is.
2013-01-29 22:21:41 -06:00
cmastudios
c3d7b74109 Fixed colored armor not working at all in loadouts 2013-01-25 19:17:20 -06:00
cmastudios
c87799c03d Fixed inability to download spout from maven
Spout changed the format of their repository again. @tommytony probably didn't notice because it was cached in his local maven repositoy.
2013-01-25 17:29:29 -06:00
taoneill
bff034a299 Fixed rotating warhub at restart after /warcfg.
Stops the warhub from rotating upon restart after a call to /warcfg -
sorry for the mess.  Still have to convert config files and fix
commands.
2013-01-10 22:29:26 -05:00
taoneill
0245476130 Basic support for RB 1.4.5-R1.0.
Backward compatible with 1.4.5-R0.2 and previous. Switched version to
War v1.7.4-PREVIEW. Lobbies and warhubs should line up properly now, at
least. Commands such as '/setzonelobby east' still use the wrong
directions.
2012-12-20 00:10:40 -05:00
taoneill
381047f915 Finally releasing v1.7.3.
No real improvement. Just targeting 1.4.5-R0.2 now instead of
1.2.5-R4.0. BlockFace compatibility with 1.4.5-R0.3 will come later.
2012-12-08 15:07:24 -05:00
taoneill
666f604133 Removed console warning. 2012-09-04 23:20:50 -04:00
taoneill
d71adaa8ab Stopgag patch: support block IDs from 128 to 255
Got my head out of my butt and figured how I was casting bytes to ints
all wrong. War map format can support block ids up to 255 now with this
ugly patch. This is just to tide people over until a format switch to
something that will supports custom blocks and items.
2012-09-04 23:16:47 -04:00