help to apply this!

07/24/2014 12:59 bluedrago#1
Just one thing, for the level max you haven't put the dif for the /level command, on the game the /level command have a limit (120)
Spoiler
Code:
int __cdecl do_level(int a1, int a2)
{
__int32 v2; // eax@2
int v3; // eax@2
int result; // eax@3
char v5; // [sp+Ch] [bp-11Ch]@0
char nptr; // [sp+1Ch] [bp-10Ch]@1
int v7; // [sp+11Ch] [bp-Ch]@1

v7 = *(_DWORD *)_stack_chk_guard__FBSD_1_0;
one_argument(a2, &nptr, 256);
if ( nptr )
{
v2 = strtol(&nptr, 0, 10);
v3 = MINMAX(1, v2, 120);
CHARACTER::ResetPoint(a1, v3);
CHARACTER::ClearSkill(a1);
CHARACTER::ClearSubSkill(a1);
}
else
{
CHARACTER::ChatPacket(a1, 1, "Syntax: level <level>", v5);
}
result = *(_DWORD *)_stack_chk_guard__FBSD_1_0 ^ v7;
if ( *(_DWORD *)_stack_chk_guard__FBSD_1_0 != v7 )
__stack_chk_fail();
return result;
}
---------------------------------
where apply this?
thanks
07/24/2014 14:36 PDDS™#2
This is C++, so you may have to add/edit this in your game-Source.

Regards
07/24/2014 15:04 Coniesan#3
here is the function of the source:
Code:
ACMD(do_level)
{
	char arg2[256];
	one_argument(argument, arg2, sizeof(arg2));

	if (!*arg2)
	{
		ch->ChatPacket(CHAT_TYPE_INFO, "Syntax: level <level>");
		return;
	}

	int	level = 0;
	str_to_number(level, arg2);
	ch->ResetPoint(MINMAX(1, level, PLAYER_MAX_LEVEL_CONST));

	ch->ClearSkill();
	ch->ClearSubSkill();
}
you only have to change the "PLAYER_MAX_LEVEL_CONST" (I think) so you only have to change the 120 up to 255 (if u want) in your code!