Jump to content
  • 0

Remove equip garment Costume


Question

Posted

Hello how can i properly remove a costume equipment via sql? example i want to properly remove the costume archangel wing ( 20500)

Ive used

DELETE FROM `inventory ` WHERE nameid='20500' AND equip='8192;

But when i login i can see that the archangel wing(20500) is gone in the equip but the sprite view is still there.

Is there anyway to remove also the sprite view upon deleting the item in sql?

or is there any scripts that can be done via onlogin to automatically check and remove the player's costume garment sprite view before entering the game?

Thanks in advance!

2 answers to this question

Recommended Posts

  • 0
Posted (edited)
2 hours ago, Nero said:

Is there anyway to remove also the sprite view upon deleting the item in sql?

Yes, check this part:

table : `char`
columns : `head_top` , `head_mid` , `head_bottom`
Quote

or is there any scripts that can be done via onlogin to automatically check and remove the player's costume garment sprite view before entering the game?

I don't think it is possible.. Never tried it tho

Edited by pajodex
  • 0
Posted

Script:

	// Here goes your view id to remove.
	.@view_id = 999;
	setarray .@look[0],LOOK_HEAD_BOTTOM,LOOK_HEAD_TOP,LOOK_HEAD_MID;
	for(.@i = EQI_HEAD_LOW;.@i <= EQI_HEAD_TOP;.@i++) {
		.@view = getiteminfo(getequipid(.@i),11);
		if(getlook(.@look[.@i - 4]) == .@view_id)
			setlook .@look[.@i - 4],.@view;
	}

Or querys:

	UPDATE `char` SET `head_top` = '0' WHERE `head_top` = '999'
	UPDATE `char` SET `head_mid` = '0' WHERE `head_mid` = '999'
	UPDATE `char` SET `head_bottom` = '0' WHERE `head_bottom` = '999'

I don't know how these might work, they may reset the view ids and players might have to relog (they could have no view id even if they have a poring hat, for example).

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...