[Point Blank] UDP3 Send-back packet - Форум администраторов игровых серверов
Форум администраторов игровых серверов StormWall - Защита от DDos атак
Регистрация Мнения Справка Сообщество Календарь
Вернуться   Форум администраторов игровых серверов > MMO > Point Blank (Piercing Blow)

Point Blank (Piercing Blow)
Общие вопросы по написанию эмулятора. General questions on developing emulator. При поддержке: Lucera 2 - разработка Java Interlude

Ответ
Опции темы
Непрочитано 28.06.2018, 17:20   #1
Пользователь

Автор темы (Топик Стартер) UDP3 Send-back packet

Hi,
i'm working on packet 4 (answer to packet 3).

I've make it working just "copying" all the content between the Header and the Footer of the packet (And this work in a part, I see player move and so on)

Then, I've start to write the content between the Header and the Footer of the packet with the PosRotation event but that's not working. I've get the sending data, and i've see a problem
Код:
ae 4f b2 44 6f be 9e 50 0e 49 10 00 //This is PosRotation wrong      
0a e4 fb 24 46 fb e9 e5 00 e4 91 00 //This is PosRotation correct

If you check them, you can the that the wrong one is all moved of one, I've colored 2 by 2 for make it more clearly
This is the no-working code
Код:
byte subHead = read.readByte();
int subHead_Slot = read.readShort();
int subHead_Length = read.readShort();
int subHead_Flag = read.readInt();

if ((subHead_Flag & 0x01) > 0) //..
if ((subHead_Flag & 0x02) > 0) //..
if ((subHead_Flag & 0x04) > 0)
{
        posX = read.readUnsignedShort();
	posY = read.readUnsignedShort();
	posZ = read.readUnsignedShort();
	camX = read.readUnsignedShort();
	camY = read.readUnsignedShort();
	area = read.readUnsignedShort();
	event.event += 0x04;
	pSize += 12;
}

event.data.buffer.writeHeader();
event.data.buffer.writeByte(subHead);
event.data.buffer.writeByte(subHead_Slot);
event.data.buffer.writeByte(pSize);
if((event.event & 0x04) > 0){
        //This part is the HEX buffer showed up
	event.data.buffer.writeShort(posX);
	event.data.buffer.writeShort(posY);
	event.data.buffer.writeShort(posZ);
	event.data.buffer.writeShort(camX);
	event.data.buffer.writeShort(camY);
	event.data.buffer.writeShort(area);
}
This is the working code
Код:
//.. header
Data = new byte[Length - 13];
Receive.readBytes(Data);
Reader = Unpooled.copiedBuffer(Data).order(ByteOrder.LITTLE_ENDIAN);
BitShift.onlyDecrypt(Reader, Length);

send.buffer.writeBytes(Packet.Data.clone());

Последний раз редактировалось ManuelDev; 28.06.2018 в 22:24. Причина: No need anymore
ManuelDev вне форума Ответить с цитированием
Непрочитано 28.06.2018, 22:24   #2
Пользователь

Автор темы (Топик Стартер) Re: UDP3 Send-back packet

Problem solved
ManuelDev вне форума Ответить с цитированием
Непрочитано 29.06.2018, 11:33   #3
Пользователь

По умолчанию Re: UDP3 Send-back packet

Цитата:
Сообщение от ManuelDev Посмотреть сообщение
Problem solved
help me
how to fix ?

Добавлено через 19 минут
@PROGRAMMATOR help me please

Последний раз редактировалось bmzproject; 29.06.2018 в 11:52. Причина: Добавлено сообщение
bmzproject вне форума Ответить с цитированием
Непрочитано 29.06.2018, 12:18   #4
Пользователь

Автор темы (Топик Стартер) Re: UDP3 Send-back packet

Цитата:
Сообщение от bmzproject Посмотреть сообщение
help me
how to fix ?

Добавлено через 19 минут
@PROGRAMMATOR help me please
I'm not sure, but I think it was a shift problem
ManuelDev вне форума Ответить с цитированием
Ответ


Здесь присутствуют: 1 (пользователей: 0 , гостей: 1)
 

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.

Быстрый переход

Похожие темы
Тема Автор Раздел Ответов Последнее сообщение
[Point Blank] Help me UDP3 Before send packet to player bmzproject Point Blank (Piercing Blow) 0 14.05.2018 14:26
[Point Blank] Help me please UDP3 Event receive and send I'm wrong bmzproject Point Blank (Piercing Blow) 2 01.05.2018 01:11
[Point Blank] Help me please UDP3 send to Client bmzproject Point Blank (Piercing Blow) 4 18.03.2018 23:06
Аукцион Send Log rreanimatorr Серверная часть 2 04.07.2011 16:53
Ошибка Send Log при смене класса Bigboxer Серверная часть 4 21.06.2011 17:03


© 2007–2024 «Форум администраторов игровых серверов»
Защита сайта от DDoS атак — StormWall
Работает на Булке неизвестной версии с переводом от zCarot
Текущее время: 14:01. Часовой пояс GMT +3.

Вверх