Cookies


Vsroplus only uses the cookies it needs to keep you signed in and remember your language. No ads, no tracking.

Got it

Need to learn more? Privacy policy

Our guides are in English for now.

Add Item to Inventory

You will need to obtain the character ID for the character that should receive the item. You can use the following query to get the character ID from the database.

SELECT CharID FROM _OnlinePlayers WHERE CharName16 = 'character_name'

You will also need to obtain the item ID that you want to add. You can use the following query to get the item ID from the database.

SELECT ID FROM SRO_VT_SHARD.._RefObjCommon WHERE CodeName128 = 'ITEM_ETC_ARENA_COIN'

Stored Procedure: _Char_AddItemToInventory

Parameters:

  • @CharID INT - Target character ID
  • @RefItemID INT - Target item ID
  • @Data INT - Amount to add. If 0 is used, a full stack will be added.
  • @OptLevel TINYINT - The plus value of the item
  • @RandomizedStats BIT - Randomized stats
    If this value is set to 1, the item will have random blues.
  • @Executor VARCHAR(129) - User who added the item

Let us first test whether the command works by using the following code, which will add 10 Arena Coins.

USE [vPlus]
GO
DECLARE @CharID INT = (SELECT CharID FROM _OnlinePlayers WHERE CharName16 = 'character_name')
EXEC _Char_AddItemToInventory @CharID, 25834, 10, 0, 0, 'Reward';

For real usage, use @CharID directly from your calling procedure.

EXEC _Char_AddItemToInventory @CharID, 25834, 10, 0, 0, 'Reward';

Last updated: 8 December, 2023

An error has occurred. This application may no longer respond until reloaded. Reload 🗙