Jump to content
  • 0

Chatrang/allclassrace/onlinecommunity


Question

Posted (edited)

Hello everybody,

 

My name is MagicOz and I'm a new novice Admin.

 

In first, i'm sorry because my english is bad :/

 

 

1/ I would need your help for changed my channel trade rang (regionnal => world).

 

2/ Allow quite the races to acquire quite the classes in first class.

 

3/ Include the character online list in the page region in the community.

 

 

I use L2J High Five latest version !

 

One thank you early!

Edited by MagicOz

9 answers to this question

Recommended Posts

  • 0
Posted (edited)

1) chathandlers/ChatTrade.java

There will be something like that:  && region == MapRegionTable.getMapRegion(player.getX(), player.getY())

Delete it. (you should delete final int region = MapRegionTable.getMapRegion(activeChar.getX(), activeChar.getY()); too since it's not used after you delete the first line)

 

2) I didn't understand, do you want players to change directly to the 3rd class or?

 

3) communitybbs/Manager/RegionBBSManager.java (note that this is aCis, i don't know what project/pack you are using)

Go to method showRegion() and add below all the content = content.replace this:

content = content.replace("%onlineplayers%", ""+L2World.getInstance().getPlayers().size());

 

Then go to your region html (should be data/html/CommunityBoard/region/castle.htm) and add where you want: Online players: %onlineplayers%

 

Edit: I just noticed you use l2j high five, however i can't be arsed changing paths etc, figure it out it's easy.

Edited by An4rchy
  • 0
Posted (edited)

1) I deleted well the line:

 

- if ((region == MapRegionManager.getInstance().getMapRegionLocId(player)) && !BlockList.isBlocked(player, activeChar) && (player.getInstanceId() == activeChar.getInstanceId()))

- int region = MapRegionManager.getInstance().getMapRegionLocId(activeChar);

- import com.l2jserver.gameserver.instancemanager.MapRegionManager;

 

And that works perfectly!

 

One thank you An4rchy !!! I note lines for those who have the same source as me.

 

2) I shall like that quite races have access to quite the classes of the game  dice their creation. That I may changed the first one classes without changed the appearance of races.

Ex : Elf => Dark Avenger, Human => Spellhowler, Kamael => Grand Khavatari, etc...

 

3) Here are my codes for the community region

 

Link : game\data\scripts\handlers\communityboard\regionboard.java

 

 

 

*
* Copyright © 2004-2016 L2J DataPack
*
* This file is part of L2J DataPack.
*
* L2J DataPack 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.
*
* L2J DataPack 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 .
*/
package handlers.communityboard;

import java.util.List;

import com.l2jserver.gameserver.cache.HtmCache;
import com.l2jserver.gameserver.data.sql.impl.ClanTable;
import com.l2jserver.gameserver.handler.CommunityBoardHandler;
import com.l2jserver.gameserver.handler.IWriteBoardHandler;
import com.l2jserver.gameserver.instancemanager.CastleManager;
import com.l2jserver.gameserver.model.L2Clan;
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
import com.l2jserver.gameserver.model.entity.Castle;
import com.l2jserver.gameserver.util.Util;

/**
* Region board.
* @author Zoey76
*/
public class RegionBoard implements IWriteBoardHandler
{
// Region data
// @formatter:off
private static final int[] REGIONS = { 1049, 1052, 1053, 1057, 1060, 1059, 1248, 1247, 1056 };
// @formatter:on
private static final String[] COMMANDS =
{
"_bbsloc"
};

@Override
public String[] getCommunityBoardCommands()
{
return COMMANDS;
}

@Override
public boolean parseCommunityBoardCommand(String command, L2PcInstance activeChar)
{
if (command.equals("_bbsloc"))
{
CommunityBoardHandler.getInstance().addBypass(activeChar, "Region", command);

final String list = HtmCache.getInstance().getHtm(activeChar.getHtmlPrefix(), "data/html/CommunityBoard/region_list.html");
final StringBuilder sb = new StringBuilder();
final List castles = CastleManager.getInstance().getCastles();
for (int i = 0; i < REGIONS.length; i++)
{
final Castle castle = castles.get(i);
final L2Clan clan = ClanTable.getInstance().getClan(castle.getOwnerId());
String link = list.replaceAll("%region_id%", String.valueOf(i));
link = link.replace("%region_name%", String.valueOf(REGIONS));
link = link.replace("%region_owning_clan%", (clan != null ? clan.getName() : "NPC"));
link = link.replace("%region_owning_clan_alliance%", ((clan != null) && (clan.getAllyName() != null) ? clan.getAllyName() : ""));
link = link.replace("%region_tax_rate%", String.valueOf(castle.getTaxRate() * 100) + "%");
sb.append(link);
}

String html = HtmCache.getInstance().getHtm(activeChar.getHtmlPrefix(), "data/html/CommunityBoard/region.html");
html = html.replace("%region_list%", sb.toString());
CommunityBoardHandler.separateAndSend(html, activeChar);
}
else if (command.startsWith("_bbsloc;"))
{
CommunityBoardHandler.getInstance().addBypass(activeChar, "Region>", command);

final String id = command.replace("_bbsloc;", "");
if (!Util.isDigit(id))
{
LOG.warning(RegionBoard.class.getSimpleName() + ": Player " + activeChar + " sent and invalid region bypass " + command + "!");
return false;
}

// TODO: Implement.
}
return true;
}

@Override
public boolean writeCommunityBoardCommand(L2PcInstance activeChar, String arg1, String arg2, String arg3, String arg4, String arg5)
{
// TODO: Implement.
return false;
}
}

 

 

Link : game\data\html\communityboard\region.html

