CPlayer_ItemServices
Interface CPlayer_ItemServices
Namespace: SwiftlyS2.Shared.SchemaDefinitions
Assembly: SwiftlyS2.CS2.dll
public interface CPlayer_ItemServices : CPlayerPawnComponent, ISchemaClass<CPlayerPawnComponent>, ISchemaClass<CPlayer_ItemServices>, ISchemaField, ISchemaClass, INativeHandleImplements
- CPlayerPawnComponent
- ISchemaClass<CPlayerPawnComponent>
- ISchemaClass<CPlayer_ItemServices>
- ISchemaField
- ISchemaClass
- INativeHandle
Methods
DropActiveItem()
Drop the item that player is holding.
Thread unsafe, use async variant instead for non-main thread context.
[ThreadUnsafe]
void DropActiveItem()DropActiveItemAsync()
Drop the item that player is holding asynchronously.
Task DropActiveItemAsync()GiveItem<T>()
Give an item to the player.
Thread unsafe, use async version instead for non-main thread context.
[ThreadUnsafe]
T GiveItem<T>() where T : ISchemaClass<T>- T — The item that was given.
- T — The type of the item to give.
GiveItem<T>(string)
Give an item to the player.
Thread unsafe, use async variant instead for non-main thread context.
[ThreadUnsafe]
T GiveItem<T>(string itemDesignerName) where T : ISchemaClass<T>- itemDesignerName string — The designer name of the item to give.
- T — The item that was given.
- T
GiveItem(string)
Give an item to the player.
Thread unsafe, use async variant instead for non-main thread context.
[ThreadUnsafe]
void GiveItem(string itemDesignerName)- itemDesignerName string — The designer name of the item to give.
GiveItemAsync<T>()
Give an item to the player asynchronously.
Task<T> GiveItemAsync<T>() where T : ISchemaClass<T>- Task<T> — The item that was given.
- T — The type of the item to give.
GiveItemAsync<T>(string)
Give an item to the player asynchronously.
Task<T> GiveItemAsync<T>(string itemDesignerName) where T : ISchemaClass<T>- itemDesignerName string — The designer name of the item to give.
- Task<T> — The item that was given.
- T
GiveItemAsync(string)
Give an item to the player asynchronously.
Task GiveItemAsync(string itemDesignerName)- itemDesignerName string — The designer name of the item to give.
- Task — The item that was given.
RemoveItems()
Remove all items from the player.
Thread unsafe, use async variant instead for non-main thread context.
[ThreadUnsafe]
void RemoveItems()RemoveItemsAsync()
Remove all items from the player asynchronously.
Task RemoveItemsAsync()