How can I convert Data

data:93 30 0C 03 01 >>> I can convert it to this form. b’\x00



would it be enough to do it this way?

You’re missing \x93 at the beginning. I assume you’re trying to do something with a transport. The ID of your transport changes on every teleport and summon so you have to use the APIs to get that info then use it in your packet instead of a hardcoded ID value.

actually the item I want to do. Beginner scroll of experience (100%)

xPacketTool > Show Client packets[C->S] select.

opcode: 0x704C
(Data) :11 30 0C 0D 0E

condition this

elif msg == “Exp100”:
# itemname
item100 = get_item(24196)[“name”]
log(‘Plugin: Trying to use ‘+str(item100)+’ …’)
# –

When I try to use it this way, the connection drops.

You can harcode that as long as the scrolls are always in the same slot. The first byte (11) is the inventory slot.

Yes, new opened characters and items are in the same section.

can i use clintess if NO client only

Just a little push to avoid taking bad habits.

from phBot import *
import struct

def handle_chat(t,player,msg):
	if msg == 'Exp100':
		# search item on inventory
		item100 = GetItemByExpression(lambda n,s: n == 'Beginner scroll of experience (100%)',13)
		# check existence
		if item100:
			log('Plugin: Trying to use '+str(item100['name'])+'...')
			p = struct.pack('B',item100['slot'])
			p += b'\x30\x0C\x0D\x0E'
			log('Plugin: "Beginner scroll of experience (100%)" item name not found on inventory')

# Search an item by name or servername through lambda expression and return his information
def GetItemByExpression(_lambda,start=0,end=0):
	inventory = get_inventory()
	items = inventory['items']
	if end == 0:
		end = inventory['size']
	# check items between intervals
	for slot, item in enumerate(items):
		if start <= slot and slot <= end:
			if item:
				# Search by lambda
				if _lambda(item['name'],item['servername']):
					# Save slot location
					item['slot'] = slot
					return item
	return None
1 Like

Hey jelly.

It is quite difficult to teleport the characters one by one during the war. Is there an easy way to do this?
It is quite annoying to beam from phbot maps one by one :frowning:

No you cant its blocked.

I’m not saying with code.

with magic?

for example with manager :slight_smile:

If you could do it with manager then theres no point in blocking it through plugins.

Both are different.

you only teleport characters on your own computer from the manager.

Thank you very much.


1 Like

Akademi eklentisindeki import struct altına eklemem yeterlimi bunu @EzKime

1 Like