Jump to content
  • 0

Change the maximum size value of htm.


Question

Posted

Hello guys, i've seen this question somewhere before here but i can't find it so i made a new topic.

I have a problem with the html size of Community Board, if the size of the htm file is small something like 6,7 kb Community Board will open normally but if i was trying some things and the htm file became bigger about 14kb and now my community board won't show up when i'm clicking to open it, if i change to the old htm file it will be fine.

So my question here is, anyone know how to change this value and where? So i can increase the size and put longer htm files in size?

Thanks in advance!

14 answers to this question

Recommended Posts

  • 0
Posted

on server packets i think ShowBoard.java put here source of this file.

on html message (dialog) max size 8kb because if it will be bigger then it can crash l2.

on show board maybe same?

  • 0
Posted (edited)
1 hour ago, wongerlt said:

on server packets i think ShowBoard.java put here source of this file.

on html message (dialog) max size 8kb because if it will be bigger then it can crash l2.

on show board maybe same?

Here is the ShowBoard.java

/*
 * 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.network.serverpackets;

import java.util.List;

public class ShowBoard extends L2GameServerPacket
{
	private static final String _S__6E_SHOWBOARD = "[S] 7b ShowBoard";

	private String _htmlCode;
	private String _id;
	private List<String> _arg;

	public ShowBoard(String htmlCode, String id)
	{
		_id = id;
		_htmlCode = htmlCode; // html code must not exceed 8192 bytes
	}

	public ShowBoard(List<String> arg)
	{
		_id = "1002";
		_htmlCode = null;
		_arg = arg;

	}

	private byte[] get1002()
	{
		int len = _id.getBytes().length * 2 + 2;
		for (String arg : _arg)
		{
			len += (arg.getBytes().length + 4) * 2;
		}
		byte data[] = new byte[len];
		int i = 0;
		for (int j = 0; j < _id.getBytes().length; j++, i += 2)
		{
			data[i] = _id.getBytes()[j];
			data[i + 1] = 0;
		}
		data[i++] = 8;
		data[i++] = 0;
		for (String arg : _arg)
		{
			for (int j = 0; j < arg.getBytes().length; j++, i += 2)
			{
				data[i] = arg.getBytes()[j];
				data[i + 1] = 0;
			}
			data[i++] = 0x20;
			data[i++] = 0x0;
			data[i++] = 0x8;
			data[i++] = 0x0;
		}
		return data;
	}

	@Override
	protected final void writeImpl()
	{
		writeC(0x7b);
		writeC(0x01); //c4 1 to show community 00 to hide
		writeS("bypass _bbshome"); // top
		writeS("bypass _bbsgetfav"); // favorite
		writeS("bypass _bbsloc"); // region
		writeS("bypass _bbsclan"); // clan
		writeS("bypass _bbsmemo"); // memo
		writeS("bypass _bbsmail"); // mail
		writeS("bypass _bbsfriends"); // friends
		writeS("bypass bbs_add_fav"); // add fav.
		if (!_id.equals("1002"))
		{
			// getBytes is a very costly operation, and should only be called once
			byte htmlBytes[] = null;
			if (_htmlCode != null)
				htmlBytes = _htmlCode.getBytes();
			
			byte idBytes[] = _id.getBytes();
			
			byte data[] = new byte[2 + 2 + 2 + idBytes.length * 2 + 2
				* ((_htmlCode != null) ? htmlBytes.length : 0)];
			int i = 0;
			for (int j = 0; j < idBytes.length; j++, i += 2)
			{
				data[i] = _id.getBytes()[j];
				data[i + 1] = 0;
			}
			data[i++] = 8;
			data[i++] = 0;
			if (_htmlCode != null)
			{
				for (int j = 0; j < htmlBytes.length; i += 2, j++)
				{
					data[i] = htmlBytes[j];
					data[i + 1] = 0;
				}
			}
			data[i++] = 0;
			data[i] = 0;
			//writeS(_htmlCode); // current page
			writeB(data);
		}
		else
		{
			writeB(get1002());
		}
	}

	/* (non-Javadoc)
	 * @see net.sf.l2j.gameserver.serverpackets.ServerBasePacket#getType()
	 */
	@Override
	public String getType()
	{
		return _S__6E_SHOWBOARD;
	}
}

