Table of Contents

Interface ICoreAPI

Namespace
Vintagestory.API.Common
Assembly
VintagestoryAPI.dll

Common API Components that are available on the server and the client. Cast to ICoreServerAPI or ICoreClientAPI to access side specific features.

public interface ICoreAPI : ICoreAPICommon
Inherited Members
Extension Methods

Properties

Assets

API Component for loading and reloading one or multiple assets at once from the assets folder

IAssetManager Assets { get; }

Property Value

IAssetManager

ChatCommands

IChatCommandApi ChatCommands { get; }

Property Value

IChatCommandApi

ClassRegistry

API Compoment for creating instances of certain classes, such as Itemstacks

IClassRegistryAPI ClassRegistry { get; }

Property Value

IClassRegistryAPI

CmdlArguments

The command line arguments that were used to start the client or server application

string[] CmdlArguments { get; }

Property Value

string[]

Event

Api component to register/trigger events

IEventAPI Event { get; }

Property Value

IEventAPI

Logger

The local Logger instance.

ILogger Logger { get; }

Property Value

ILogger

ModLoader

API Component for checking for and interacting with other mods and mod systems

IModLoader ModLoader { get; }

Property Value

IModLoader

Network

API for sending/receiving network packets

INetworkAPI Network { get; }

Property Value

INetworkAPI

Side

Returns if you are currently on server or on client

EnumAppSide Side { get; }

Property Value

EnumAppSide

World

Second API Component for access/modify everything game world related

IWorldAccessor World { get; }

Property Value

IWorldAccessor

Methods

RegisterEntityClass(string, EntityProperties)

Registers a new entity config for given entity class

void RegisterEntityClass(string entityClassName, EntityProperties config)

Parameters

entityClassName string
config EntityProperties