Jump to content

Rizlaaa

Members
  • Posts

    362
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

Everything posted by Rizlaaa

  1. +1 Δε μπορει κανενας να μην το ειδε αυτο , ελεος.
  2. And why the method is synchronized?
  3. Just created a character and loged in. Whoever want to play like a team ( clan , etc ) pm me in game: iRatana Good Luck.
  4. Εκεί που γράφει l2jfrozen console να γράφει l2jserver by Μ@n80$ και να είναι βασισμένο σε l2j clean. Όπως είναι το L2jKatara Οποτε ναι , αν γι αυτον αυτο θεωρειται δικο του project, τοτε ναι το πιστευω . Αυτο ειπε αν καταλαβες καλα.
  5. κανενα error στο gameserver?
  6. lol; Το gameserver.bat αλλαζεις για να το κανεις αυτο.
  7. το εχει ηδη το source σου, αν κοιτουσες θα το βλεπες , σου ειπα σε ποιο αρχειο.
  8. δε θα σου πω ακριβως , σκεψου. Ειναι απλο να το καταλαβεις... public void setHtml(String text) { if(text.length() > 8192) { _log.warning("Html is too long! this will crash the client!"); _html = "<html><body>Html was too long</body></html>"; return; } _html = text; // html code must not exceed 8192 bytes } if(text.length() > 8192) αυτο σημαινει αν το μεγεθος του html ειναι πανω απο 8192 χαρακτηρες _html = "<html><body>Html was too long</body></html>"; return; τοτε να βγαζει αυτο το σφαλμα. Σκεψου δε χρειαζεται γνωσεις για να το fixareis , θελει να πειραματιστεις ομως.
  9. Να μην τα πολυλογουμε και τσαμπα και καλο δε θα βρεις τελος. Παμε τωρα στο κυριο μερος. Τι εννοεις λεγοντας πως να κανουμε ενα pack? Κανεις compile l2j καθαρο ή οτι αλλο θες , και απλα περνας οτι θελεις. Τωρα αν ξεκινησεις με l2j , δε θα καταφερεις και τιποτα σπουδαιο αν δεν ξερεις java. Αν κατσεις να μαθεις λιγο java , και να μπορεις να χειριζεσαι λιγο πολυ το source , τοτε κατι γινεται.
  10. thank you
  11. LOL I was at the top list in the old L2Dream. I don't believe it is old one , I will give a try.
  12. ★PictureMyPain★ just stfu man , pentoy is the real owner of L2Battle and all know it.He is Cod3x.
  13. Python. αν θες με java... το μονο pack που εχει java engine για τα quests ειναι το aCis.
  14. NpcHtmlMessage.java public void setHtml(String text) { if(text.length() > 8192) { _log.warning("Html is too long! this will crash the client!"); _html = "<html><body>Html was too long</body></html>"; return; } _html = text; // html code must not exceed 8192 bytes } πειραματησου..
  15. restriction μπορει να βαλει ο καθενας πιστευω , απλα αυτο ειναι το βασικο δηλαδη το σημαντικο μερος.
  16. thank you bro :)
  17. Requested και αυτο επισης αρα το κανω share, ειναι απλο. Π.χ ενας gm θελει να κανει δικο του event και βαριεται να κανει recall Ολους τους παιχτες η μπορει και καποιος να μη θελει. Απλα παταει //register_available και ολοι μπορουν να πατανε .joinevent για να παρουν μερος.Επισης υπαρχει και το .eventinfo που εχει πληροφοριες.Τελος..ενα μετα απο 10 λεπτα (default) γινονται teleport οσοι πατησαν joinevent ### Eclipse Workspace Patch 1.0 #P aVa Tester Index: java/net/sf/l2j/gameserver/handler/admincommandhandlers/AdminEvent.java =================================================================== --- java/net/sf/l2j/gameserver/handler/admincommandhandlers/AdminEvent.java (revision 0) +++ java/net/sf/l2j/gameserver/handler/admincommandhandlers/AdminEvent.java (revision 0) @@ -0,0 +1,105 @@ +/* + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more + * details. + * + * You should have received a copy of the GNU General Public License along with + * this program. If not, see <http://www.gnu.org/licenses/>. + */ +package net.sf.l2j.gameserver.handler.admincommandhandlers; + +import javolution.util.FastList; + +import net.sf.l2j.Config; +import net.sf.l2j.gameserver.Announcements; +import net.sf.l2j.gameserver.ThreadPoolManager; +import net.sf.l2j.gameserver.handler.IAdminCommandHandler; +import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance; + +/** + * @author irat + * + */ +public class AdminEvent implements IAdminCommandHandler +{ + + public static FastList<L2PcInstance> players = new FastList<L2PcInstance>(); + private static boolean active = false; + private final String[] command = {"admin_register_available"}; + + private int minutes = Config.MINUTES_OPEN; + + public static boolean isActive() + { + return active; + } + + public static void setActive(boolean t) + { + active = t; + } + + @Override + public boolean useAdminCommand(String command, L2PcInstance activeChar) + { + if(activeChar == null) + return false; + + if(command.equalsIgnoreCase("admin_register_available")) + { + if(isActive()) + { + activeChar.sendMessage("You have already open the registrations"); + return false; + } + + setActive(true); + + int time = minutes * 60000; + + Announcements.getInstance().announceToAll("Event registrations opened , type .joinevent to join. You have 10 minutes..."); + ThreadPoolManager.getInstance().scheduleGeneral(new Close(activeChar), time); + } + + return true; + } + + + private class Close implements Runnable{ + + private L2PcInstance p; + + private Close(L2PcInstance j) + { + p = j; + } + + public void run() + { + setActive(false); + Announcements.getInstance().announceToAll("Registrations closed"); + if(p != null) + for(L2PcInstance k : players) + { + if(k == null) + continue; + + k.teleToLocation(p.getX(), p.getY(), p.getZ()); + players.clear(); + } + } + } + + + @Override + public String[] getAdminCommandList() + { + return command; + } + +} Index: java/net/sf/l2j/gameserver/GameServer.java =================================================================== --- java/net/sf/l2j/gameserver/GameServer.java (revision 13) +++ java/net/sf/l2j/gameserver/GameServer.java (working copy) @@ -86,6 +86,7 @@ import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminEditNpc; import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminEffects; import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminEnchant; +import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminEvent; import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminEventEngine; import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminExpSp; import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminFightCalculator; @@ -202,6 +203,7 @@ import net.sf.l2j.gameserver.handler.usercommandhandlers.Time; import net.sf.l2j.gameserver.handler.voicedcommandhandlers.Wedding; import net.sf.l2j.gameserver.handler.voicedcommandhandlers.castle; +import net.sf.l2j.gameserver.handler.voicedcommandhandlers.joinevent; import net.sf.l2j.gameserver.idfactory.IdFactory; import net.sf.l2j.gameserver.instancemanager.AuctionManager; import net.sf.l2j.gameserver.instancemanager.BoatManager; @@ -516,6 +518,8 @@ _adminCommandHandler = AdminCommandHandler.getInstance(); _adminCommandHandler.registerAdminCommandHandler(new AdminAdmin()); + if(Config.ALLOW_EVENT_COMMANDS) + _adminCommandHandler.registerAdminCommandHandler(new AdminEvent()); _adminCommandHandler.registerAdminCommandHandler(new AdminInvul()); _adminCommandHandler.registerAdminCommandHandler(new AdminDelete()); _adminCommandHandler.registerAdminCommandHandler(new AdminKill()); @@ -594,6 +598,9 @@ if(Config.L2JMOD_ALLOW_WEDDING) _voicedCommandHandler.registerVoicedCommandHandler(new Wedding()); + + if(Config.ALLOW_EVENT_COMMANDS) + _voicedCommandHandler.registerVoicedCommandHandler(new joinevent()); _log.config("VoicedCommandHandler: Loaded " + _voicedCommandHandler.size() + " handlers."); Index: java/net/sf/l2j/gameserver/handler/voicedcommandhandlers/joinevent.java =================================================================== --- java/net/sf/l2j/gameserver/handler/voicedcommandhandlers/joinevent.java (revision 0) +++ java/net/sf/l2j/gameserver/handler/voicedcommandhandlers/joinevent.java (revision 0) @@ -0,0 +1,75 @@ +/* + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more + * details. + * + * You should have received a copy of the GNU General Public License along with + * this program. If not, see <http://www.gnu.org/licenses/>. + */ +package net.sf.l2j.gameserver.handler.voicedcommandhandlers; + +import net.sf.l2j.gameserver.handler.IVoicedCommandHandler; +import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance; +import net.sf.l2j.gameserver.handler.admincommandhandlers.AdminEvent; + +/** + * @author irat + * + */ +public class joinevent implements IVoicedCommandHandler +{ + + private final String[] command = {"joinevent","eventinfo"}; + + @Override + public boolean useVoicedCommand(String command, L2PcInstance activeChar, String target) + { + if(activeChar == null) + return false; + + if(command.equalsIgnoreCase("joinevent")) + { + if(AdminEvent.players.contains("activeChar")) + { + activeChar.sendMessage("You have already registed!"); + return false; + } + + if(!AdminEvent.isActive()) + return false; + + AdminEvent.players.add(activeChar); + activeChar.sendMessage("You registed successfully!"); + } + else if(command.equalsIgnoreCase("eventinfo")) + { + if(!AdminEvent.isActive()) + { + activeChar.sendMessage("Event isn't active."); + return false; + } + + activeChar.sendMessage("---Event is Active---"); + activeChar.sendMessage("---Players Registed:"+AdminEvent.players.size()+"---"); + activeChar.sendMessage("---You are registed:"+AdminEvent.players.contains(activeChar)+ "---"); + } + + return true; + } + + /* (non-Javadoc) + * @see net.sf.l2j.gameserver.handler.IVoicedCommandHandler#getVoicedCommandList() + */ + @Override + public String[] getVoicedCommandList() + { + return command; + } + +} Index: java/net/sf/l2j/Config.java =================================================================== --- java/net/sf/l2j/Config.java (revision 13) +++ java/net/sf/l2j/Config.java (working copy) @@ -859,6 +859,9 @@ public static boolean L2JMOD_WEDDING_SAMESEX; public static boolean L2JMOD_WEDDING_FORMALWEAR; public static int L2JMOD_WEDDING_DIVORCE_COSTS; + + public static boolean ALLOW_EVENT_COMMANDS; + public static int MINUTES_OPEN; // Packet information /** Count the a-beep-t of packets per minute ? */ @@ -1832,6 +1835,8 @@ L2JMOD_WEDDING_FORMALWEAR = Boolean.parseBoolean(L2JModSettings.getProperty("WeddingFormalWear", "True")); L2JMOD_WEDDING_DIVORCE_COSTS = Integer.parseInt(L2JModSettings.getProperty("WeddingDivorceCosts", "20")); + ALLOW_EVENT_COMMANDS = Boolean.valueOf(L2JModSettings.getProperty("AllowEventCommands","True")); + MINUTES_OPEN = Integer.parseInt(L2JModSettings.getProperty("MinutesOpen","10")); } catch (Exception e) { Index: java/config/l2jmods.properties =================================================================== --- java/config/l2jmods.properties (revision 13) +++ java/config/l2jmods.properties (working copy) @@ -90,3 +90,9 @@ WeddingFormalWear=True #Cost of Divorce, % of Adena WeddingDivorceCosts=20 + +#Event configs +#allow? +AllowEventCommands = True +#Minutes to wait for register +MinutesOpen = 10 \ No newline at end of file
  18. Requested σε pm και ειπα να το κανω share,ισως το θελει καποιος. Ενα απλο npc που οποιος παιχτης παει διπλα του τον κανει heal αυτοματα χωρις target , τπτ.Επισης οποιος δει τον κωδικα και απορει αν ο κωδικας μπορει να φερει lag , η απαντηση ειναι ΟΧΙ και ο λογος ειναι οτι χιλιαδες tasks τρεχουν την ιδια ωρα.Σκεφτειτε οτι το baium κανει ανα 1-2 δευτερολεπτο actions που χρησιμοποιουν tasks.Αρα δεν υπαρχει προβλημα.. Type στο navicat: L2Healer /* * This program is free software: you can redistribute it and/or modify it under * the terms of the GNU General Public License as published by the Free Software * Foundation, either version 3 of the License, or (at your option) any later * version. * * This program is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more * details. * * You should have received a copy of the GNU General Public License along with * this program. If not, see <http://www.gnu.org/licenses/>. */ package net.sf.l2j.gameserver.model.actor.instance; import java.util.concurrent.ScheduledFuture; import net.sf.l2j.gameserver.ThreadPoolManager; import net.sf.l2j.gameserver.datatables.SkillTable; import net.sf.l2j.gameserver.model.L2Skill; import net.sf.l2j.gameserver.serverpackets.MagicSkillUser; import net.sf.l2j.gameserver.templates.L2NpcTemplate; /** * @author irat * */ public class L2HealerInstance extends L2NpcInstance { private ScheduledFuture<?> _aiTask; public L2HealerInstance(int objectId, L2NpcTemplate template) { super(objectId, template); if (_aiTask != null) _aiTask.cancel(true); _aiTask = ThreadPoolManager.getInstance().scheduleAiAtFixedRate(new Heal(this), 3000, 3000); } public void deleteMe() { if (_aiTask != null) { _aiTask.cancel(true); _aiTask = null; } } private class Heal implements Runnable { private L2HealerInstance _heal; protected Heal(L2HealerInstance caster) { _heal = caster; } public void run() { L2Skill skill = SkillTable.getInstance().getInfo(1218, 1); for (L2PcInstance player : getKnownList().getKnownPlayersInRadius(100)) { if(player == null) continue; player.sendPacket(new MagicSkillUser(player, player, 1218, 1, skill.getHitTime(),0)); player.setCurrentHp(player.getMaxHp()); player.setCurrentCp(player.getMaxCp()); player.setCurrentMp(player.getMaxMp()); } } } }
  19. Pm sent.
  20. Thanks ;) Forgot to told you that i took some htm from your vote reward :D
  21. Thank. I don't know Rain and neither his code( i saw his code i mean the way he did it). Anyway thank you again
  22. Like world of warcraft. In the video in the end i stucked a bit in the wall(but it's not problem)because i haven't geodata. The command i pressed ( sorry for that , that it didn't show it ) is ?auto_pilot? (you just write this in chat without / or . ) Sorry for quality and for video general , i made it very fast. Maybe i will add a better one. Anyway you will be informed for everything if you contact with me. Prize: Negotiable beetween 10-25 Euros Contact me at iracundusgr@live.com or pm me here
  23. You can trust this guy , he is trusted and for sure skilled guy :D , good luck.
×
×
  • Create New...