I can't see anything related to the size, i also checked the HtmCache.java as well changed a value but still nothing

Edited by Designatix
correction
  • 0
Posted
27 minutes ago, Designatix said:

Here is the ShowBoard.java


/*
 * 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.network.serverpackets;

import java.util.List;

public class ShowBoard extends L2GameServerPacket
{
	private static final String _S__6E_SHOWBOARD = "[S] 7b ShowBoard";

	private String _htmlCode;
	private String _id;
	private List<String> _arg;

	public ShowBoard(String htmlCode, String id)
	{
		_id = id;
		_htmlCode = htmlCode; // html code must not exceed 8192 bytes
	}

	public ShowBoard(List<String> arg)
	{
		_id = "1002";
		_htmlCode = null;
		_arg = arg;

	}

	private byte[] get1002()
	{
		int len = _id.getBytes().length * 2 + 2;
		for (String arg : _arg)
		{
			len += (arg.getBytes().length + 4) * 2;
		}
		byte data[] = new byte[len];
		int i = 0;
		for (int j = 0; j < _id.getBytes().length; j++, i += 2)
		{
			data[i] = _id.getBytes()[j];
			data[i + 1] = 0;
		}
		data[i++] = 8;
		data[i++] = 0;
		for (String arg : _arg)
		{
			for (int j = 0; j < arg.getBytes().length; j++, i += 2)
			{
				data[i] = arg.getBytes()[j];
				data[i + 1] = 0;
			}
			data[i++] = 0x20;
			data[i++] = 0x0;
			data[i++] = 0x8;
			data[i++] = 0x0;
		}
		return data;
	}

	@Override
	protected final void writeImpl()
	{
		writeC(0x7b);
		writeC(0x01); //c4 1 to show community 00 to hide
		writeS("bypass _bbshome"); // top
		writeS("bypass _bbsgetfav"); // favorite
		writeS("bypass _bbsloc"); // region
		writeS("bypass _bbsclan"); // clan
		writeS("bypass _bbsmemo"); // memo
		writeS("bypass _bbsmail"); // mail
		writeS("bypass _bbsfriends"); // friends
		writeS("bypass bbs_add_fav"); // add fav.
		if (!_id.equals("1002"))
		{
			// getBytes is a very costly operation, and should only be called once
			byte htmlBytes[] = null;
			if (_htmlCode != null)
				htmlBytes = _htmlCode.getBytes();
			
			byte idBytes[] = _id.getBytes();
			
			byte data[] = new byte[2 + 2 + 2 + idBytes.length * 2 + 2
				* ((_htmlCode != null) ? htmlBytes.length : 0)];
			int i = 0;
			for (int j = 0; j < idBytes.length; j++, i += 2)
			{
				data[i] = _id.getBytes()[j];
				data[i + 1] = 0;
			}
			data[i++] = 8;
			data[i++] = 0;
			if (_htmlCode != null)
			{
				for (int j = 0; j < htmlBytes.length; i += 2, j++)
				{
					data[i] = htmlBytes[j];
					data[i + 1] = 0;
				}
			}
			data[i++] = 0;
			data[i] = 0;
			//writeS(_htmlCode); // current page
			writeB(data);
		}
		else
		{
			writeB(get1002());
		}
	}

	/* (non-Javadoc)
	 * @see net.sf.l2j.gameserver.serverpackets.ServerBasePacket#getType()
	 */
	@Override
	public String getType()
	{
		return _S__6E_SHOWBOARD;
	}
}

I can't see anything related to the size, i also checked the HtmCache.java as well changed a value but still nothing

then debug packets , and check that client get it or no. if no then try find where cheking size

  • 0
Posted
33 minutes ago, wongerlt said:

then debug packets , and check that client get it or no. if no then try find where cheking size

how i can do this? XD

  • 0
Posted
6 minutes ago, wongerlt said:

