Jump to content

Recommended Posts

Posted

Helllllloooo members of maxcheaters.com!!!

 

This is my firts java code and i'm glad that will share this in forum

i hope to enjoy that!!!

 

Index: java/net/sf/l2j/gameserver/clientpackets/EnterWorld.java
===================================================================
--- java/net/sf/l2j/gameserver/clientpackets/EnterWorld.java	
+++ java/net/sf/l2j/gameserver/clientpackets/EnterWorld.java
@@ -249,9 +249,67 @@

   SevenSigns.getInstance().sendCurrentPeriodMsg(activeChar);
   Announcements.getInstance().showAnnouncements(activeChar);
+
       Quest.playerEnter(activeChar);
       activeChar.sendPacket(new QuestList());

@@ -286,6 +287,7 @@
                 Hero.getInstance().getHeroes().containsKey(activeChar.getObjectId()))
             activeChar.setHero(true);

+        activeChar.charAnnouncements();
         setPledgeClass(activeChar);

Index: java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
+++ java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
@@ -36,6 +36,7 @@

import net.sf.l2j.Config;
import net.sf.l2j.L2DatabaseFactory;
+import net.sf.l2j.gameserver.Announcements;
import net.sf.l2j.gameserver.GameTimeController;
import net.sf.l2j.gameserver.GeoData;
import net.sf.l2j.gameserver.GmListTable;
@@ -9985,6 +9986,35 @@
		return _duelState;
	}

+	
+	public void charAnnouncements()
+	{
+		
+		       if (Config.Announcements_Hero)
+		       {
+		       if (isHero())
+		        {                                                                     
+		       Announcements.getInstance().announceToAll("Server's Hero "+getName()+"is currently online");
+		       sendMessage("Welcome : "+getName()+ "Hero of our Server");  
+		       sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		        }
+		       }
+		       
+		       if (Config.Announcements_GODLIKE)
+		       {
+		       if (getPvpKills() > 150 & getPkKills() > 150 & isNoble())
+		        {                                                                    
+		       Announcements.getInstance().announceToAll("Server's GODLIKE "+getName()+" with 150 pvp & 150pk & noble is currently online");
+		       sendMessage("Welcome : "+getName()+ "GODLIKE of our Server");           
+		       sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		        }
+		       }
+
+
+		       if (Config.Announcements_Legendery)
+		       {
+		       if (getPvpKills() > 100 & getPkKills() > 100 & isNoble())     
+		       {                                                                     
+		      Announcements.getInstance().announceToAll("Server's legendary "+getName()+" with 100 pvp & 100pk & noble is currently online");
+		      sendMessage("Welcome : "+getName()+ "Legendary of our Server");           
+		      sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		       }
+		       }
+		       
+		       if (Config.Announcements_Incredible)
+		       {
+		       if (getPvpKills() > 50 & getPkKills() > 50 & isNoble())
+		       {                                                                     
+		      Announcements.getInstance().announceToAll("Server's Incredible "+getName()+" with 50 pvp & 50pk & noble is currently online");
+		      sendMessage("Welcome : "+getName()+ "Incredible of our Server");           
+		      sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		       }
+		       } 			       
+	}
Index: java/net/sf/l2j/Config.java
===================================================================
--- java/net/sf/l2j/Config.java
+++ java/net/sf/l2j/Config.java
@@ -1185,5 +1185,46 @@

/** Alt Settings for devs */
    public static boolean ALT_DEV_NO_QUESTS;
    public static boolean ALT_DEV_NO_SPAWNS;

+
+   public static boolean Announcements_Hero;
+   public static boolean Announcements_GODLIKE;
+   public static boolean Announcements_Legendery;
+   public static boolean Announcements_Incredible;
+
+
/**
     * This class initializes all global variables for configuration.<br>
     * If key doesn't appear in properties file, a default value is setting on by this class.
     * @see #CONFIGURATION_FILE for configuring your server.
     */
    public static void load()

@@ 1904,17 1904,138 @@

                L2JMOD_WEDDING_SAMESEX                  = Boolean.parseBoolean(L2JModSettings.getProperty("WeddingAllowSameSex", "False"));
                L2JMOD_WEDDING_FORMALWEAR               = Boolean.parseBoolean(L2JModSettings.getProperty("WeddingFormalWear", "True"));
                L2JMOD_WEDDING_DIVORCE_COSTS            = Integer.parseInt(L2JModSettings.getProperty("WeddingDivorceCosts", "20"));
