Commit Graph

617 Commits

Author SHA1 Message Date
cmastudios
f00ed85c4b Add economy reward for winning team 2014-02-26 18:51:39 -06:00
cmastudios
43bbb24dd5 Initial Vault support for economy
I personally dislike forcing our users to use a separate plugin
just to abstract different economy plugins, but sadly we live in a
hell world where there are 20 competing economy plugins and
counting so I don't want to deal with that.
2014-02-26 17:07:44 -06:00
cmastudios
64ae4c617f Teleport 'warmup' time - delay before teleport
Closes #507.

War now includes a configuration option "TPWARMUP" to add delays
before teleporting players to a war. This can be used on full-world
PvP servers to prevent players from running away from a fight.

The configuration option is specified in ticks - 20/sec.

The delay is activated for /zone and /warhub.

@taoneill @cmastudios documentate for 1.9 release.
2014-02-22 19:46:53 -06:00
cmastudios
72a2f08d70 Config to apply potions on spawn.
Closes #615.

The new APPLYPOTION configuration option allows warzone makers to
give potion effects ot players every time they spawn.

Use case: Resistance 5 for a few seconds on player spawn to prevent
them from being "spawn camped" - killed when they step out by other
players waiting nearby.

Format of APPLYPOTION: effect_type:duration:amplification

 effect_type:
  For a valid list of values that can be used for this type param,
  please see http://jd.bukkit.org/rb/apidocs/org/bukkit/potion/PotionEffectType.html

 duration:
  Time in ticks (1/20 sec) that the potion will apply for.

 amplification:
  Amplifier to the potion's power.

@taoneill @cmastudios documentate how to tune this option before
 1.9 release on the wiki. Also please test use of this option in
 game (pulling a @grinning here).
2014-02-22 18:12:11 -06:00
cmastudios
4106dd887f Autojoin zone on connect
Closes #698. #733.

@taoneill please test.
2014-02-22 01:17:20 -06:00
cmastudios
1d6ffcea7e Bump version to 1.9-SNAPSHOT for development
@taoneill @grinning we need a new name for War 1.9. Maybe Bob can have his
chance again after all?

@taoneill also please update main war branch to 'develop'.
2014-02-22 01:15:42 -06:00
taoneill
6294922225 Bumped up version to 1.8. Congrats! 2014-02-01 22:21:20 -05:00
taoneill
bed0385476 Instead of small redstone torch to highlight active zones, now we have two big redstone blocks and two torches.
- Less subtle, but really gets the point accross (and doesn't have the won't-work-on-glass problem). :)
2014-02-01 21:31:19 -05:00
taoneill
0e481bb5d5 Changed all gate signs to be wall signs instead of sign posts.
- Also, now highlighting active warzones with a redstone torch on its warhub gate
2014-02-01 17:08:46 -05:00
taoneill
b17e38cfd2 Closes #746. OnEntityCombust event handler was firing for non-fire events and cancelling regular damage events for players within spawn.
- This fixes players being able to profit from spawn damage protection even if they already left the spawn once
2014-01-26 17:20:56 -05:00
cmastudios
5146a7c9c8 Send "English" instead of an empty string 2014-01-19 15:09:41 -06:00
cmastudios
20223d1c12 Fix lobby width issue with auto assign
Fixed by moving calculateLobbyWidth logic into constructors.

