• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook pagefor updates, or we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.)

[Help] How to resize items model in inventory?

Junior Spellweaver
Joined
Feb 18, 2011
Messages
108
Reaction score
41
Hi,

I want to change height and width of every item in the game to 1:1 (every item will ocupy 1 slot in inventory).

By changing the values of Height and Width in item.bmd the item ocupies only 1 slot but the 3d model of the item remains the same. I need to resize the model too to fit in 1 slot.

Does anyone know if there is a client file with the size (height/width) of items models or this is hard-coded in the .exe?

Thanks in advance.
 
Joined
Nov 4, 2012
Messages
928
Reaction score
545
you didn't even test it?it's a part of the pDrawItemModel.

You made it static bro, there is the problem.
Also just change Scale will buggy some items that deppends to change X Y Position according their size.

.H
Code:
#pragma once

// Draw Item Model Class
#define pDrawItemModel						((void(__cdecl*)(float PosX,float PosY,float Width,float Height,int ItemID,int Level,int Excellent,int Ancient,int Floating)) 0x5D2280) // Floating related to size
#define oDrawItemModelCall1					0x0077117C // Inventory and Personal Shop Call?
#define oDrawItemModelCall2					0x0085CE0D // CashShop Call?

class cDrawItemModel
{
public:
	cDrawItemModel();

	void		Load();
	static void DrawItemModel(float PosX,float PosY,float Width,float Height,int ItemID,int a6,int a7,int Ancient,int Floating);
};

extern cDrawItemModel gDrawItemModel;

.CPP
Code:
#include "stdafx.h"

cDrawItemModel gDrawItemModel;

cDrawItemModel::cDrawItemModel()
{
	/**/
}

void cDrawItemModel::Load()
{
	gToolKit.SetOp((LPVOID)(oDrawItemModelCall1),this->DrawItemModel,ASM::CALL);
	gToolKit.SetOp((LPVOID)(oDrawItemModelCall2),this->DrawItemModel,ASM::CALL);
}

void cDrawItemModel::DrawItemModel(float PosX,float PosY,float Width,float Height,int ItemID,int Level,int Excellent,int Ancient,int Floating)
{
	if(ItemID == ItemId(8,15)) // Fix Storm Crow armor position
	{
		PosY -= 10.0f;
	}

	pDrawItemModel(PosX,PosY,Width,Height,ItemID,Level,Excellent,Ancient,Floating);
}

Code:
http://patch-ggp.muonline.webzen.net/1.03.43/up_list.zip

Anyway will do same thing

Ps. Main 1.03.43
 
Upvote 0
Skilled Illusionist
Joined
Jun 22, 2017
Messages
363
Reaction score
561
You made it static bro, there is the problem.
Also just change Scale will buggy some items that deppends to change X Y Position according their size.
you are wrong! i didn't changed item width, height.

i changed Model Scale, it's difference thinks. (lpObj->m_Model.Scale) this is static



wz calculate scale size by window size not the item size.
ex: scale = 1.0 it means model height = 480 and width = 640.
 
Last edited:
Upvote 0
Junior Spellweaver
Joined
Feb 18, 2011
Messages
108
Reaction score
41
will not work for other parts than inventory, again i suggest you to see a function that i have posted, duo all calls to inventory model size is remated with this function, like in cashshop for example.

I specificly asked for how to change the size of items 3d models in inventory. myheart 's answer fits precisely what I asked for.
 
Upvote 0
Back
Top