<html>
	<body>
		<br>
		<br>
		<table border="0" width="755">
			<tr>
				<td width="10">
				</td>
				<td width="600" align="left">
					<a action="bypass _bbsloc">&$381;</a> > <a action="bypass _bbshome">Local Community</a> > <a action="bypass _bbshome">Local Information</a>
				</td>
			</tr>
		</table>
		<center>
			<img src="L2UI.squareblank" width="1" height="10"><br>
			<table border="0" cellspacing="0" cellpadding="2" width="755" bgcolor="A7A19A">
				<tr>
					<td width="100" align="right">
						&$1790;
					</td>
					<td width="300" align="center">
						&$382;
					</td>
					<td width="240" align="center">
						&$590;
					</td>
					<td width="115" align="center">
						&$1608;
					</td>
				</tr>
			</table>
			<br>
			%region_list%
			<br>
		</center>
	</body>
</html>

What line do I owe changed?

 

Again, thank you early.

Edited by MagicOz
  • 0
Posted

Define better what is "quite" because there is no meaning in english in the way you use it. Do you mean "all" ?

 

You have to rework entirely class system if that's the case, cause atm classes are bound by race, and it's defined by the structure itself of the datafile.

  • 0
Posted

OK.

I think that it is too much complicated for my skills.

I thought about an alternative solution.

But for it, it is necessary to me to know if it is possible.

 

Instead of re-coding all the classes and the races, I would want to make so that all subclass then to acquire certifs in main class player and so that they can entry to Olympiad.

And what all the class can be acquired there subclass.

 

Do you think that it is possible?

 

Thank you in advance :-[

  • 0
Posted (edited)

OK.

I think that it is too much complicated for my skills.

I thought about an alternative solution.

But for it, it is necessary to me to know if it is possible.

 

Instead of re-coding all the classes and the races, I would want to make so that all subclass then to acquire certifs in main class player and so that they can entry to Olympiad.

And what all the class can be acquired there subclass.

 

Do you think that it is possible?

 

Thank you in advance :-[

 

Even if it's possible, subclasses are limited to lvl 75, so people using main class will get a huge advantage.

 

And I doubt it will work, you need to rework Olympiads system to handle class differently (drop subclass check to allow subclassed ppl to register, register the player on this class, and how about heroes ? You will base heroes on subclassed too ? What happen if one dude register and gains points on all his subclasses ? Which to use to calculate hero ?).

Edited by Tryskell
  • 0
Posted

Even if it's possible, subclasses are limited to lvl 75, so people using main class will get a huge advantage.

 

On my server subclass is lvl 85. Thank for option in L2J ;)

 

And I doubt it will work, you need to rework Olympiads system to handle class differently (drop subclass check to allow subclassed ppl to register, register the player on this class, and how about heroes ? You will base heroes on subclassed too ? What happen if one dude register and gains points on all his subclasses ? Which to use to calculate hero ?).

 

 

For the heroes, I shall like that the winning class takes gains points and status of heroin but that it is not shared on all the classes of one character.

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

    • Luniage - a custom Interlude client on Unity, with its own server Hi everyone. I've been quietly working on this for a long time and I think it's finally at the point where it's worth showing. Short version: it's Interlude, but the client and the server are both mine. The client is a custom one, built in Unity — not a patched or reskinned original. The server is written from scratch in C#. The only thing that comes from the old game is the content: the world, the models, the animations, the sounds, the icons, the interface art. The game looks and feels like the game you know. Everything underneath it is new. Why do this at all   Because the old client is a 2004 executable and anyone who has ever tried to add something to it knows exactly how that conversation ends. You can't add a window. You can't change how a skill looks. You can't fix a bug that's staring you in the face. Every server that wanted a feature of its own had to fake it through HTML dialogs and system messages, because the client simply won't bend. At some point it stops being worth fighting. I'd rather keep the game and rebuild everything around it. Where it is right now   You can sit down and play it. Not a tech demo, not a walk-around-and-look-at-the-trees build - an actual character. Most of the game is in: movement, combat, the skill system with its real formulas and timings, items and equipment, enchanting, shops and player trade, quests, parties, clans, and the whole interface that ties it together. Progression works from level 1 all the way through A grade - you can level, gear up, join a clan and run content today. What's missing isn't the foundation. It's the top end - and that's exactly where the work is pointed next.   Videos     What I'm working on now   Castle sieges and the Olympiad. The two biggest systems the game has, the ones that turn a working world into a server people actually stay on. And visual effects. They already run, but "runs" and "looks the way you remember it" are two very different things, and closing that gap turned out to be a much longer road than I expected. I'm going through them one by one. Does it run outside Windows   Yes. It's a Unity project, so Windows, Mac and Linux are just build targets. I actually develop on a Mac, which has kept the whole thing honest about staying portable. Will it work with my existing server   No, and it never will. The client talks to my server and nothing else - that's the trade I made, and it's the reason everything above is possible in the first place. If you're looking for a drop-in replacement client for a setup you already have, this isn't it. What's the goal   First and foremost, to launch my own project on it. That's what the client and the server are being built for, and that's what sets the priorities. Longer term, I'd like to open-source it. This community has spent twenty years working around a client nobody can touch, and I think the honest ending to this story is handing over something people can actually build on. I'm not putting a date on that - first it has to be good enough to be worth someone else's time. Can I try it   Not yet. When there's a build worth handing out, it gets posted here first. In the meantime I'll be posting progress regularly, and I read every reply. If you've run a server, built a client, or just spent a decade staring at this game and know exactly which detail everyone gets wrong — please say so. A good share of what's right in this project is right because somebody pointed at a screenshot and said "that's not how it looked." Thanks for reading.  
  • 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..