Everything posted by Elfo
-
L2jRest - An L2j Rest API
So I was bored again... L2jRest is a RESTful API for L2j It is created for latest aCis but you should be able to adapt it is you wanna use it for other projects. L2jRest is an open source project licensed under MIT. You can find the source here: https://github.com/Elfocrash/L2jRest Why use it? You can use the data of your server in your website You can create an account control panel with it You can expose data to your community to allow them to make third party apps Technical stuff It is written in Kotlin. It is using the Ktor framework. Ktor is using coroutines to achieve asynchronous request handling. It is very efficient and very fast. It is using Netty as the underlying server. It is written in a CQRS manner with query handlers for get endpoints and command handlers for post, put, patch, delete etc. It is using Koin as the IoC framework. How to setup Download and install Intellij IDEA Git clone the project and open it with Intellij Run the build Gradle task. It is configured to create a fat jar with all the dependencies included Paste the jar in your project, add it in your classpath and add the following line at the bottom of your Gameserver.java: L2jRestApi.INSTANCE.start(); Running the gameserver will also run the api. It is running under port 6969 How to extend it All you need to do if you wanna add more endpoints is to add a new handler and then add the Get, Post etc annotation depending on what endpoint you want this to be. Current endpoints: http://localhost:6969/api/players http://localhost:6969/api/players/{id} A couple of endpoint examples Endpoints: http://localhost:6969/api/players Response: { players: [ { "id": 268480927, "name": "Test", "level": 1, "isOnline": false, "pvpKills": 0, "pkKills": 0, "isNobless": false }, { "id": 268480924, "name": "Test2", "level": 1, "isOnline": true, "pvpKills": 0, "pkKills": 0, "isNobless": false } ] } Endpoint: http://localhost:6969/api/players/268480927 Response: { "id": 268480927, "name": "Test", "level": 1, "isOnline": false, "pvpKills": 0, "pkKills": 0, "isNobless": false } Currently it just supports two endpoints and no authentication. I am planning to add more endpoints and ApiKey based auth tomorrow. If you can't be arsed to build the project yourself but you wanna take a look anyway you can download the jar here
-
L2JFrozen 1.5
That’s what you call proof? I guess you don’t do programming for a living. The single request response times with a single db query for microframeworks and full web frameworks with a combination of different databases such as postgres and MySQL with no proof that a cp is configured to be used is what you call proof? On top of that the Spring framework in this example is configured to work with Postgres not MySQL and there is no clarity on which cp is used or how it’s configured. ALSO you can see that the leading Microframeworks have better performance because: 1. They are not using an ORM and they are executing their DB queries raw so OFC they will have optimal performance 2. They have the 1/1000 of the codebase that Spring has and they can do a very limited amount of things. i also find it very funny that you choose to know single query (which doesn’t even make sense for the CP) and not multiple because in multiple is the top most performing full web framework. Seriously i am wasting my time with this joker. I would be ashamed if I were you.
- L2JFrozen 1.5
- L2JFrozen 1.5
- L2JFrozen 1.5
- L2JFrozen 1.5
- Pin Code Elfocrash
-
L2JEnterprise Private
I thought compiled packs are not allowed to be shared.
-
Developer needed
It's always been that way.
-
Official Spam Topic ☂
Προφανώς ειναι bot, σιγά μην ήταν ο ίδιος τόσο active.
-
Official Spam Topic ☂
"είναι φόρουμ τεχνολογίας" Χαζέψατε όλοι μου φαίνεται.
-
Official Spam Topic ☂
Ααα ναι γιατι το όνειρο μου είναι να διαβάζω τα νέα μου για την τεχνολογία απο το Maxcheaters - The best cheating forum
-
Official Spam Topic ☂
O Maxtoras με αυτες τι μαλακιες που ποστάρει δείχνει πόσο λίγο ξέρει το κοινο του
-
About Twitch / Streaming reward system / command
Something like that?
-
G2A Integration
a
-
Most stable Interlude pack
a
-
Most stable Interlude pack
a
-
FEATURE - Droplist Dashboard (Shift + Click)
I always felt like things like this have more of a place in the CommunityBoard, instead of the NpcHtml. You have more space and to add more things. Also previous/next pagination can get hectic without numbered pagination so I would add that. In terms of the code the following can be optimized: npc.getDropData().forEach(c -> list.add(c)); Collections.reverse(list); You can iterate over the getDropData() enumerable in a reverse fashion in order to prevent the reverse call. You just add the objects in reverse before hand. You can move "final int ITEMS_PER_LIST = 7;" outside of the static method to prevent the allocation to the object every time the method is called. You should chain sb.append within your sb.append calls. Strings are immutable so you're allocating more memory for no reason. You can change this: if (_ignored.contains(itemId)) _ignored.remove(itemId); else _ignored.add(itemId); To this: var existed = _ignored.remove(itemId); if(!existed) _ignored.add(itemId); You also should rename the public methods "ignoredDropContain" and "ignored" in Player.java. They are really bad names and they don't imply what they do. They also don't belong in the Player class. There are other small things as well but too nit picky to mention.
-
Most stable Interlude pack
a
-
Most stable Interlude pack
a
-
[L2J] Order vs. Chaos
Pretty much every server has fake players nowadays and I have a fair share of blame to take on that. However, do you want pvp with healers even though they are bots or without healers? I would personally go with the first but you have the danger of not having action at all which leads to players leaving. There is an argument to be made on both sides.
-
L2 Html Integrator
As the title suggests I am looking for someone that can take a PSD and create the appropriate L2-flavored HTML for that image. This is interlude specific. Send me pms with examples of your work and I will choose the best one.
-
L2 on Mac OS
Yeah it's possible. I use Wine to run it and it works like a charm. https://www.winehq.org/
-
[L2J] L2Elixir
Ο Μήτσος για μισό κιλό φέτα και 4 ελιές πουλάει και την μάνα του.
-
Most stable Interlude pack
a