I have some time without trying to setup a server i will give a little description about what programs i m using for make more easy your help:
SO: Windows 7 64Bits
Navicat
eclipse-SDK-3.5.1-win32 ( i m thinking if the 64 will be better than this..?)
jdk-6u17-windows-i586 (thinking in get the 64 Bits to)
mysql-essential-5.4.3-beta-winx64 (i need use this yes or yes why Win dows 7 have 2 folder in C: C:\Program Files "for 64 bits programs i think" and C:\Program Files (x86). So when i was trying to install the Database instaler (with MySQL 32 bits) for create the l2jdb i have a problem don't recognize the Directory of MySQL 32 Bits).
Well after i install all this i can install the DB without any problem, i put up the server etc...
(Compile without any errors but nothing happend in game).
Ranks Titles Based on PVP Points:
Index: /home/sauron3256/eclipse/workspace/L2_GameServer/java/config/l2jmods.properties
===================================================================
--- /home/sauron3256/eclipse/workspace/L2_GameServer/java/config/l2jmods.properties (revision 3178)
+++ /home/sauron3256/eclipse/workspace/L2_GameServer/java/config/l2jmods.properties (working copy)
@@ -229,4 +229,63 @@
# This option will enable core support for:
# Mana Drug (item ID 726), using skill ID 9007.
# Mana Potion (item ID 728), using skill ID 9008.
-EnableManaPotionSupport = False
\ No newline at end of file
+EnableManaPotionSupport = False
+
+# ---------------------------------------
+# Section: PvP Title Color Change System by Level
+# ---------------------------------------
+# Each Amount will change the title content and color to the values defined here.
+# Example: PvpAmount1 = 20, when a character's PvP counter reaches 20
+# their title color and content will change according to the ColorForAmount value.
+# Note: Colors Must Be in RBG format.
+EnablePvPColorSystem = false
+
+# Pvp Amount, Title & color level 1.
+PvpAmount1 = 20
+ColorForAmount1 = 00FF00
+TitleForAmount1 = Warrior
+
+# Pvp Amount, Title & color level 2.
+PvpAmount2 = 80
+ColorForAmount2 = 00FF00
+TitleForAmount2 = Soldier
+
+# Pvp Amount, Title & color level 3.
+PvpAmount3 = 140
+ColorForAmount3 = 00FF00
+TitleForAmount3 = Elite Soldier
+
+# Pvp Amount, Title & color level 4.
+PvpAmount4 = 190
+ColorForAmount4 = 00FF00
+TitleForAmount4 = Gladiator
+
+# Pvp Amount, Title & color level 5.
+PvpAmount5 = 290
+ColorForAmount5 = 00FF00
+TitleForAmount1 = Veteran
+
+# Pvp Amount, Title & color level 6.
+PvpAmount6 = 390
+ColorForAmount6 = 00FF00
+TitleForAmount6 = Champion
+
+# Pvp Amount, Title & color level 7.
+PvpAmount7 = 500
+ColorForAmount7 = 00FF00
+TitleForAmount7 = Commander
+
+# Pvp Amount, Title & color level 8.
+PvpAmount8 = 650
+ColorForAmount8 = 00FF00
+TitleForAmount8 = Master
+
+# Pvp Amount, Title & color level 9.
+PvpAmount9 = 800
+ColorForAmount9 = 00FF00
+TitleForAmount9 = Assassin
+
+# Pvp Amount, Title & color level 10.
+PvpAmount10 = 1000
+ColorForAmount10 = 00FF00
+TitleForAmount10 = Hero
Index: /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/Config.java
===================================================================
--- /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/Config.java (revision 3178)
+++ /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/Config.java (working copy)
@@ -576,6 +576,39 @@
public static int OFFLINE_NAME_COLOR;
public static boolean L2JMOD_ENABLE_MANA_POTIONS_SUPPORT;
+ /** Config options allowing the PvP name color Engine. */
+ public static boolean PVP_TITLE_AND_COLOR_SYSTEM_ENABLED;
+ public static int PVP_AMOUNT1;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT1;
+ public static String PVP1_TITLE;
+ public static int PVP_AMOUNT2;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT2;
+ public static String PVP2_TITLE;
+ public static int PVP_AMOUNT3;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT3;
+ public static String PVP3_TITLE;
+ public static int PVP_AMOUNT4;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT4;
+ public static String PVP4_TITLE;
+ public static int PVP_AMOUNT5;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT5;
+ public static String PVP5_TITLE;
+ public static int PVP_AMOUNT6;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT6;
+ public static String PVP6_TITLE;
+ public static int PVP_AMOUNT7;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT7;
+ public static String PVP7_TITLE;
+ public static int PVP_AMOUNT8;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT8;
+ public static String PVP8_TITLE;
+ public static int PVP_AMOUNT9;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT9;
+ public static String PVP9_TITLE;
+ public static int PVP_AMOUNT10;
+ public static int TITLE_COLOR_FOR_PVP_AMOUNT10;
+ public static String PVP10_TITLE;
+ public static int PVP_AMOUNT11;
//--------------------------------------------------
// NPC Settings
@@ -1701,6 +1734,40 @@
L2JMOD_ENABLE_WAREHOUSESORTING_PRIVATE = Boolean.valueOf(L2JModSettings.getProperty("EnableWarehouseSortingPrivate", "False"));
L2JMOD_ENABLE_WAREHOUSESORTING_FREIGHT = Boolean.valueOf(L2JModSettings.getProperty("EnableWarehouseSortingFreight", "False"));
+ // PVP Title & Color System configs - Start
+ PVP_TITLE_AND_COLOR_SYSTEM_ENABLED = Boolean.parseBoolean(L2JModSettings.getProperty("EnablePvPColorSystem", "false"));
+ PVP_AMOUNT1 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount1", "20"));
+ TITLE_COLOR_FOR_PVP_AMOUNT1 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount1", "00FF00"));
+ PVP1_TITLE = L2JModSettings.getProperty("TitleForAmount1", "Warrior");
+ PVP_AMOUNT2 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount2", "80"));
+ TITLE_COLOR_FOR_PVP_AMOUNT2 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount2", "00FF00"));
+ PVP2_TITLE = L2JModSettings.getProperty("TitleForAmount2", "Soldier");
+ PVP_AMOUNT3 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount3", "140"));
+ TITLE_COLOR_FOR_PVP_AMOUNT3 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount3", "00FF00"));
+ PVP3_TITLE = L2JModSettings.getProperty("TitleForAmount3", "Elite Soldier");
+ PVP_AMOUNT4 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount4", "190"));
+ TITLE_COLOR_FOR_PVP_AMOUNT4 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount4", "00FF00"));
+ PVP4_TITLE = L2JModSettings.getProperty("TitleForAmount4", "Gladiator");
+ PVP_AMOUNT5 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount5", "290"));
+ TITLE_COLOR_FOR_PVP_AMOUNT5 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount5", "00FF00"));
+ PVP5_TITLE = L2JModSettings.getProperty("TitleForAmount5", "Veteran");
+ PVP_AMOUNT6 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount6", "390"));
+ TITLE_COLOR_FOR_PVP_AMOUNT6 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount6", "00FF00"));
+ PVP6_TITLE = L2JModSettings.getProperty("TitleForAmount6", "Champion");
+ PVP_AMOUNT7 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount7", "500"));
+ TITLE_COLOR_FOR_PVP_AMOUNT7 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount7", "00FF00"));
+ PVP7_TITLE = L2JModSettings.getProperty("TitleForAmount7", "Commander");
+ PVP_AMOUNT8 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount8", "650"));
+ TITLE_COLOR_FOR_PVP_AMOUNT8 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount8", "00FF00"));
+ PVP8_TITLE = L2JModSettings.getProperty("TitleForAmount8", "Master");
+ PVP_AMOUNT9 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount9", "800"));
+ TITLE_COLOR_FOR_PVP_AMOUNT9 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount9", "00FF00"));
+ PVP9_TITLE = L2JModSettings.getProperty("TitleForAmount9", "Assassin");
+ PVP_AMOUNT10 = Integer.parseInt(L2JModSettings.getProperty("PvpAmount10", "1000"));
+ TITLE_COLOR_FOR_PVP_AMOUNT10 = Integer.decode("0x" + L2JModSettings.getProperty("ColorForAmount10", "00FF00"));
+ PVP10_TITLE = L2JModSettings.getProperty("TitleForAmount10", "Hero");
+ // PvP Title & Color System configs - End
+
if (TVT_EVENT_PARTICIPATION_NPC_ID == 0)
{
TVT_EVENT_ENABLED = false;
Index: /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (revision 3178)
+++ /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (working copy)
@@ -4119,7 +4119,70 @@
DuelManager.getInstance().broadcastToOppositTeam(this, update);
}
}
-
+
+ // Custom PVP Color System - Start
+ public void updatePvPTitleColor(int pvpKillAmount)
+ {
+ if (Config.PVP_TITLE_AND_COLOR_SYSTEM_ENABLED)
+ {
+ //Check if the character has GM access and if so, let them be.
+ if (isGM())
+ return;
+ {
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT1)) && (pvpKillAmount < (Config.PVP_AMOUNT2)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT1);
+ setTitle(Config.PVP1_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT2)) && (pvpKillAmount < (Config.PVP_AMOUNT3)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT2);
+ setTitle(Config.PVP2_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT3)) && (pvpKillAmount < (Config.PVP_AMOUNT4)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT3);
+ setTitle(Config.PVP3_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT4)) && (pvpKillAmount < (Config.PVP_AMOUNT5)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT4);
+ setTitle(Config.PVP4_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT5)) && (pvpKillAmount < (Config.PVP_AMOUNT6)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT5);
+ setTitle(Config.PVP5_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT6)) && (pvpKillAmount < (Config.PVP_AMOUNT7)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT6);
+ setTitle(Config.PVP6_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT7)) && (pvpKillAmount < (Config.PVP_AMOUNT8)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT7);
+ setTitle(Config.PVP7_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT8)) && (pvpKillAmount < (Config.PVP_AMOUNT9)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT8);
+ setTitle(Config.PVP8_TITLE);
+ }
+ if ((pvpKillAmount >= (Config.PVP_AMOUNT9)) && (pvpKillAmount < (Config.PVP_AMOUNT10)))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT9);
+ setTitle(Config.PVP9_TITLE);
+ }
+ else if (pvpKillAmount >= (Config.PVP_AMOUNT10))
+ {
+ getAppearance().setTitleColor(Config.TITLE_COLOR_FOR_PVP_AMOUNT10);
+ }
+ }
+ }
+ }
+ //Custom PVP Color System - End
+
/**
* Send a Server->Client packet UserInfo to this L2PcInstance and CharInfo to all L2PcInstance in its _KnownPlayers.<BR><BR>
*
@@ -5399,7 +5462,11 @@
{
// Add karma to attacker and increase its PK counter
setPvpKills(getPvpKills() + 1);
-
+
+ //Update the character's title content and color if they reached any of the 10 PvP levels.
+ updatePvPTitleColor(getPvpKills());
+ broadcastUserInfo();
+
// Send a Server->Client UserInfo packet to attacker with its Karma and PK Counter
sendPacket(new UserInfo(this));
sendPacket(new ExBrExtraUserInfo(this));
Index: /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java
===================================================================
--- /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java (revision 3178)
+++ /home/sauron3256/eclipse/workspace/L2_GameServer/java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java (working copy)
@@ -300,7 +300,13 @@
Quest.playerEnter(activeChar);
activeChar.sendPacket(new QuestList());
loadTutorial(activeChar);
-
+
+ /* PvP color & title System checks - Start
+ Check if the PvP color & title system is enabled and if so
+ check the character's counters and apply any changes that must be done. =*/
+ if (activeChar.getPvpKills()>=(Config.PVP_AMOUNT1) && (Config.PVP_TITLE_AND_COLOR_SYSTEM_ENABLED)) activeChar.updatePvPTitleColor(activeChar.getPvpKills());
+ /* PvP color & title System checks - End */
+
if (Config.PLAYER_SPAWN_PROTECTION > 0)
activeChar.setProtection(true);
(Compile without errors but nothing happend in game).
I m wroking with Last Rev getting from SVN with Eclipse, i m really interesting in this 3 things if somebody can help will great... thx for read.
PD: I make the usual compile take the Java.jar from the wrkspace Build directory and paste it in C:/server/gamserver later i put up the server but nothing happend any of this things work, i m thinking maybe can be why need use Java JDK and Eclipse 64 Bits i don't know i m really fucked with this.
Hello.
This code works well. It removes buff with double click, but If you preffer remove buff with ALT + mouse click, place this code in AbnormalStatusWnd.uc
function OnLButtonDown(WindowHandle a_WindowHandle, int X, int Y)
{
local Rect windowBounds;
local int targetRow;
local int targetCol;
local StatusIconInfo info;
local SkillInfo skillInfo;
if (IsKeyDown(IK_alt) == false)
return;
// Find window position
windowBounds = Me.GetRect();
// Process clicks outside of window frame only
if (X > (windowBounds.nX + NSTATUSICON_FRAMESIZE))
{
// Calc row and col of targeted icon
targetRow = (Y - windowBounds.nY) / NSTATUSICON_SIZE;
targetCol = (X - windowBounds.nX - NSTATUSICON_FRAMESIZE) / NSTATUSICON_SIZE;
// Store status info of targeted icon
StatusIcon.GetItem(targetRow, targetCol, info);
// Store actual skill info and make sure it is exists
if (GetSkillInfo(info.ClassID, info.Level, skillInfo))
{
// Request server to stop skill effect
// Usage: _dispel:<int:skill_id>,<int :skill_level>
// Example: _dispel:313,8
RequestBypassToServer ( "_dispel:" $ string ( skillInfo. SkillID ) $ "," $ string ( skillInfo. SkillLevel ) ) ) ;
}
}
}
Question
ZeroCool22
Hi to all good ppl.
I have some time without trying to setup a server i will give a little description about what programs i m using for make more easy your help:
SO: Windows 7 64Bits
Navicat
eclipse-SDK-3.5.1-win32 ( i m thinking if the 64 will be better than this..?)
jdk-6u17-windows-i586 (thinking in get the 64 Bits to)
mysql-essential-5.4.3-beta-winx64 (i need use this yes or yes why Win dows 7 have 2 folder in C: C:\Program Files "for 64 bits programs i think" and C:\Program Files (x86). So when i was trying to install the Database instaler (with MySQL 32 bits) for create the l2jdb i have a problem don't recognize the Directory of MySQL 32 Bits).
Well after i install all this i can install the DB without any problem, i put up the server etc...
Now i m interesting in this things for my server:
PVP Rewards:
http://www.maxcheaters.com/forum/index.php?topic=28058.0 (Compiled without any error but nothing happend in game)
Disallowed GK for players in combat state (Purple instance):
(Compile without any errors but nothing happend in game).
Ranks Titles Based on PVP Points:
(Compile without errors but nothing happend in game).
I m wroking with Last Rev getting from SVN with Eclipse, i m really interesting in this 3 things if somebody can help will great... thx for read.
PD: I make the usual compile take the Java.jar from the wrkspace Build directory and paste it in C:/server/gamserver later i put up the server but nothing happend any of this things work, i m thinking maybe can be why need use Java JDK and Eclipse 64 Bits i don't know i m really fucked with this.
5 answers to this question
Recommended Posts