Jump to content
McKay Development

node-tf2 Renaming Items


JLeelan2

Recommended Posts

Hello,

I am trying to send a message to the TF2 game coordinator to rename an item. I tried adding the following code

TeamFortress2.prototype.nameItem = function(tagID, itemID, name) {
	let buffer = new ByteBuffer(16 + Buffer.byteLength(name) + 1, ByteBuffer.LITTLE_ENDIAN);
	buffer.writeUint64(tagID);
	buffer.writeUint64(itemID);
	buffer.writeUTF8String(name);
	this._send(Language.NameItem, null, buffer);
}

Nothing happens after I provide the item IDs and a custom name, however. I do not know how I should be constructing the bytebuffer, and it's hard to tell what I'm doing wrong since there doesn't seem to be any response from the GC at all. I would appreciate any help.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   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.

Loading...
×
×
  • Create New...