Adding new map to client.

Joined
Mar 13, 2008
Messages
760
Reaction score
1,021
I am working for add a new map on main 1.04j s3ep1 maybe a lot people know it but i dont know nothing about it XD.

Here some offset for main 1.04j

00639A33 3B55 98 CMP EDX,DWORD PTR SS:[EBP-4]


Need be changed to

00639A33 3B55 98 CMP EDX,DWORD PTR SS:[EBP-68]

same in address:

00639C26 and 00639CC9 (CHANGE EBP-4 to EBP-68)


And now the client can read all maps new... but have a problem not read objects in searching how i can load objects in maps..

and for can enter to new map need be fix the gameserver

here a image

Pinkof - Adding new map to client. - RaGEZONE Forums






if someone want help me add me to skype

pinkof_4
 
at least in version 1.02c addition to the changes in gameserver I just changed the main to read the map name and the interface name that appears so when will the map

Here is the code that reads into main 1.02c

sorry my english is bad

Code:
#include "stdafx.h"

int    map          = 0;
char * loren_market = "\\Custom\\Maps\\MapName_MarketRolen.OZT";
char * name_load    = "";

__declspec(naked) void interface_load()
{
	_asm
	{
	mov dword ptr ss:[ebp-0x94],0x27
    push 0x7B6A5C
    lea eax, dword ptr ss:[ebp-0x94]
    push eax
    mov ecx, dword ptr ss:[ebp-0x98]
    add ecx,4
    call load_1
    mov ecx, eax
    call load_2
	//
	mov dword ptr ss:[ebp-0x94],0x28
    push loren_market
    lea eax, dword ptr ss:[ebp-0x94]
    push eax
    mov ecx, dword ptr ss:[ebp-0x98]
    add ecx,4
    call load_1
    mov ecx, eax
    call load_2
	//
	mov edi, 0x006D9C56
	jmp edi
    load_1:
	mov edi, 0x006DA070
	jmp edi
    load_2:
	mov edi, 0x004142E0
	jmp edi
    mov esp, ebp
    pop ebp
    retn
	}
}

__declspec(naked) void name_map_load()
{
	_asm
	{
		mov map, eax
	}

	if(map == 37)
	{
		name_load = (char*)0x0784D510;
	}
	else if(map == 40)
	{
		name_load = "Loren Market";
	}
	else
	{
		_asm
		{
		mov ecx, 0x0064B185
		jmp ecx
		}
	}

	_asm
	{
    mov eax,name_load
    retn
	}
}

hook

Code:
	//hook_extended(0x006D9C2B,                (DWORD)(&interface_load));
	//func_nop(0x006D9C2B+5, 38);

	//hook_extended(0x0064B17A,                (DWORD)(&name_map_load));
	//func_nop(0x0064B17A+5, 6);
 
at least in version 1.02c addition to the changes in gameserver I just changed the main to read the map name and the interface name that appears so when will the map

Here is the code that reads into main 1.02c

sorry my english is bad

Code:
#include "stdafx.h"

int    map          = 0;
char * loren_market = "\\Custom\\Maps\\MapName_MarketRolen.OZT";
char * name_load    = "";

__declspec(naked) void interface_load()
{
    _asm
    {
    mov dword ptr ss:[ebp-0x94],0x27
    push 0x7B6A5C
    lea eax, dword ptr ss:[ebp-0x94]
    push eax
    mov ecx, dword ptr ss:[ebp-0x98]
    add ecx,4
    call load_1
    mov ecx, eax
    call load_2
    //
    mov dword ptr ss:[ebp-0x94],0x28
    push loren_market
    lea eax, dword ptr ss:[ebp-0x94]
    push eax
    mov ecx, dword ptr ss:[ebp-0x98]
    add ecx,4
    call load_1
    mov ecx, eax
    call load_2
    //
    mov edi, 0x006D9C56
    jmp edi
    load_1:
    mov edi, 0x006DA070
    jmp edi
    load_2:
    mov edi, 0x004142E0
    jmp edi
    mov esp, ebp
    pop ebp
    retn
    }
}

__declspec(naked) void name_map_load()
{
    _asm
    {
        mov map, eax
    }

    if(map == 37)
    {
        name_load = (char*)0x0784D510;
    }
    else if(map == 40)
    {
        name_load = "Loren Market";
    }
    else
    {
        _asm
        {
        mov ecx, 0x0064B185
        jmp ecx
        }
    }

    _asm
    {
    mov eax,name_load
    retn
    }
}

hook

Code:
    //hook_extended(0x006D9C2B,                (DWORD)(&interface_load));
    //func_nop(0x006D9C2B+5, 38);

    //hook_extended(0x0064B17A,                (DWORD)(&name_map_load));
    //func_nop(0x0064B17A+5, 6);

thanks for it i will try test =)
 
Back