Skip to content
This repository was archived by the owner on May 15, 2022. It is now read-only.

AddItem

Matias Salas edited this page Nov 4, 2020 · 1 revision
Player.AddItem(Source, Name, Amount)

This function add an item to player inventory.

Arguments

Argument Type Optional Default Value Explanation
Source CitizenFX.Core.Player No - Player
Name string No - Item Name
Amount int No - Item Amount

Example

public void Example([FromSource] CitizenFX.Core.Player Source)
{
    Player.AddItem(Source, "Something", 3) //Added item "Something" x3 to player
}

Clone this wiki locally