-
Posts
4,504 -
Joined
-
Last visited
-
Days Won
1 -
Feedback
0%
Content Type
Articles
Profiles
Forums
Store
Everything posted by Matim
-
This is section about L2J not about Videos..
-
Java - How to create Your own /commands
Matim replied to Matim's topic in Server Development Discussion [L2J]
If somone has found any bugg's or somethink like that , please report it to me. -
Raid Boss Respawn Time
Matim replied to masterlan's question in Request Server Development Help [Greek]
Sory , wrong section , please delete this post , sory again :-\ -
[Share]How to have auto TvT(simply way for niebies)
Matim replied to Sr.Set's topic in Server Development Discussion [L2J]
I think DM cant be auto started...why ? Becouse You must manualy start registration , event starting and event finishing -
Ok . Everyone know how to create these commands like .command , but now i want to say how to create thats /command . I think it look much better ;) This guide is for L2J files , if somone want make it for other pack , should change imports . Ok . As We know...in newest L2J rev , we have handlers in DataPack ( .java files ) so we dont must compile them in core to make them working . Ok . For example we want to create command and when we use it , it will show us window with our text . 1 . First step : You should open : data\scripts\handlers\usercommandhandlers 2. Second Step : Create new .java file . For example ServerInfo.java 3. Third Step : - Ok , We have our .java file . So now We must open this file and start writing : /* * 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/>. */ We know , this is GNU license , dont forget to paste it in our file . - Then We must import some classes needed for shown html window in game , so : package handlers.usercommandhandlers; import net.sf.l2j.gameserver.handler.IUserCommandHandler; import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance; import net.sf.l2j.gameserver.network.serverpackets.NpcHtmlMessage; Ok , we have imported needed classes from core , now we must create our class : public class ServerInfo implements IUserCommandHandler { private static final int[] COMMAND_IDS = { 121 }; Now all should ask...omg but what is that ? What its this ID ( 121 in this example ) . The answer is simple : This is ID form our client . We can define this in : commandname-e.dat file . Ok , download FileEdit and open this fille , we should have somethink like that : - Ok , first column if for command number ( 1,2,3,4,5,5 ... ) - Secound column is for command ID - yes we need it in our class ( I'ill show it again , where we will put ID ) : Ok , we want to add that command : /serverinfo , so we must put : - 122 in first column , becouse last one was 121 .. ( we are smarts - yeah ;) ) - 121 in secound column , becouse last one was 120 ... ok this is our comman ID , we must this into our class ( look upper , to show where put this ... ) - And in third column we must add : Now when we use /serverinfo in game , server will try to use command with 121 ID So it look like this : - Close and save file , this is it ;) Now add to our script this : Done , our ServerInfo.java should look that : /* * 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 handlers.usercommandhandlers; import net.sf.l2j.gameserver.handler.IUserCommandHandler; import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance; import net.sf.l2j.gameserver.network.serverpackets.NpcHtmlMessage; /** * Support for /serverinfo command * Added by Matim */ public class ServerInfo implements IUserCommandHandler { private static final int[] COMMAND_IDS = { 121 }; /** * * @see net.sf.l2j.gameserver.handler.IUserCommandHandler#useUserCommand(int, net.sf.l2j.gameserver.model.actor.instance.L2PcInstance) */ public boolean useUserCommand(int id, L2PcInstance activeChar) { if (id != COMMAND_IDS[0]) return false; NpcHtmlMessage npcHtmlMessage = new NpcHtmlMessage(0); npcHtmlMessage.setHtml("<html><head><title>TvT Event</title></head><body>Your team won the event. Look in your inventory, there should be your reward.</body></html>"); activeChar.sendPacket(npcHtmlMessage); return true; } /** * * @see net.sf.l2j.gameserver.handler.IUserCommandHandler#getUserCommandList() */ public int[] getUserCommandList() { return COMMAND_IDS; } } Now we must add our script to MasterHandler.java in \data\scripts\handlers folder - Open this file : And find these lines , in first column : import handlers.usercommandhandlers.ChannelDelete; import handlers.usercommandhandlers.ChannelLeave; import handlers.usercommandhandlers.ChannelListUpdate; import handlers.usercommandhandlers.ClanPenalty; import handlers.usercommandhandlers.ClanWarsList; import handlers.usercommandhandlers.DisMount; import handlers.usercommandhandlers.Escape; import handlers.usercommandhandlers.InstanceZone; import handlers.usercommandhandlers.Loc; import handlers.usercommandhandlers.Mount; import handlers.usercommandhandlers.OlympiadStat; import handlers.usercommandhandlers.PartyInfo; import handlers.usercommandhandlers.Time; and add our : import handlers.usercommandhandlers.ServerInfo; Now find this column : private static void loadUserHandlers() { UserCommandHandler.getInstance().registerUserCommandHandler(new ClanPenalty()); UserCommandHandler.getInstance().registerUserCommandHandler(new ClanWarsList()); UserCommandHandler.getInstance().registerUserCommandHandler(new DisMount()); UserCommandHandler.getInstance().registerUserCommandHandler(new Escape()); UserCommandHandler.getInstance().registerUserCommandHandler(new InstanceZone()); UserCommandHandler.getInstance().registerUserCommandHandler(new Loc()); UserCommandHandler.getInstance().registerUserCommandHandler(new Mount()); UserCommandHandler.getInstance().registerUserCommandHandler(new PartyInfo()); UserCommandHandler.getInstance().registerUserCommandHandler(new Time()); UserCommandHandler.getInstance().registerUserCommandHandler(new OlympiadStat()); UserCommandHandler.getInstance().registerUserCommandHandler(new ChannelLeave()); UserCommandHandler.getInstance().registerUserCommandHandler(new ChannelDelete()); UserCommandHandler.getInstance().registerUserCommandHandler(new ChannelListUpdate()); UserCommandHandler.getInstance().registerUserCommandHandler(new ServerInfo()); _log.config("Loaded " + UserCommandHandler.getInstance().size() + " UserHandlers"); } And add this : UserCommandHandler.getInstance().registerUserCommandHandler(new ServerInfo()); (under : UserCommandHandler.getInstance().registerUserCommandHandler(new ChannelListUpdate()); ) Save , and restart Your server , done now type /serverinfo in game ;) Credits goes to me
-
[Developer] Looking for Web Developer-Designer
Matim replied to heopas's question in Request Server Development Help [L2J]
Lol man , stop spam , do you know what that topic mean ? THEY ARE LOOKING FOR DEVELOPER , dont need spamers. -
Here you have all files from Soul : http://www.4shared.com/dir/5400879/ed3a38e9/sharing.html And dont sey its your 4Shared , its Soul 4shared,,,
-
LINK IS DEAD , so dont tell and stop spamming with ''omg it working , mega , pro , extra , great " etc ...
-
[SHARE]GM Shop C-A Grade BY Angelic [Interlude]
Matim replied to angelic's topic in Server Development Discussion [L2J]
I hope You have right , but i heave seen same gmshop with only different icons on main html. -
[SHARE]GM Shop C-A Grade BY Angelic [Interlude]
Matim replied to angelic's topic in Server Development Discussion [L2J]
..only small changs in html and xml...Its not 100% Your work ... -
Spammers ..lol it look nice ? I dont think so Oo . Its bad .. its just my opinion..
-
You can change text and move dalay so no problem , this is only sample :) Read all posts from this thread ... its already posted ( answer ).
-
If You dont like it , dont use it . I have different NPC id's . If Your ID are already ussed You can simple change it , lol its so hard ?
-
You havent 'walker_routes' table in Your database , cheack it .
-
[Share]Aion Weapon Pack obj + dds for Lineage 2 by CrazyOne
Matim replied to Clipso's topic in Client Development Discussion
Great Share , La2base rulez . These items look very good Especially this big axe :P -
Why not ? As I said : If You have any error when you want import .sql file You should cheack .sql and nothink more .
-
Link deleted .
-
Thanx ;) Without meaning , You only must import .sql file into Your database and add paste .htm file in data/html/default folder .
-
Oh sory , my bad . Here is walker routes sql : INSERT INTO `walker_routes` (`route_id`, `npc_id`, `move_point`, `chatText`, `move_x`, `move_y`, `move_z`, `delay`, `running`) VALUES (43, 30006, 1, 'Please ! Vote for Us now !', 82718, 149312, -3471, 10, 1), (43, 30006, 2, 'Prosze ! Glosuj na nasz server !', 82713, 147899, -3471, 10, 1), (43, 30006, 3, 'Please ! Vote for Us now !', 81153, 147904, -3471, 10, 1), (43, 30006, 4, 'Prosze ! Glosuj na nasz server !', 81158, 149316, -3471, 10, 1); Link fixed with updated sql file
-
Heh , no ..
-
Hello . Now i want to share this simple 'Vote NPC' . You can ask why it is called 'Vote NPC' , I have simple answer . This NPC walking around Giran Square and he says : 'Please Vote for Us!' Ok look at the few screenshots : NPC text : NPC Html NPC trajectory : DOWNLOAD : Click Credits : Matim (me)
-
Credits goes to Soul DiskW - Download CT1 Kamael System - Download Hellbound System - Download Interlude System - Download Host Changer - Download FileEdit C4-C5 - Download FileEdit Hellbound - Download FileEdit Interlude/Kamael - Download
-
Credits ? Screens ?
-
[Request] HELP me if you know how to fix this !!!
Matim replied to dqkonabg's question in Request Server Development Help [L2J]
Firstly You should tell us , with one server pack You're using ..client ? Revision ? You've compiled Your core/dp or You're using stable rev ?