or just try optimize ur html file. example, delete all spaces, lines and etc.

put here ur html

I'm trying to put l2mythras community index to mine (i'm using gf) here is the code

<html noscrollbar>
<title>Community Board</title>
<body><br>
<table width=610>
<tr>
<center><td align=center valign=top>
<table border=0 cellpadding=0 cellspacing=0 width=769 height=492 background="L2RedemptionCB.dragon">
<tr>
<td valign="top" align="center">
<table width=610 height=468>
<tr>
<td width=610>
<table border=0 cellspacing=0 cellpadding=0 width=610>
<tr>
<td height=10></td>
</tr>
<tr>
<td width=260>
<table width=260 height=180>
<tr>
<td valign="top" align="center">
<table border=0 width=260 height=240 cellspacing=4 cellpadding=3 background="l2ui_ct1.ComboBox_DF_Dropmenu_Bg">
<tr>
<td width=220 align=left valign=top>
<table width=260 height=25 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>
<td width=228 align=center valign=center>
<font color="FF6633">Character Information</font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=000000>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Name</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="669900"><?player_name?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=333333>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Class</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?player_class?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=000000>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Level</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?player_level?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=333333>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Clan</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?player_clan?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=000000>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Nobless</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?player_noobless?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=000000>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Your IP</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?player_ip?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=333333>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Online Time</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?online_time?></font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=333333>
<tr>
<td width=90 align=right valign=center>
<font color="B59A75">Premium Account</font>
</td>
<td width=4 align=center valign=center>
:
</td>
<td width=90 align=left valign=center>
<font color="FFFFFF"><?player_premium?></font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td width=456>
<table width=456 height=180>
<tr>
<td valign="top" align="center">
<table border=0 width=456 height=240 cellspacing=4 cellpadding=3 background="l2ui_ct1.ComboBox_DF_Dropmenu_Bg">
<tr>
<td width=220 align=left valign=top>
<table width=456 height=23 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>
<td width=416 align=center valign=center>
<font name="CreditTextNormal" color="FF6633">Welcome to L2Mythras</font>
</td>
</tr>
</table>
<table width=456 height=25 bgcolor=000000>
<tr>
<td width=456 align=left valign=center>
 <font>Hello <font name="CreditTextNormal" color=669900><?player_name?></font>, and welcome to our grand new project<br1>
 <br>
