C# Класс Gruppe22.Backend.NPC

The class used to generate NPCs. NPCs can either tell a story to the player or have a shop.
Наследование: Actor
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AddQuest ( Quest q ) : void

Add quest to the player. This shoud be used from NPC(dialog).

ClearQuests ( ) : void

Reset the list of quests

HideQuest ( int id ) : void
Interact ( Actor With ) : void

Method to interact with a NPC. Either opens the NPC's shop or his dialogue. Calls the Eventhandler.

NPC ( int health = 10, int armor, int damage, int maxHealth = 10, string name = "", Random r = null, int _level = 1, bool shop = false ) : System

The constructor for a NPC. Initializes the standard properties and graphics for that NPC. See actor for the params.

Описание методов

AddQuest() публичный Метод

Add quest to the player. This shoud be used from NPC(dialog).
public AddQuest ( Quest q ) : void
q Quest The quest.
Результат void

ClearQuests() публичный Метод

Reset the list of quests
public ClearQuests ( ) : void
Результат void

HideQuest() публичный Метод

public HideQuest ( int id ) : void
id int
Результат void

Interact() публичный Метод

Method to interact with a NPC. Either opens the NPC's shop or his dialogue. Calls the Eventhandler.
public Interact ( Actor With ) : void
With Actor The actor with which should be interacted
Результат void

NPC() публичный Метод

The constructor for a NPC. Initializes the standard properties and graphics for that NPC. See actor for the params.
public NPC ( int health = 10, int armor, int damage, int maxHealth = 10, string name = "", Random r = null, int _level = 1, bool shop = false ) : System
health int
armor int
damage int
maxHealth int
name string
r System.Random
_level int
shop bool
Результат System