+
+               Announcements_Hero                      = Boolean.parseBoolean(L2JModSettings.getProperty("AnnouncementsHero", "False"));
+               Announcements_GODLIKE                   = Boolean.parseBoolean(L2JModSettings.getProperty("AnnouncementsGODLIKE", "False"));         
+               Announcements_Legendery                 = Boolean.parseBoolean(L2JModSettings.getProperty("AnnouncementsLegendery", "False"));
+               Announcements_Incredible                = Boolean.parseBoolean(L2JModSettings.getProperty("AnnouncementsIncredible", "False"));
+
                    if (TVT_EVENT_PARTICIPATION_NPC_ID == 0)
                {
                    TVT_EVENT_ENABLED = false;
                    System.out.println("TvTEventEngine[Config.load()]: invalid config property -> TvTEventParticipationNpcId");
                }

Index: java/Config/L2jmods.Properties
===================================================================
--- java/Config/L2jmods.Properties	
+++ java/Config/L2jmods.Properties
@@ -140,1 +140,1 @@

+#==================================================
+#                Custom Announcements             =
+#==================================================
+#Set this options to true to enable Announcements.
+AnnouncementsHero = False
+AnnouncementsGODLIKE = False
+AnnouncementsLegendery = False
+AnnouncementsIncredible = False

 

If player is hero

he get a wellcome message every time login

when login can be seen all online players in this time

and he Announcements!!!

 

when one player done noblesse and has some pvp and pk BECOME a Incredible then Legendary and the final level is the GODLIKE he then gets a wellcome message every time login, when login can be seen all online players in this time AND Announcements ( as the hero :P )

 

You can edit the numbers of pvp,pk on 'getPvpKills() > 150' for pvp and 'activeChar.getPkKills() > 150' for pk AND don't forget to change the message!!!

 

Τhank Fanky who helped me in L2PcInstanse code :)

Posted

someone read my guide in gr section,I guess.

 

gud job.

 

but still way too simple,you could done it through pcinstance and then load the method in enterworld,in this way it's too crappy :P but since it is your first code..

Posted

someone read my guide in gr section,I guess.

 

gud job.

 

but still way too simple,you could done it through pcinstance and then load the method in enterworld,in this way it's too crappy :P but since it is your first code..

Yay, I have to agree. Anyway, it's your first time and it's very good.

 

Keep practicing.

Posted

Good luck man [Gr] Vlepw xwnese sta vathia  [GR]

He is doing well. He doesn't ask help every 1 minute and spam whole forum. He is learning alone and that's very good.
Posted

but still way too simple,you could done it through pcinstance and then load the method in enterworld,in this way it's too crappy :P but since it is your first code..

somethin' like that.

### Eclipse Workspace Patch 1.0
#P L2_GameServer_It
Index: java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java	(revision 5585)
+++ java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java	(working copy)
@@ -36,6 +36,7 @@

import net.sf.l2j.Config;
import net.sf.l2j.L2DatabaseFactory;
+import net.sf.l2j.gameserver.Announcements;
import net.sf.l2j.gameserver.GameTimeController;
import net.sf.l2j.gameserver.GeoData;
import net.sf.l2j.gameserver.GmListTable;
@@ -9985,6 +9986,35 @@
		return _duelState;
	}