Enjoy playing on our server and if you have any suggestion, visit our forum.</font>
</td>
</tr>
</table>
<table width=456 height=23 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>>
<td width=416 align=center valign=center>
<font name="CreditTextNormal" color="FF6633">Server Rates</font>
</td>
</tr>
</table>
<table width=456 height=25 bgcolor=000000>
<tr>
<td width=456 align=center valign=center>
<table align=center width=456 border=0>
<tr>
<td width=50 align=right><font color=B59A75>XP</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x55</font></td>
<td width=50 align=right><font color=B59A75>SP</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x55</font></td>
<td width=50 align=right><font color=B59A75>Adena</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x50</font></td>
</tr>
<tr>
<td width=50 align=right><font color=B59A75>Drop</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x25</font></td>
<td width=50 align=right><font color=B59A75>Spoil</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x25</font></td>
<td width=50 align=right><font color=B59A75>Quest</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x4</font></td>
</tr>
<tr>
<td width=50 align=right><font color=B59A75>Siege</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x10</font></td>
<td width=50 align=right><font color=B59A75>Manor</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x10</font></td>
<td width=50 align=right><font color=B59A75>Fish</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x10</font></td>
</tr>
<tr>
<td width=50 align=right><font color=B59A75>ClanRep</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x10</font></td>
<td width=50 align=right><font color=B59A75>Hellbound</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x10</font></td>
<td width=50 align=right><font color=B59A75>RaidBoss</font></td>
<td width=5>:</td>
<td width=50><font name="CreditTextNormal" color=FFFFFF>x5</font></td>
</tr>
</table>
</td>
</tr>
</table>
<table width=456 height=23 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>
<td width=416 align=center valign=center>
<font name="CreditTextNormal" color="FF6633">Server info</font>
</td>
</tr>
</table>
<table width=456 height=23 bgcolor=000000>
<tr>
<td align=center valign=center width=150>
<font color="B59A75" name="CreditTextNormal">Time: </font><font name="CreditTextNormal"> <?time?> </font>
</td>
<td align=center valign=center width=150>
<font color="B59A75" name="CreditTextNormal">Online Now: </font><font name="CreditTextNormal"> <?online?> </font>
</td>
<td align=center valign=center width=150>
<font color="B59A75" name="CreditTextNormal">Offtraders: </font><font name="CreditTextNormal"> <?offtrade?> </font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<table border=0 cellspacing=0 cellpadding=0 width=456>
<tr>
<td height=18></td>
</tr>
<tr>
<td width=260>
<table width=260 height=92>
<tr>
<td valign="top" align="center">
<table border=0 width=260 height=92 cellspacing=4 cellpadding=3 background="l2ui_ct1.ComboBox_DF_Dropmenu_Bg">
<tr>
<td width=220 align=left valign=top>
<table width=260 height=23 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>
<td width=228 align=center valign=center>
<font color="FF6633">Social Information</font>
</td>
</tr>
</table>
<table width=260 height=25 bgcolor=000000>
<tr>
<td width=260 height=55 align=center valign=center>
<table width=260 height=25>
<tr>
<td width=53 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skillraid">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="url !2265" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Facebook
</td>
<td width=53 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skillraid">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="url !2266" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Website
</td>
<td width=53 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skillraid">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="url !2267" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Forum
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td width=456>
<table width=456 height=92>
<tr>
<td valign="top" align="center">
<table border=0 width=455 height=92 cellspacing=4 cellpadding=3 background="l2ui_ct1.ComboBox_DF_Dropmenu_Bg">
<tr>
<td width=220 align=left valign=top>
<table width=455 height=23 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>
<td width=416 align=center valign=center>
<font color="FF6633">Questions</font>
</td>
</tr>
</table>
<table width=454 height=25 bgcolor=000000>
<tr>
<td width=455 align=left valign=center>
Do you have any questions? Use the buttons to check information about server rates, configuration, raids & instances, 
donations and more.<br1>
If you still confused, please, go to our forums: <font color=LEVEL>www.L2Mythras.Eu/forum</font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<table border=0 cellspacing=0 cellpadding=0 width=736>
<tr>
<td height=18></td>
</tr>
<tr>
<td width=736>
<table width=736 height=60>
<tr>
<td valign="top" align="center">
<table border=0 width=745 height=98 cellspacing=4 cellpadding=3 background="l2ui_ct1.ComboBox_DF_Dropmenu_Bg">
<tr>
<td width=736 align=center valign=center>
<table width=740 height=23 background="l2ui_ct1.Windows_DF_Drawer_Bg">
<tr>
<td width=704 align=center valign=center>
<font color="FF6633">Navigation</font>
</td>
</tr>
</table>
<table width=755 height=60 bgcolor=000000>
<tr>
<td width=110 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skill5243">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="bypass _bbspage:Serverinfo" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Server Info
</td>
<td width=110 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skill5861">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="bypass _bbspage:RB" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
RaidBoss
</td>
<td width=110 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="branchsys2.br_vitality_day_i00">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="bypass -h scripts_services.Premium:see" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Premium Account
</td>
<td width=110 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skill1526">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="bypass _bbspage:Command" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Commands
</td>
<td width=110 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skill5762">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="bypass _bbspage:Donate/donate" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
Donation Store
</td>
<td width=110 align=center valign=top>
<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="Icon.skill5739">
<tr>
<td width=32 height=32 align=center valign=top>
<button action="bypass _bbspage:HowToDonate" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
</td>
</tr>
</table>
How to Donate
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<table border=0 cellspacing=0 cellpadding=0 width=755>
<tr>
<td height=18></td>
</tr>
<tr>
<td width=755>
<table width=755 height=20>
<tr>
<td valign="top" align="center">
<table border=0 width=755 height=20 cellspacing=4 cellpadding=3 background="l2ui_ct1.ComboBox_DF_Dropmenu_Bg">
<tr>
<td width=755 align=left valign=top>
<table width=745 height=25 bgcolor=0e0d0d>
<tr>
<td width=736 align=center valign=center>
<font color="LEVEL">Server Last Restarted at:</font> <?server_uptime?>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td></center>
</tr>
</table>
</body></html>

 

  • 0
