WorldGen: Difference between revisions

From Vintage Story Wiki
Line 47: Line 47:
This is registering a treasure command with the server with a brief description that is used to describe the command for when the user types /help. The other important argument is the PlaceTreasureChestInFrontOfPlayer argument which is a reference to a method we haven't written yet. So lets add the following method below StartServerSide.
This is registering a treasure command with the server with a brief description that is used to describe the command for when the user types /help. The other important argument is the PlaceTreasureChestInFrontOfPlayer argument which is a reference to a method we haven't written yet. So lets add the following method below StartServerSide.
<syntaxhighlight lang="c#">
<syntaxhighlight lang="c#">
        private void PlaceTreasureChestInFrontOfPlayer(IServerPlayer player, int groupId, CmdArgs args)
private void PlaceTreasureChestInFrontOfPlayer(IServerPlayer player, int groupId, CmdArgs args)
        {
{
 
}
        }
</syntaxhighlight>
</syntaxhighlight>


256

edits