+	
+	public void charAnnouncements()
+	{
+		
+		       if (isHero())
+		        {                                                                   
+		       Announcements.getInstance().announceToAll("Server's Hero "+getName()+"is currently online");
+		       sendMessage("Welcome : "+getName()+ "Hero of our Server");  
+		      sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		        }        
+		       if (getPvpKills() > 150 & getPkKills() > 150 & isNoble())
+		        {                                                                    
+		       Announcements.getInstance().announceToAll("Server's GODLIKE "+getName()+" with 150 pvp & 150pk & noble is currently online");
+		       sendMessage("Welcome : "+getName()+ "GODLIKE of our Server");           
+		       sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		       }      
+		       if (getPvpKills() > 100 & getPkKills() > 100 & isNoble())     
+		       {                                                                     
+		       Announcements.getInstance().announceToAll("Server's legendary "+getName()+" with 100 pvp & 100pk & noble is currently online");
+		       sendMessage("Welcome : "+getName()+ "Legendary of our Server");           
+		       sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		       }                 
+		       if (getPvpKills() > 50 & getPkKills() > 50 & isNoble())
+		       {                                             
+		      Announcements.getInstance().announceToAll("Server's Incredible "+getName()+" with 50 pvp & 50pk & noble is currently online");
+		      sendMessage("Welcome : "+getName()+ "Incredible of our Server");           
+		      sendMessage("There are: "+L2World.getInstance().getAllPlayers().size()+" players online");
+		       }
+	}
	/**
	 * Sets up the duel state using a non 0 duelId.
	 * @param duelId 0=not in a duel
Index: java/net/sf/l2j/gameserver/clientpackets/EnterWorld.java
===================================================================
--- java/net/sf/l2j/gameserver/clientpackets/EnterWorld.java	(revision 5585)
+++ java/net/sf/l2j/gameserver/clientpackets/EnterWorld.java	(working copy)
@@ -251,6 +251,7 @@

         SevenSigns.getInstance().sendCurrentPeriodMsg(activeChar);
         Announcements.getInstance().showAnnouncements(activeChar);
+        

		Quest.playerEnter(activeChar);
		activeChar.sendPacket(new QuestList());
@@ -286,6 +287,7 @@
                 Hero.getInstance().getHeroes().containsKey(activeChar.getObjectId()))
             activeChar.setHero(true);

+        activeChar.charAnnouncements();
         setPledgeClass(activeChar);

		//add char to online characters

 

for the record,because I'm kinda sure that you've no idea why we didnt used activeChar in l2pcinstance

the reason is simple,activeChar is l2pcinstance's object,that's why.

Posted

yes i spam in help section every one minute  :P  :-[ !!! Thank you all very much for your kind words!!! and fanky your guide is veryyyyy good helped me a lot!!! :D

Posted

yes i spam in help section every one minute  :P  :-[ !!! Thank you all very much for your kind words!!! and franky your guide is veryyyyy good helped me a lot!!!

fanky.

 

glad that I helped anyway.

Posted

AND thank you for the L2PcInstance code!!! realy!!! I understood my mistake ;D

your code doesnt got mistake.

 

just by l2pcinstance way,its a bit more advanced than yours crappy way :P

Posted

OK!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! :D thnxxxx!!!!

 

i think i do a config today the night!!! :P because with config would be more practical!!! :P

Posted

OK!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! :D thnxxxx!!!!

 

i think i do a config today the night!!! :P because with config would be more practical!!! :P

configs are useless unless you are newbie >.>
Posted

where's the config on your code;

lol.

 

you just add them in config.java/properties.

 

where's in your code?

 

btw,what's that?if you keep l2pcinstance code u should delete all the enterworld code,lol.

and just add one line in enterworld

activeChar.charAnnouncements();

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Posts

    • Bump still selling Discord: leilows
    • THE CAMERA DISTORTS – AND THAT CAN EXPOSE YOU ▪ You look at the photo: “looks fine.” But the sensor has already altered it – and without that, the shot doesn’t exist. ▪ Rolling shutter. The frame is read line by line objects slightly “drift”, geometry isn’t perfect that’s not a bug – that’s the baseline. ▪ Sensor noise. Even in good lighting there’s still grain every sensor has its own signature too clean = unnatural. ▪ Aberrations. Color shifts appear near the edges lenses aren’t perfect, and it shows perfect edges with no shift are rare. ▪ Reality ≠ what the camera records. It always adds distortion. ▪ Want to know where your file is “too perfect”? Send it over – we’ll break it down for you. › TG: @mustang_service ( https:// t.me/ mustang_service ) › Channel: Mustang Service ( https:// t.me/ +JPpJCETg-xM1NjNl ) #editing #photoshop #distortion #verification #camera
    • We’re not trying to be “Reborn” or anyone else and you have copy the server concept,the reborn website,the reborn logo,the reborn community board html,lol trash
    • SOCNET is a universal service that combines a digital goods store, an SMM panel, a Telegram bot for purchasing Telegram Stars and a Telegram bot for renting virtual numbers. Here you will find accounts for TikTok, Instagram, Reddit, Twitter, Telegram, Facebook, LinkedIn, WhatsApp, SnapChat, YouTube, Google, Discord, email (Outlook, Hotmail, Gmail, Rambler, Firstmail and others), proxies, virtual servers, advertising accounts, access to ChatGPT 5, gift cards and premium subscriptions to numerous services — and all this at the best prices!   SOCNET STARS is a service that helps you quickly and profitably purchase Telegram Stars and subscribe to Telegram Premium. Using our Telegram bot you can buy Telegram Stars at the lowest prices on the market and use them to pay for gifts, reactions, donations and other features inside Telegram.   Our bot also features a NEW gaming feature — gift slots, where users can win valuable prizes: Telegram gifts, bonuses from our partners and the SOCNET company, stars and premium subscriptions. The game mechanics are completely transparent: no tricks, only real luck decides. You can try it at any time — bets start from just 1 ruble. We also provide the opportunity for a one-time free spin!   Available payment methods: LOLZTEAM, Crypto Bot, Cryptocurrency, Bank cards and SBP ⭐ Our online store ⭐ SOCNET.STORE ⭐ Telegram store ⭐ SOCNET.SHOP ⭐ Our SMM Panel for social media promotion ⭐ SOCNET.PRO ⭐ Our Telegram bot for purchasing Telegram Stars ⭐ SOCNET.CC ⭐ Our SMS Service ⭐ SOCNET.APP ✅ News resources: ➡ Telegram channel ➡ WhatsApp channel ➡ Discord server ✅ Contacts and support: ➡ Telegram support ➡ WhatsApp support ➡ Discord support: socnet_support ➡ Email support: help@socnet.pro We have been operating for a long time and have gathered a huge list of reviews about our work! Our huge list of positive and honest reviews is presented on our website! ⭐We invite you to COOPERATE and EARN with us ⭐ Want to sell your product or service in our stores and make money? Become our partner or suggest mutually beneficial cooperation? You can contact us via the CONTACTS listed in this topic. If you have any questions or problems, our fast customer support is ready to respond to your requests! Refunds for a service that does not fully meet the requirements or quality are issued only if a guarantee and warranty period were specified in the product description. In all other cases, refunds for the service will not be fully processed or issued! By purchasing such a service, you automatically agree to our refund policy for non-provided services! We currently accept Any type of cryptocurrency (Cryptomus, Binance Pay, CryptoBot), any bank cards (VISA, Mastercard, MIR Pay, SBP), LolzTeam Market, Wise, Revolut, Paypal Friends&Families. We value every customer and provide replacements for invalid accounts and services through our contact methods!
    • SOCNET is a universal service that combines a digital goods store, an SMM panel, a Telegram bot for purchasing Telegram Stars and a Telegram bot for renting virtual numbers. Here you will find accounts for TikTok, Instagram, Reddit, Twitter, Telegram, Facebook, LinkedIn, WhatsApp, SnapChat, YouTube, Google, Discord, email (Outlook, Hotmail, Gmail, Rambler, Firstmail and others), proxies, virtual servers, advertising accounts, access to ChatGPT 5, gift cards and premium subscriptions to numerous services — and all this at the best prices!   SOCNET STARS is a service that helps you quickly and profitably purchase Telegram Stars and subscribe to Telegram Premium. Using our Telegram bot you can buy Telegram Stars at the lowest prices on the market and use them to pay for gifts, reactions, donations and other features inside Telegram.   Our bot also features a NEW gaming feature — gift slots, where users can win valuable prizes: Telegram gifts, bonuses from our partners and the SOCNET company, stars and premium subscriptions. The game mechanics are completely transparent: no tricks, only real luck decides. You can try it at any time — bets start from just 1 ruble. We also provide the opportunity for a one-time free spin!   Available payment methods: LOLZTEAM, Crypto Bot, Cryptocurrency, Bank cards and SBP ⭐ Our online store ⭐ SOCNET.STORE ⭐ Telegram store ⭐ SOCNET.SHOP ⭐ Our SMM Panel for social media promotion ⭐ SOCNET.PRO ⭐ Our Telegram bot for purchasing Telegram Stars ⭐ SOCNET.CC ⭐ Our SMS Service ⭐ SOCNET.APP ✅ News resources: ➡ Telegram channel ➡ WhatsApp channel ➡ Discord server ✅ Contacts and support: ➡ Telegram support ➡ WhatsApp support ➡ Discord support: socnet_support ➡ Email support: help@socnet.pro We have been operating for a long time and have gathered a huge list of reviews about our work! Our huge list of positive and honest reviews is presented on our website! ⭐We invite you to COOPERATE and EARN with us ⭐ Want to sell your product or service in our stores and make money? Become our partner or suggest mutually beneficial cooperation? You can contact us via the CONTACTS listed in this topic. If you have any questions or problems, our fast customer support is ready to respond to your requests! Refunds for a service that does not fully meet the requirements or quality are issued only if a guarantee and warranty period were specified in the product description. In all other cases, refunds for the service will not be fully processed or issued! By purchasing such a service, you automatically agree to our refund policy for non-provided services! We currently accept Any type of cryptocurrency (Cryptomus, Binance Pay, CryptoBot), any bank cards (VISA, Mastercard, MIR Pay, SBP), LolzTeam Market, Wise, Revolut, Paypal Friends&Families. We value every customer and provide replacements for invalid accounts and services through our contact methods!
  • Topics

×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..