Jump to content

Stefoulis15

Legendary Member
  • Posts

    2,588
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

Everything posted by Stefoulis15

  1. well this is goin to need a change to OnDeath of event. and then addadena and other things wont work. shouldnt i do it like this ? if(Config.ALLOW_HITMAN_GDE) Hitman.getInstance().onDeath((L2PcInstance)killer, this);
  2. honestly thats the only thing that i get ! java.lang.NullPointerException
  3. kl perimene na apantisei o tipas p ekane t thread.
  4. You mean this one? 2010.06.29 13:03:17,562 INFO 10 net.sf.l2j.Config loading gameserver config 2010.06.29 13:03:17,718 INFO 10 com.mchange.v2.log.MLog MLog clients using java 1.4+ standard logging. 2010.06.29 13:03:17,984 INFO 10 com.mchange.v2.c3p0.C3P0Registry Initializing c3p0-0.9.1.2 [built 21-May-2007 15:04:56; debug? true; trace: 10] 2010.06.29 13:03:18,390 INFO 10 com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 5, acquireRetryAttempts -> 0, acquireRetryDelay -> 500, autoCommitOnClose -> true, automaticTestTable -> connection_test_table, breakAfterAcquireFailure -> false, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge1368910e4l38146y00z|982589, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge1368910e4l38146y00z|982589, idleConnectionTestPeriod -> 3600, initialPoolSize -> 10, jdbcUrl -> jdbc:mysql://localhost/l2jdb, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 0, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 100, maxStatements -> 0, maxStatementsPerConnection -> 100, minPoolSize -> 10, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> null, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ] 2010.06.29 13:03:18,421 INFO 10 net.sf.l2j.gameserver.GameServer L2J Server Version: 108:118M 2010.06.29 13:03:18,421 INFO 10 net.sf.l2j.gameserver.GameServer L2J Datapack Version: 104:124M 2010.06.29 13:03:18,468 INFO 10 net.sf.l2j.gameserver.idfactory.IdFactory Updated characters online status. 2010.06.29 13:03:18,562 INFO 10 net.sf.l2j.gameserver.idfactory.IdFactory Cleaned 0 elements from database. 2010.06.29 13:03:18,734 INFO 10 net.sf.l2j.gameserver.idfactory.BitSetIDFactory IDFactory: 102912 id's available. 2010.06.29 13:03:19,828 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable SkillTreeTable: Loaded 35881 skills. 2010.06.29 13:03:20,031 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable FishingSkillTreeTable: Loaded 109 general skills. 2010.06.29 13:03:20,031 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable DwarvenSkillTreeTable: Loaded 8 dwarven skills. 2010.06.29 13:03:20,031 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable EnchantSkillTreeTable: Loaded 13769 enchant skills. 2010.06.29 13:03:20,031 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable PledgeSkillTreeTable: Loaded 64 pledge skills 2010.06.29 13:03:22,546 CONFIG 10 net.sf.l2j.gameserver.datatables.ItemTable ItemTable: Loaded 1014 Armors. 2010.06.29 13:03:22,562 CONFIG 10 net.sf.l2j.gameserver.datatables.ItemTable ItemTable: Loaded 6884 Items. 2010.06.29 13:03:22,812 CONFIG 10 net.sf.l2j.gameserver.datatables.ItemTable ItemTable: Loaded 1313 Weapons. 2010.06.29 13:03:23,312 CONFIG 10 net.sf.l2j.gameserver.TradeController TradeController: Loaded 526 Buylists. 2010.06.29 13:03:23,312 CONFIG 10 net.sf.l2j.gameserver.TradeController TradeController: Loaded 120 Limited Buylists. 2010.06.29 13:03:23,343 INFO 10 net.sf.l2j.gameserver.datatables.SpawnTable Initializing Walkers Routes Table. 2010.06.29 13:03:23,359 INFO 10 net.sf.l2j.gameserver.datatables.SpawnTable WalkerRoutesTable: Loaded 167 Npc Walker Routes. 2010.06.29 13:03:23,375 CONFIG 10 net.sf.l2j.gameserver.RecipeController RecipeController: Loaded 871 Recipes. 2010.06.29 13:03:23,390 INFO 10 net.sf.l2j.gameserver.datatables.BufferBuffTemplate BufferBuffTemplate: Loaded 4 List(s) 2010.06.29 13:03:23,390 CONFIG 10 net.sf.l2j.gameserver.datatables.ArmorSetsTable ArmorSetsTable: Loaded 51 armor sets. 2010.06.29 13:03:23,406 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable FishTable: Loaded 270 Fishes. 2010.06.29 13:03:23,406 CONFIG 10 net.sf.l2j.gameserver.datatables.ClanTable Restored 0 clans from the database. 2010.06.29 13:03:23,421 CONFIG 10 net.sf.l2j.gameserver.datatables.CharTemplateTable CharTemplateTable: Loaded 89 Character Templates. 2010.06.29 13:03:23,421 INFO 10 net.sf.l2j.gameserver.datatables.MaxCheatersTable MaxCheatersTable Loaded: 5 npc to pc entry(s) 2010.06.29 13:03:23,421 CONFIG 10 net.sf.l2j.gameserver.datatables.SkillTreeTable SkillSpellbookTable: Loaded 334 Spellbooks. 2010.06.29 13:03:23,421 INFO 10 net.sf.l2j.gameserver.cache.HtmCache Cache[html]: Running lazy cache 2010.06.29 13:03:23,453 INFO 10 net.sf.l2j.gameserver.cache.CrestCache Cache[Crest]: 0,000MB on 0 files loaded. (Forget Time: 300s , Capacity: 50) 2010.06.29 13:03:24,296 CONFIG 10 net.sf.l2j.gameserver.datatables.NpcTable NpcTable: Loaded 6526 Npc Templates. 2010.06.29 13:03:24,687 CONFIG 10 net.sf.l2j.gameserver.datatables.NpcTable NpcTable: Loaded 439 Minions. 2010.06.29 13:03:24,687 CONFIG 10 net.sf.l2j.gameserver.datatables.HennaTable HennaTable: Loaded 180 Templates. 2010.06.29 13:03:24,750 CONFIG 10 net.sf.l2j.gameserver.datatables.HennaTreeTable HennaTreeTable: Loaded 7128 Henna Tree Templates. 2010.06.29 13:03:24,750 CONFIG 10 net.sf.l2j.gameserver.datatables.HennaTable Helper Buff Table: Loaded 14 Templates. 2010.06.29 13:03:24,750 INFO 10 net.sf.l2j.gameserver.GeoData Geodata Engine: Disabled. 2010.06.29 13:03:24,812 CONFIG 10 net.sf.l2j.gameserver.model.L2World L2World: Setting up World Regions 2010.06.29 13:03:24,859 CONFIG 10 net.sf.l2j.gameserver.model.L2World L2World: (87 by 128) World Region Grid set up. 2010.06.29 13:03:24,890 CONFIG 10 net.sf.l2j.gameserver.datatables.TeleportLocationTable TeleportLocationTable: Loaded 682 Teleport Location Templates. 2010.06.29 13:03:24,890 CONFIG 10 net.sf.l2j.gameserver.datatables.LevelUpData LevelUpData: Loaded 89 Character Level Up Templates. 2010.06.29 13:03:24,906 INFO 10 net.sf.l2j.gameserver.datatables.ZoneData Loading zones... 2010.06.29 13:03:25,062 INFO 10 net.sf.l2j.gameserver.instancemanager.TownManager Initializing TownManager 2010.06.29 13:03:25,750 INFO 10 net.sf.l2j.gameserver.datatables.ZoneData Done: loaded 111 zones. 2010.06.29 13:03:31,562 INFO 10 net.sf.l2j.gameserver.instancemanager.DayNightSpawnManager DayNightSpawnManager: Day/Night handler initialised 2010.06.29 13:03:32,750 CONFIG 10 net.sf.l2j.gameserver.datatables.SpawnTable SpawnTable: Loaded 39422 Npc Spawn Locations. 2010.06.29 13:03:32,843 INFO 10 net.sf.l2j.gameserver.instancemanager.RaidBossSpawnManager RaidBossSpawnManager: Loaded 179 Instances 2010.06.29 13:03:32,843 INFO 10 net.sf.l2j.gameserver.instancemanager.RaidBossSpawnManager RaidBossSpawnManager: Scheduled 0 Instances 2010.06.29 13:03:32,843 INFO 10 net.sf.l2j.gameserver.instancemanager.DayNightSpawnManager DayNightSpawnManager: Deleted 0 night creatures 2010.06.29 13:03:32,859 INFO 10 net.sf.l2j.gameserver.instancemanager.DayNightSpawnManager DayNightSpawnManager: Spawning 232 day creatures 2010.06.29 13:03:32,859 INFO 10 net.sf.l2j.gameserver.instancemanager.DimensionalRiftManager DimensionalRiftManager: Loaded 7 room types with 56 rooms. 2010.06.29 13:03:32,875 INFO 10 net.sf.l2j.gameserver.instancemanager.DimensionalRiftManager DimensionalRiftManager: Loaded 462 dimensional rift spawns, 0 errors. 2010.06.29 13:03:32,875 CONFIG 10 net.sf.l2j.gameserver.Announcements Announcements: Loaded 3 Announcements. 2010.06.29 13:03:32,875 INFO 10 net.sf.l2j.gameserver.model.L2Manor ManorManager: Loaded 256 seeds 2010.06.29 13:03:32,953 INFO 10 net.sf.l2j.gameserver.instancemanager.CastleManorManager Initializing CastleManorManager 2010.06.29 13:03:32,953 INFO 10 net.sf.l2j.gameserver.instancemanager.CastleManorManager Manor System: Manor refresh updated 2010.06.29 13:03:32,968 INFO 10 net.sf.l2j.gameserver.instancemanager.CastleManorManager Manor System: Manor period approve updated 2010.06.29 13:03:32,968 INFO 10 net.sf.l2j.gameserver.instancemanager.CastleManorManager Manor System: New Schedule for period approve @ Wed Jun 30 06:00:32 EEST 2010 2010.06.29 13:03:48,500 INFO 10 net.sf.l2j.gameserver.model.entity.events.Hitman Hitman: Loaded 0 Assassination Target(s) 2010.06.29 13:03:48,500 INFO 10 net.sf.l2j.gameserver.datatables.AugmentationData Initializing AugmentationData. 2010.06.29 13:03:48,515 INFO 10 net.sf.l2j.gameserver.datatables.AugmentationData AugmentationData: Loaded: 52 augmentation stats. 2010.06.29 13:03:48,515 INFO 10 net.sf.l2j.gameserver.datatables.AugmentationData AugmentationData: Loaded: 82 active, 21 passive and 75 chance skills 2010.06.29 13:03:48,531 WARNING 10 net.sf.l2j.gameserver.datatables.DoorTable Searching clan halls doors: 2010.06.29 13:03:48,593 CONFIG 10 net.sf.l2j.gameserver.datatables.DoorTable DoorTable: Loaded 548 Door Templates. 2010.06.29 13:03:48,593 CONFIG 10 net.sf.l2j.gameserver.datatables.StaticObjects StaticObject: Loaded 29 StaticObject Templates. 2010.06.29 13:03:48,640 INFO 10 net.sf.l2j.gameserver.SevenSigns SevenSigns: Currently in the Competition (Quest Event) period! 2010.06.29 13:03:48,640 INFO 10 net.sf.l2j.gameserver.SevenSigns SevenSigns: The Seal of Avarice remains unclaimed. 2010.06.29 13:03:48,640 INFO 10 net.sf.l2j.gameserver.SevenSigns SevenSigns: The Seal of Gnosis remains unclaimed. 2010.06.29 13:03:48,640 INFO 10 net.sf.l2j.gameserver.SevenSigns SevenSigns: The Seal of Strife remains unclaimed. 2010.06.29 13:03:48,640 INFO 10 net.sf.l2j.gameserver.SevenSigns SevenSigns: The competition, if the current trend continues, will end in a tie this week. 2010.06.29 13:03:48,640 INFO 10 net.sf.l2j.gameserver.SevenSigns SevenSigns: Next period begins in 6 days, 4 hours and 56 mins. 2010.06.29 13:03:48,656 INFO 10 net.sf.l2j.gameserver.SevenSignsFestival SevenSignsFestival: The first Festival of Darkness cycle begins in 2 minute(s). 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Loading Olympiad System.... 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Currently in Olympiad Period 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Period Ends.... 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: In 18 days, 22 hours and 56 mins. 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Next Weekly Change is in.... 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: 7 days, 0 hours and 0 mins. 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Loaded 0 Nobles 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Competition Period Starts in 0 days, 4 hours and 57 mins. 2010.06.29 13:03:48,765 INFO 10 net.sf.l2j.gameserver.model.Olympiad.Olympiad Olympiad System: Event starts/started : Tue Jun 29 18:00:48 EEST 2010 2010.06.29 13:03:48,781 INFO 10 net.sf.l2j.gameserver.model.entity.Hero Hero System: Loaded 0 Heroes. 2010.06.29 13:03:48,781 INFO 10 net.sf.l2j.gameserver.model.entity.Hero Hero System: Loaded 0 all time Heroes. 2010.06.29 13:03:48,859 WARNING 10 net.sf.l2j.gameserver.script.faenor.FaenorEventParser Event ID: (Valentines Event) has passed... Ignored. 2010.06.29 13:03:48,875 INFO 10 net.sf.l2j.gameserver.instancemanager.CursedWeaponsManager Initializing CursedWeaponsManager 2010.06.29 13:03:50,140 INFO 10 net.sf.l2j.gameserver.instancemanager.CursedWeaponsManager Loaded : 2 cursed weapon(s). 2010.06.29 13:03:50,140 CONFIG 10 net.sf.l2j.gameserver.GameServer AutoChatHandler: Loaded 32 handlers in total. 2010.06.29 13:03:50,140 CONFIG 10 net.sf.l2j.gameserver.GameServer AutoSpawnHandler: Loaded 129 handlers in total. 2010.06.29 13:03:50,156 CONFIG 10 net.sf.l2j.gameserver.GameServer ItemHandler: Loaded 2011 handlers. 2010.06.29 13:03:50,187 CONFIG 10 net.sf.l2j.gameserver.GameServer SkillHandler: Loaded 71 handlers. 2010.06.29 13:03:50,250 CONFIG 10 net.sf.l2j.gameserver.GameServer AdminCommandHandler: Loaded 350 handlers. 2010.06.29 13:03:50,250 CONFIG 10 net.sf.l2j.gameserver.GameServer UserCommandHandler: Loaded 14 handlers. 2010.06.29 13:03:50,265 CONFIG 10 net.sf.l2j.gameserver.GameServer VoicedCommandHandler: Loaded 10 handlers. 2010.06.29 13:03:50,265 INFO 10 net.sf.l2j.gameserver.instancemanager.CoupleManager L2JMOD: Initializing CoupleManager 2010.06.29 13:03:50,265 INFO 10 net.sf.l2j.gameserver.instancemanager.CoupleManager Loaded: 0 couples(s) 2010.06.29 13:03:50,406 CONFIG 10 net.sf.l2j.gameserver.GameServer IdFactory: Free ObjectID's remaining: 1879004508 2010.06.29 13:03:50,406 INFO 10 net.sf.l2j.gameserver.util.FloodProtector Initializing FloodProtector 2010.06.29 13:03:51,625 INFO 10 net.sf.l2j.gameserver.GameServer GameServer Started, free memory 709 Mb of 989 Mb 2010.06.29 13:03:51,625 INFO 11 net.sf.l2j.gameserver.LoginServerThread Connecting to login on 127.0.0.1:9014 2010.06.29 13:03:51,796 CONFIG 10 net.sf.l2j.gameserver.GameServer Maximum Numbers of Connected Players: 1000 2010.06.29 13:03:52,078 INFO 11 net.sf.l2j.gameserver.LoginServerThread Registered on login as Server 1 : Overdose 2010.06.29 13:05:55,703 INFO 12 net.sf.l2j.gameserver.instancemanager.CrownManager CrownManager: initialized 2010.06.29 13:14:44,390 SEVERE 13 net.sf.l2j.gameserver.model.L2Character java.lang.NullPointerException
  5. Well , I've tried to adapt Hitman Event From Gracia Final to Interlude without any problem. i compiled my serverpack and then i logged in to test it, i set the bounty to my 2nd char successfully , but when i tried to kill my 2nd char with my 1st char i get an NPE Error on my gs console, and IG i get no adena reward and no msg that my target was assasinated or sth. i tried a lot of things but nothing worked. something that might help : NPE error on gs ( ffs ) : java.lang.NullPointerException Error on .log file : 2010.06.29 13:14:44,390 SEVERE 13 net.sf.l2j.gameserver.model.L2Character java.lang.NullPointerException
  6. eukolo. o barman evgale to oplo g na tn fovisei kai na tou figei o loksigas.k o tipas tn eyxaristise gt tou efige. :)
  7. well mate u came to the wrong place.. if u really wish to find a good pack with the most bugs fixed and also with the best support around , wait for archid to release their packs and buy a premium membership. else , create ur own. P.S: u can also use l2jbrasil
  8. sorry if i bump the post guyz. well i got a problem. i've made it for interlude. everything works fine. i set the bounty to the player i want and then when i kill him , i get an npe error on the gs console and also i get nothing for killing him. -.-' i've tried to fix it , but i made nothing! any ideas?
  9. m pan k mena oti gnt afto k psaxnw na dw tr.. :/
  10. an k eimai tou ksenou hiphop p kserei g t milaei oriste ena elliniko p m aresei. einai low bap an dn kanw la8os dn t paw k toso kala me ta eidh...
  11. lolz u are teh imba proest nigz0r dev! +1 to cod3x. nothing personal. just voting! ( BTW WTF Is Intrepid and setekh in there? lolz they shouldnt even compare with those guyz )
  12. Well , i've seen cobra's share about making new bypasses and those things. and i was thinking dammit , that shit exists already in lineage 2 ( tutorial book) so why to make new bypasses since we can use the old ones.? lets say now that u made an item for this thing. and its id is 9999. go to Book.java ( gameserver/handler/itemhandlers/ ) and find the line : and simply after 7112 add your item id. guess what. core side is done. the only thing you got to do now , is to create the htmls. easy! go to data/html/help in your datapack and create an html named 9999.htm and you are done. when in need of creating something like bypassing from one 9999.htm to 9999-1.htm do this : easy right? enjoy!
  13. well , since it's your opinion i got to respect it. but also i got to defend since u offend my server. now what makes you think that it will fail from the first week? u know us? u worked with us? or did u even thought before posting? please. i dunno if you are always like that , if u are just jealous or u got any problem with me , revenger or our server but u should really check it out.
  14. actually... ITS FREAKING AWESOME! This is like woah! gratz mate. really cool share.
  15. http://www.leagueoflegends.com/playnow/?redirect=http://www.leagueoflegends.com/board/showthread.php%3Ft%3D11751 this might help. i just googled it.
  16. well , the last version i've shared hadn't any restrictions about level and active subclass. eh , this gives you noblesse tiara when u click the item also , when u clicked appeared the social action that appears when you become a hero. now its just a firework effect. last one, the other wasnt that configurable. the only config was enable/disable. now it has configs about the restrictions , the item id and enable/disable.
  17. Well , It's Been AGES since i shared this thing , and i thought it would be better if i shared the new version to you. no more talking. Here's The Diff: Index: java/config/l2jmods.properties =================================================================== --- java/config/l2jmods.properties (revision 4307) +++ java/config/l2jmods.properties (working copy) @@ -132,3 +132,20 @@ # ex.: 1;2;3;4;5;6 # no ";" at the start or end TvTEventDoorsCloseOpenOnStartEnd = + +#---------------------# +#Noblesse Item Configs +#---------------------# +NoblesseItemEnabled = False + +# ID Of The Noblesse Item +# Default : 6673 ( Festival Adena ) +NoblesseItemId = 6673 + +# Noblesse Item Lvl Restriction +# A Player Lower than 76 level won't be able to use this item +NoblesseItemLvlRestriction = True + +# Noblesse Item Sub Restriction +# A Player That is not with his subclass won't be able to use this item +NoblesseItemSubRestriction = True \ No newline at end of file Index: java/net/sf/l2j/Config.java =================================================================== --- java/net/sf/l2j/Config.java (revision 4307) +++ java/net/sf/l2j/Config.java (working copy) @@ -882,6 +882,11 @@ public static boolean L2JMOD_WEDDING_FORMALWEAR; public static int L2JMOD_WEDDING_DIVORCE_COSTS; + public static int NOBLESSE_ITEM_ID; + public static boolean NOBLESSE_ITEM_LEVEL_RESTRICTION; + public static boolean NOBLESSE_ITEM_SUBCLASS_RESTRICTION; + public static boolean NOBLESSE_ITEM_ENABLED; + // Packet information /** Count the amount of packets per minute ? */ public static boolean COUNT_PACKETS = false; @@ -1858,7 +1863,11 @@ 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")); - + NOBLESSE_ITEM_ID = Integer.parseInt(L2JModSettings.getProperty("NoblesseItemId", "6673")); + NOBLESSE_ITEM_LEVEL_RESTRICTION = Boolean.parseBoolean(L2JModSettings.getProperty("NoblesseItemLvlRestriction", "True")); + NOBLESSE_ITEM_SUBCLASS_RESTRICTION = Boolean.parseBoolean(L2JModSettings.getProperty("NoblesseItemSubRestriction", "True")); + NOBLESSE_ITEM_ENABLED = Boolean.parseBoolean(L2JModSettings.getProperty("NoblesseItemEnabled", "False")); + if (TVT_EVENT_PARTICIPATION_NPC_ID == 0) { TVT_EVENT_ENABLED = false; Index: java/net/sf/l2j/gameserver/GameServer.java =================================================================== --- java/net/sf/l2j/gameserver/GameServer.java (revision 4307) +++ java/net/sf/l2j/gameserver/GameServer.java (working copy) @@ -136,6 +136,7 @@ import net.sf.l2j.gameserver.handler.itemhandlers.Harvester; import net.sf.l2j.gameserver.handler.itemhandlers.MercTicket; import net.sf.l2j.gameserver.handler.itemhandlers.MysteryPotion; +import net.sf.l2j.gameserver.handler.itemhandlers.NoblesseItem; import net.sf.l2j.gameserver.handler.itemhandlers.PaganKeys; import net.sf.l2j.gameserver.handler.itemhandlers.Potions; import net.sf.l2j.gameserver.handler.itemhandlers.Recipes; @@ -476,6 +477,10 @@ _itemHandler.registerItemHandler(new SpecialXMas()); _itemHandler.registerItemHandler(new SummonItems()); _itemHandler.registerItemHandler(new BeastSpice()); + + if (Config.NOBLESSE_ITEM_ENABLED) + _itemHandler.registerItemHandler(new NoblesseItem()); + _log.config("ItemHandler: Loaded " + _itemHandler.size() + " handlers."); _skillHandler = SkillHandler.getInstance(); Index: java/net/sf/l2j/gameserver/handler/itemhandlers/NoblesseItem.java =================================================================== --- java/net/sf/l2j/gameserver/handler/itemhandlers/NoblesseItem.java (revision 0) +++ java/net/sf/l2j/gameserver/handler/itemhandlers/NoblesseItem.java (revision 0) @@ -0,0 +1,54 @@ +package net.sf.l2j.gameserver.handler.itemhandlers; + +import net.sf.l2j.Config; +import net.sf.l2j.gameserver.handler.IItemHandler; +import net.sf.l2j.gameserver.model.L2ItemInstance; +import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance; +import net.sf.l2j.gameserver.model.actor.instance.L2PlayableInstance; +import net.sf.l2j.gameserver.serverpackets.MagicSkillUser; + +public class NoblesseItem implements IItemHandler +{ + private static final int ITEM_IDS[] = + { + Config.NOBLESSE_ITEM_ID + }; + + public void useItem(L2PlayableInstance playable, L2ItemInstance item) + { + if(!(playable instanceof L2PcInstance)) + return; + L2PcInstance activeChar = (L2PcInstance)playable; + if(activeChar.isNoble()) + { + activeChar.sendMessage("You Are Already A Noblesse!"); + return; + } + if (activeChar.getLevel() < 76 && Config.NOBLESSE_ITEM_LEVEL_RESTRICTION) + { + activeChar.sendMessage("You Must Be Over 76 Level To Use This Item!"); + return; + } + if (!activeChar.isSubClassActive() && Config.NOBLESSE_ITEM_SUBCLASS_RESTRICTION) + { + activeChar.sendMessage("You Must Be With Your Subclass To Use This Item!"); + return; + } + else + { + MagicSkillUser MSU = new MagicSkillUser(playable, activeChar, 2023, 1, 1, 0); + activeChar.sendPacket(MSU); + activeChar.broadcastPacket(MSU); + activeChar.setNoble(true); + activeChar.sendMessage("You Are Now a Noble,You Are Granted With Noblesse Status , And Noblesse Skills."); + activeChar.broadcastUserInfo(); + activeChar.getInventory().addItem("Noblesse Tiara",7694, 1, activeChar, playable); + playable.destroyItem("Consume", item.getObjectId(), 1, null, false); + } + } + + public int[] getItemIds() + { + return ITEM_IDS; + } +} \ No newline at end of file Enjoy.
×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock