Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ### Eclipse Workspace Patch 1.0
- #P L2jFrozen_GameServer
- Index: head-src/com/l2jfrozen/gameserver/model/entity/event/CTF.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/model/entity/event/CTF.java (revision 1118)
- +++ head-src/com/l2jfrozen/gameserver/model/entity/event/CTF.java (working copy)
- @@ -127,6 +127,14 @@
- /** The _flags taken. */
- public static Vector<Boolean> _flagsTaken = new Vector<>();
- + // Reward custom for VIP user by João Vitor Barbosa
- + public static int vipRewardAmountItem(L2PcInstance player) {
- + if (player.isVIP) {
- + return Config.TVT_VIP_REWARD_ITEM_AMOUNT;
- + }
- + return 0;
- + }
- +
- /**
- * Instantiates a new cTF.
- */
- @@ -2382,7 +2390,7 @@
- if (teamName != null && (player._teamNameCTF.equals(teamName)))
- {
- - player.addItem(_eventName + " Event: " + _eventName, _rewardId, _rewardAmount, player, true);
- + player.addItem(_eventName + " Event: " + _eventName, _rewardId, (_rewardAmount + vipRewardAmountItem(player)), player, true);
- final NpcHtmlMessage nhm = new NpcHtmlMessage(5);
- final TextBuilder replyMSG = new TextBuilder("");
- @@ -2403,10 +2411,10 @@
- int minus_reward = 0;
- if (_topScore != 0)
- - minus_reward = _rewardAmount / 2;
- + minus_reward = (_rewardAmount + vipRewardAmountItem(player)) / 2;
- else
- // nobody took flags
- - minus_reward = _rewardAmount / 4;
- + minus_reward = (_rewardAmount + vipRewardAmountItem(player)) / 4;
- player.addItem(_eventName + " Event: " + _eventName, _rewardId, minus_reward, player, true);
- Index: config/frozen/dm.properties
- ===================================================================
- --- config/frozen/dm.properties (revision 1118)
- +++ config/frozen/dm.properties (working copy)
- @@ -52,4 +52,7 @@
- DMAllowedHealerClasses = True
- # Remove Buffs on player die
- -DMRemoveBuffsOnPlayerDie = False
- \ No newline at end of file
- +DMRemoveBuffsOnPlayerDie = False
- +
- +# Reward amount VIP - By João Vitor Barbosa
- +# disabled = 0
- +DMRewardItemAmount = 20
- \ No newline at end of file
- Index: head-src/com/l2jfrozen/Config.java
- ===================================================================
- --- head-src/com/l2jfrozen/Config.java (revision 1118)
- +++ head-src/com/l2jfrozen/Config.java (working copy)
- @@ -1657,6 +1657,7 @@
- public static boolean TVT_AURA;
- public static boolean TVT_STATS_LOGGER;
- public static boolean TVT_REMOVE_BUFFS_ON_DIE;
- + public static int TVT_VIP_REWARD_ITEM_AMOUNT;
- // ============================================================
- public static void loadTVTConfig()
- @@ -1696,6 +1697,8 @@
- TVT_REMOVE_BUFFS_ON_DIE = Boolean.parseBoolean(TVTSettings.getProperty("TvTRemoveBuffsOnPlayerDie", "false"));
- + TVT_VIP_REWARD_ITEM_AMOUNT = Integer.parseInt(TVTSettings.getProperty("TvTRewardItemAmount", "35"));
- +
- }
- catch (final Exception e)
- {
- @@ -2217,6 +2220,7 @@
- public static boolean DM_STATS_LOGGER;
- public static boolean DM_ALLOW_HEALER_CLASSES;
- public static boolean DM_REMOVE_BUFFS_ON_DIE;
- + public static int DM_VIP_REWARD_ITEM_AMOUNT;
- // ============================================================
- public static void loadDMConfig()
- @@ -2258,6 +2262,8 @@
- DM_REMOVE_BUFFS_ON_DIE = Boolean.parseBoolean(DMSettings.getProperty("DMRemoveBuffsOnPlayerDie", "false"));
- + DM_VIP_REWARD_ITEM_AMOUNT = Integer.parseInt(DMSettings.getProperty("DMRewardItemAmount", "35"));
- +
- }
- catch (final Exception e)
- {
- @@ -2282,6 +2288,7 @@
- public static boolean CTF_STATS_LOGGER;
- public static int CTF_SPAWN_OFFSET;
- public static boolean CTF_REMOVE_BUFFS_ON_DIE;
- + public static int CTF_VIP_REWARD_ITEM_AMOUNT;
- // ============================================================
- public static void loadCTFConfig()
- @@ -2314,6 +2321,8 @@
- CTF_REMOVE_BUFFS_ON_DIE = Boolean.parseBoolean(CTFSettings.getProperty("CTFRemoveBuffsOnPlayerDie", "false"));
- + CTF_VIP_REWARD_ITEM_AMOUNT = Integer.parseInt(CTFSettings.getProperty("CTFRewardItemAmount", "35"));
- +
- }
- catch (final Exception e)
- {
- Index: head-src/com/l2jfrozen/gameserver/model/entity/event/TvT.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/model/entity/event/TvT.java (revision 1118)
- +++ head-src/com/l2jfrozen/gameserver/model/entity/event/TvT.java (working copy)
- @@ -106,6 +106,14 @@
- /** The _top kills. */
- public static int _topKills = 0;
- + // Reward custom for VIP user by João Vitor Barbosa
- + public static int vipRewardAmountItem(L2PcInstance player) {
- + if (player._isVIP) {
- + return Config.TVT_VIP_REWARD_ITEM_AMOUNT;
- + }
- + return 0;
- + }
- +
- /**
- * Instantiates a new tv t.
- */
- @@ -2266,14 +2274,13 @@
- {
- if ((bestKiller != null) && (bestKiller.equals(player)))
- {
- - player.addItem(_eventName + " Event: " + _eventName, _rewardId, _rewardAmount, player, true);
- + player.addItem(_eventName + " Event: " + _eventName, _rewardId, (_rewardAmount + vipRewardAmountItem(player)), player, true);
- player.addItem(_eventName + " Event: " + _eventName, Config.TVT_TOP_KILLER_REWARD, Config.TVT_TOP_KILLER_QTY, player, true);
- -
- }
- else if (teamName != null && (player._teamNameTvT.equals(teamName)))
- {
- - player.addItem(_eventName + " Event: " + _eventName, _rewardId, _rewardAmount, player, true);
- + player.addItem(_eventName + " Event: " + _eventName, _rewardId, (_rewardAmount + vipRewardAmountItem(player)), player, true);
- final NpcHtmlMessage nhm = new NpcHtmlMessage(5);
- final TextBuilder replyMSG = new TextBuilder("");
- @@ -2294,10 +2301,10 @@
- int minus_reward = 0;
- if (_topKills != 0)
- - minus_reward = _rewardAmount / 2;
- + minus_reward = (_rewardAmount + vipRewardAmountItem(player)) / 2;
- else
- // nobody killed
- - minus_reward = _rewardAmount / 4;
- + minus_reward = (_rewardAmount + vipRewardAmountItem(player)) / 4;
- player.addItem(_eventName + " Event: " + _eventName, _rewardId, minus_reward, player, true);
- Index: config/frozen/ctf.properties
- ===================================================================
- --- config/frozen/ctf.properties (revision 1118)
- +++ config/frozen/ctf.properties (working copy)
- @@ -51,4 +51,7 @@
- CTFSpawnOffset = 300
- # Remove Buffs on player die
- -CTFRemoveBuffsOnPlayerDie = False
- \ No newline at end of file
- +CTFRemoveBuffsOnPlayerDie = False
- +
- +# Reward amount VIP - By João Vitor Barbosa
- +# disabled = 0
- +CTFRewardItemAmount = 10
- \ No newline at end of file
- Index: config/frozen/tvt.properties
- ===================================================================
- --- config/frozen/tvt.properties (revision 1118)
- +++ config/frozen/tvt.properties (working copy)
- @@ -71,4 +71,7 @@
- TvTStatsLogger = True
- # Remove Buffs on player die
- -TvTRemoveBuffsOnPlayerDie = False
- \ No newline at end of file
- +TvTRemoveBuffsOnPlayerDie = False
- +
- +# Reward amount VIP- By João Vitor Barbosa
- +# disabled = 0
- +TvTRewardItemAmount = 10
- \ No newline at end of file
- Index: head-src/com/l2jfrozen/gameserver/model/entity/event/DM.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/model/entity/event/DM.java (revision 1118)
- +++ head-src/com/l2jfrozen/gameserver/model/entity/event/DM.java (working copy)
- @@ -95,6 +95,14 @@
- /** The _save players. */
- public static Vector<String> _savePlayers = new Vector<>();
- + // Reward custom for VIP user by João Vitor Barbosa
- + public static int vipRewardAmountItem(L2PcInstance player) {
- + if (player._isVIP) {
- + return Config.DM_VIP_REWARD_ITEM_AMOUNT;
- + }
- + return 0;
- + }
- +
- /**
- * Instantiates a new dM.
- */
- @@ -2061,7 +2069,7 @@
- for (final L2PcInstance _topPlayer : _topPlayers)
- {
- - _topPlayer.addItem("DM Event: " + _eventName, _rewardId, _rewardAmount, _topPlayer, true);
- + _topPlayer.addItem("DM Event: " + _eventName, _rewardId, (_rewardAmount + vipRewardAmountItem(_topPlayer)), _topPlayer, true);
- final StatusUpdate su = new StatusUpdate(_topPlayer.getObjectId());
- su.addAttribute(StatusUpdate.CUR_LOAD, _topPlayer.getCurrentLoad());
Advertisement
Add Comment
Please, Sign In to add comment