@taoneill this is to fix the issue zac encountered on war hub.
2014-01-19 14:38:25 -06:00
taoneill
4fde95ee7b Merge branch 'master' of https://github.com/taoneill/war 2014-01-12 22:16:50 -05:00
taoneill
7ee243e20d Prevent players from leaving spawn while zone is resetting.
- Closes #738
2014-01-12 22:16:36 -05:00
Connor Monahan
82267764e1 OMG I COMMITTED SPACES 2014-01-12 18:31:31 -06:00
taoneill
0c9ed4b238 Merge branch 'master' of https://github.com/taoneill/war 2014-01-12 18:32:34 -05:00
taoneill
95ee0c1972 Closes #739. Respawning doesn't wipe your chat anymore.
- We just take care of wiping top inventory slots in CRAFTING-type inventory views (container inventories weren't causing the same issue)
- End-of-game teleport and state restoration shouldn't wipe your chat anymore either
2014-01-12 18:32:19 -05:00
Connor Monahan
95cc2c7a34 Update team spawns for TXT files. Closes #717 2014-01-11 22:13:11 -06:00
Connor Monahan
2ef0f3e324 Remove java 1.7 locale methods 2014-01-11 21:09:17 -06:00
Connor Monahan
076e8ce9bd Update locales KO PL
PL has been completed, KO corrections.
There needed to be a trailing newline on the warhub sign localization or the plugin crashed when loading a lobby.
2014-01-07 20:57:14 -06:00
Connor Monahan
ce1b60b85f Make country-specific localizations work properly
Language tags such as pt_BR and ko_KR now work correctly
2014-01-07 20:51:52 -06:00
Connor Monahan
a92b2ea4ae Magic wool block appears when hat clicked 2014-01-07 20:18:32 -06:00
Connor Monahan
c6c93ba44f Set helmets on players instead of blocks 2014-01-07 19:49:22 -06:00
Connor Monahan
20068cbb15 Fix player list spacing issue 2014-01-07 18:37:33 -06:00
Connor Monahan
b011d3a46f New active sign, gets random warzone with players 2014-01-07 17:59:08 -06:00
Connor Monahan
bc07a60b51 Only randomly teleport to zones that are enabled 2014-01-07 17:51:49 -06:00
Connor Monahan
dc764de258 Restore maven2 compatibility
Adding metrics support via shading caused a unexpected break due to versions of shade being incompatible with older versions of maven. In theory, everyone should update to maven3 if possible. However, I would like to retain compatiblity for our older CI servers.
2014-01-04 17:40:49 -06:00
Connor Monahan
a45a833e68 Merge branch 'metrics' 2014-01-04 17:08:41 -06:00
Connor Monahan
fdc4e90635 [Lang] Add FR HU KO NO PL PT localizations
This commit adds localizations for the languages French, Korean, and Norwegian. Portuguese, Hungarian, and Polish are still a work-in-progress but they have been added. The languages German, Spanish, and Russian have been updated also.
2014-01-03 20:16:28 -06:00
Connor Monahan
0805a04cad Collect metrics statistics from servers
War now collects statistics from servers running the plugin. The statistics are minimal. The goal is so the developers of the plugin can tell what areas they need to do more work in.
In addition to the default statistics collected by PluginMetrics, War sends the number of warzones and if certain plugins that War interfaces with are enabled.
To prevent your server from sending statistical data, set "opt-out" to "true" in plugins/PluginMetrics/config.yml.
Closes #716.
2013-12-27 18:13:30 -06:00
Connor Monahan
ca03c96173 [Behavior] Blockheads:true now gives leather hat
Warzones that previously used blockheads:false during the preview to get a properly colored hat now need to switch to blockheads:true for a hat. Old warzones that have blockheads:true will now have colored helmets instead of block heads.
Closes #528.
2013-12-27 15:31:11 -06:00
Connor
59779eb0e5 Merge pull request #718 from taoneill/nimitz-v2
Optimize nimitz file store

Tested on bukkit server 1.7.2 with a warzone originally created with war 1.7.4, therefore upgrade works properly.
2013-12-26 17:11:11 -08:00
cmastudios
0af348f2cb Merge branch 'master' into nimitz-v2
Conflicts:
	war/src/main/java/com/tommytony/war/Warzone.java
2013-12-24 20:40:35 -06:00
grinning
c16bc6ca5f Maybe closes gh-517
returns the code after the leaving of the zone. Not sure if it works.
Don't think it returns under all cases

Conflicts:
	war/src/main/java/com/tommytony/war/Warzone.java
2013-12-24 20:31:40 -06:00
cmastudios
228ec2299b Prevent block duplication
Closes #722, closes #723. War prevents thieves from messing with their inventory and anyone from messing with their block head.
2013-12-24 17:11:29 -06:00
cmastudios
a120393060 Fix unbreakable regression
Closes #721. Zonemakers can modify blocks in an unbreakable zone when outside of it again.
2013-12-24 16:31:51 -06:00
cmastudios
84a5750063 Store warzone structures in main zone database
Instead of storing strutures in /dat/warzone-x/volume-y.sl3 anymore, they are stored in the main database file created for the warzone in /dat/warzone-x/volume-x.sl3. Tables is created for each structure, with the prefix being structure_HASH_. The HASH is a string hashCode run through a bitwise AND with Integer.MAX_VALUE, to prevent negative values from showing.

This is a step on the road to storing everything in a single database for the warzone. My plan is to eventually store warzone configuration in the database as well. In the ideal setup, there would be a table for teams, structure definitions, loadouts, and materials. Sadly, for configuration, we would most likely have to store teamcfg & zonecfg rules in a key-value table, unless @taoneill or @grinning has another idea.

I still need to do testing to make sure everything is backward-compatible. This conversion happens properly for nimitz-format zones and zones in the process of converting from degaulle format. When messing around earlier, I found that .txt configurations were broken due to numbered teams. I need to take a look at that. Most likely it is due to WarzoneTxtMapper not being maintained. The loader will probably have to be modified to load the new volumes and teams properly.
2013-12-08 01:46:26 -06:00
cmastudios
034b51ae03 Prevent using chests while capturing flag
Stops duplication of wool.
2013-12-07 20:49:25 -06:00
cmastudios
300f2e383b Don't reopen the file during a batch reset
Connections to the SQLite warzones are now kept open when iterating a batch reset.
2013-12-07 20:34:59 -06:00
cmastudios
346fd25955 Prevent joining zone during reset 2013-12-07 19:23:12 -06:00
cmastudios
df871c1c5b Allow disabling of automatic warzone block reset
Configuration key: RESETBLOCKS
2013-12-07 16:38:48 -06:00
cmastudios
67bb509735 Stop saving Air blocks to the database
War now skips over saving Air blocks. Instead, the plugin loads all solid blocks back into the world and then sets each block to air that was not changed.

Benchmarks:
Warzone molecule
Block count 2,487,555
Speed 50,000 blocks per tick
Intel Core i7 @ 3.6 GHz * 8

Before:
File size 70 MB
Reset 23 seconds
Save 16 seconds

After:
File size 54 MB
Save 5 seconds
(no changes)
Reset 4.9 seconds
(set to air)
Reset 31.17 seconds
(set to stone)
Reset 18.23 seconds
2013-12-07 16:22:50 -06:00
cmastudios
7ef61af277 Fix logger format arguments not being applied 2013-12-07 16:15:41 -06:00
cmastudios
78ef1dd4fc Merge branch 'no-save-air' into nimitz-v2
Conflicts:
	war/src/main/java/com/tommytony/war/mapper/ZoneVolumeMapper.java
2013-12-07 03:19:36 -06:00
cmastudios
60b62c8b71 Merge branch 'master' into nimitz-v2 2013-12-07 02:44:01 -06:00
cmastudios
d040edcc4e Attempt at some slight saver speed ups 2013-12-07 02:31:11 -06:00
cmastudios
21f91a00fc Configuration setting to allow ender chests 2013-12-07 00:48:03 -06:00
taoneill
6eed5bbe19 Coalesce many metadata columns in warzone blocks table into one.
- Container, sign, skulls, and more are not just a single column
- Compacting each warzone database after migration from schema v1 to v2 (to get disk space savings, but might take a while for large zones)
- Showing a few decimals on time value in zone reset messages instead of just showing "Reset in 0 seconds" all the time
2013-12-01 00:48:11 -05:00
cmastudios
5c2474cb70 Don't modify block type/data if it has not changed 2013-11-24 16:41:26 -06:00
cmastudios
cc2b13633c Only update twice if we are changing tile data
War originally modified each block twice when loading, even if there was no metadata. Now it will only update once if there is no metadata.
2013-11-24 16:35:56 -06:00