Posted

beside crap quality of your quoted source (where you could find way better in few sec just by googling), you can see even reason of your problem right in your quote:

_htmlCode = htmlCode; // html code must not exceed 8192 bytes

L2 client assemble html string from exactly 3 showBoard packets before rendering whole window update in game,
so all you have to do with your crap source, is to chunk your string to 8kb parts and pass them to ShowBoard with IDs: 101,102,103

Im entirety amused how clueless you look to be, and yet bother with some altB htmls. Should we expect new 100% retail like server in upcoming week? :D

  • 0
Posted (edited)
public static void separateAndSend(final String html, final L2PcInstance acha)
	{
		if (html == null)
			return;
		
		if (html.length() < 4090)
		{
			acha.sendPacket(new ShowBoard(html, "101"));
			acha.sendPacket(new ShowBoard(null, "102"));
			acha.sendPacket(new ShowBoard(null, "103"));
			
		}
		else if (html.length() < 8180)
		{
			acha.sendPacket(new ShowBoard(html.substring(0, 4090), "101"));
			acha.sendPacket(new ShowBoard(html.substring(4090, html.length()), "102"));
			acha.sendPacket(new ShowBoard(null, "103"));
			
		}
		else if (html.length() < 12270)
		{
			acha.sendPacket(new ShowBoard(html.substring(0, 4090), "101"));
			acha.sendPacket(new ShowBoard(html.substring(4090, 8180), "102"));
			acha.sendPacket(new ShowBoard(html.substring(8180, html.length()), "103"));
			
		}
	}

so max 12270 bytes on c6(maybe it just mistake in source), and on h5 i see 24540 bytes max.

Edited by wongerlt
  • 0
Posted
13 hours ago, AlmostGood said:

beside crap quality of your quoted source (where you could find way better in few sec just by googling), you can see even reason of your problem right in your quote:


_htmlCode = htmlCode; // html code must not exceed 8192 bytes

L2 client assemble html string from exactly 3 showBoard packets before rendering whole window update in game,
so all you have to do with your crap source, is to chunk your string to 8kb parts and pass them to ShowBoard with IDs: 101,102,103

Im entirety amused how clueless you look to be, and yet bother with some altB htmls. Should we expect new 100% retail like server in upcoming week? :D

lel i'm so blind ;p

about the source and my server it's not a project about to go live, it's a project i'm trying to build in order to learn more and more about development and trying to make my own codes/ideas so yes i'm clueless but i'm trying to learn :) Also it's l2j gracia final source so as you already know it's outdated as hell but it's a client i like and since it's crap it's better for me to make tests and trying to learn ;p

And btw thanks for your reply

12 hours ago, wongerlt said:

public static void separateAndSend(final String html, final L2PcInstance acha)
	{
		if (html == null)
			return;
		
		if (html.length() < 4090)
		{
			acha.sendPacket(new ShowBoard(html, "101"));
			acha.sendPacket(new ShowBoard(null, "102"));
			acha.sendPacket(new ShowBoard(null, "103"));
			
		}
		else if (html.length() < 8180)
		{
			acha.sendPacket(new ShowBoard(html.substring(0, 4090), "101"));
			acha.sendPacket(new ShowBoard(html.substring(4090, html.length()), "102"));
			acha.sendPacket(new ShowBoard(null, "103"));
			
		}
		else if (html.length() < 12270)
		{
			acha.sendPacket(new ShowBoard(html.substring(0, 4090), "101"));
			acha.sendPacket(new ShowBoard(html.substring(4090, 8180), "102"));
			acha.sendPacket(new ShowBoard(html.substring(8180, html.length()), "103"));
			
		}
	}

so max 12270 bytes on c6(maybe it just mistake in source), and on h5 i see 24540 bytes max.

Yeah i've check this on some h5 sources i got and there was a part like this one, but i didn't try to implent it on my source. I'm gonna check it thanks

  • 0
Posted (edited)

Limits are defined by the client, on IL it's way shorter than postIL clients, but it's still limited. Nothing you can do about.

Consider to review it.

Edited by Tryskell
  • 0
Posted
14 hours ago, Tryskell said:

Limits are defined by the client, on IL it's way shorter than postIL clients, but it's still limited. Nothing you can do about.

Consider to review it.

Yes i think about that because every thing i tried by server side trying to increase the site didn't worked at all, so i guess it's controlled by client side.

 

13 hours ago, tazerman2 said:

maybe you can make better that code like small with 1-2 less table maybe i can do if you want help

Yeah if you could help me on this would be just perfect :)

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

    • Very nice and passionate effort. Good luck.
    • SX.ORG is a global proxy platform offering residential, mobile and datacenter IPs for SEO, web scraping, ad verification and multi-account management. It provides flexible IP rotation, precise geo-targeting, HTTP(S)/SOCKS5 support, API access and pay-as-you-go pricing based only on the traffic you use.
    • L2-IMBA — SEASON 2  Custom PvP / PvE Interlude · Every Class Playable BETA — LIVE NOW GRAND START — 11 September 2026, 20:00 GMT+2 https://l2-imba.com · https://discord.com/invite/jmhVpj8ySv ═══════════════════════════════════════ RATES & CORE SETTINGS ═══════════════════════════════════════ Chronicle — Interlude XP / SP — x45, level-adjusted curve Adena — x1 Max level — 90 Subclass — 1, to level 80 Starting hub — Giran Skills — Auto-learn, post-80 via custom trainers Loot — Auto-loot with low-value filtering Buffs — Extended duration, expanded slots, saved schemes Client limit — NO DUAL-BOXING, one client per player Automation — Built-in auto-farm with daily time limit Offline — Trading and crafting enabled Current beta configuration. Final values confirmed at launch sign-off. ═══════════════════════════════════════ All 31 third classes are developed to level 90 through five specialized trainers — there are no dead classes here. Tanks, daggers, archers, warriors, summoners, healers, buffers and crafters all have real post-80 progression and a role worth playing. Full PvE progression through ten farm zones, thirty-five themed encounters and eighteen tracked raids, feeding into gear-equalized Team vs Team and open-world PvP. This isn't a stat patch with a new name. L2-IMBA keeps the combat, classes and world of Interlude and builds a new endgame on top of it — new equipment branches, custom class development past level 80, purpose-built farm ecosystems, boss progression, crafting, and augmentation, all connected into one progression loop. Level and develop your class → choose an armor identity → clear themed farm content → collect materials and boss resources → craft and upgrade without abandoning your build → compete in equalized and open-world PvP → reach God's equipment. ═══════════════════════════════════════ ROLE MASTERY ARMOR ═══════════════════════════════════════ Starting at Dynasty, armor becomes a real build choice instead of a mandatory set everyone wears. Each armor type offers three role masteries plus a flexible Universal path — twelve paths per tier, sixty full-set configurations across the progression. The chest piece selects your mastery; a matching five-piece set activates it. HEAVY   Juggernaut — frontline wall, shield synergy, reflection   Spellbreaker — anti-magic fortress, spell disruption   Slayer — heavy armor turned offensive, vampiric sustain LIGHT   Bowmaster — ranged pressure, kiting, accuracy   Assassin — positional burst, blow reliability, dagger lethals   Berserker — high-risk carry, power rises as HP falls ROBE   Arcanist — rapid-fire critical casting   Invoker — high-impact nuking and debuffs   Oracle — dedicated healing and support Upgrade recipes preserve your chosen path through every tier: Dynasty → Zariche → Valakas → Cursed → God's The system is gear-driven, not class-locked. Build creatively. ═══════════════════════════════════════ LEVEL 90 CLASS DEVELOPMENT ═══════════════════════════════════════ Max level extended to 90. Five specialized trainers — Archer, Tank, Rogue, Warrior, Mystic — cover all 31 third classes in post-80 progression, with 470+ learning entries. Every race gets a custom passive from level one. Tanks get distinct Human/Elf/Dark Elf identities. Duelist gains a two-handed greatsword path. Fortune Seeker becomes a real fighter without losing its spoil identity. Maestro gets a durable frontline route. Summoners, cubics and servitors get deeper combat logic rather than stat scaling. This is backed by server-side combat work — dedicated handling for debuff proficiency, PvE skill damage, blows, lethals, bow reuse, vampirism and reflection. ═══════════════════════════════════════ THE FARMING WORLD ═══════════════════════════════════════ Ten dedicated farm destinations via Global Gatekeeper: Farm Coins 1 & 2, Holy, Fire/Water, Wind, Earth, Unholy, Golden, Chaotic and Night zones. Seven themed enemy families — Undead, Demon, Angel, Beast, Bug, Water, Fire — each with four stages and a mini-boss. Thirty-five distinct encounters, each with its own resource identity feeding crafting. Eighteen tracked raids — twelve Farm Raid Bosses and six Custom Epic Raid Bosses. Plus a scheduled group-based Party Zone with dynamically managed normal and rare spawns. ═══════════════════════════════════════ CRAFTING & ENDGAME ═══════════════════════════════════════ SOUL FORGE — recycle old weapons into tier resources, convert boss and farm materials, craft Legendary components. Old gear becomes input, not warehouse clutter. CURATED AUGMENTATION — data-driven Top-Grade and Legendary profiles with meaningful stat, active and passive pools. Active effects are categorized so the same effect can't be stacked through equipment swapping. EXTENDED ENCHANT — Custom Crystal and Legendary stages. On the Legendary route, a failed enchant does not destroy the item or reduce its enchant level. Long-term progression, not an all-or-nothing gamble. TREASURE CHESTS — Rare, Immortal, Epic and Legendary tiers feeding gear growth, crafting and augmentation. ═══════════════════════════════════════ PvP ═══════════════════════════════════════ Gear-equalized Team vs Team on a recurring schedule — your equipment is snapshotted and restored, so the fight is about play, not who farmed longest. Open-world PvP with rewards and ranks alongside it. ═══════════════════════════════════════ QUALITY OF LIFE ═══════════════════════════════════════ - No dual-boxing — one client per player, enforced - Built-in auto-farm with a daily time limit — no third-party software needed, and third-party automation is bannable - Auto-learn skills, auto-loot with low-value drop filtering - Extended-duration buffs, expanded slots, saved schemes - Offline trading and crafting - Global Gatekeeper, global class change - Offline combat automation disabled ═══════════════════════════════════════ BY THE NUMBERS ═══════════════════════════════════════ 380+ custom item definitions · 110+ weapons and shields · 210+ armor and wearables · 250+ custom skill definitions · 2,700+ custom monster placements · 90+ shop and exchange catalogs · 1,100+ offers ═══════════════════════════════════════ BETA ═══════════════════════════════════════ Core systems, progression identities and content routes are in place. Exact item bonuses, mastery values, skill strength, reuse times, augment pools, enchant chances, drop rates and crafting costs remain subject to testing. Beta changes will refine balance without removing the defining role of each mastery or the overall progression structure. All beta characters are wiped at full launch. Beta testers keep their rewards. ═══════════════════════════════════════ OPEN BETA — 4 SEPTEMBER 2026 · 18:00 GMT+2 Website: https://l2-imba.com Wiki: https://l2-imba.com/wiki Register: https://l2-imba.com/account Download: https://l2-imba.com/start-playing Discord:  https://discord.com/invite/jmhVpj8ySv
    • 🛡️ 100% Safe on your personal Gmail. Zero VPN required and works globally. Grab yours directly on klouditem.com! 🚀 Daily Restock Complete! All 12–18 Month Gemini Pro activations are active with instant setup.
  • 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..