C# Класс Aura.Channel.Scripting.Scripts.GameEventScript

Script for in-game events, like Double Rainbow.
Наследование: GeneralScript
Показать файл Открыть проект

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

Метод Описание
AddActivationSpan ( ActivationSpan span ) : void

Adds the given activation span to the event, in which it's supposed to be active.

AfterLoad ( ) : void

Called after script was registered, so it can schedule itself.

Dispose ( ) : void
End ( ) : void

Stops event if it's active.

Init ( ) : bool

Loads and sets up event.

IsActiveTime ( System.DateTime time ) : bool

Returns true if the event is supposed to be active at the given time, based on its activation spans.

SetId ( string id ) : void

Sets event's id.

SetName ( string name ) : void

Sets event's name, which is used for notices and broadcasts.

Start ( ) : void

Starts event if it's not active yet.

Защищенные методы

Метод Описание
AddEventItemToShop ( string shopName, int itemId, int amount = 1, int price = -1, int stock = -1 ) : void

Adds the the item to the given shop.

AddFishingGround ( int priority, double chance, IEnumerable locations, IEnumerable items, int rod, int bait ) : void

Adds fishing ground, to be considered when players fish.

The fishing grounds describe where a player can fish under which circumstances, and what they can catch. If multiple fishing grounds exist for a location, the priority and the chance determine which ground is used. For example, if you want to override the Tir fishing spots during and event, you could do the following, which would add a new ground for the Tir spots, with a high priority and a 100% chance, so it always gets selected over the default.

AddGlobalBonus ( GlobalBonusStat stat, float multiplier ) : void

Adds global bonus.

AddGlobalDrop ( GlobalDropType type, DropData data ) : void

Adds global drop by type.

AddGlobalDrop ( int raceId, DropData data ) : void

Adds global drop by race id.

AddGlobalDrop ( string tag, DropData data ) : void

Adds global drop by race tag.

OnEnd ( ) : void

Called when the event is deactivated.

OnStart ( ) : void

Called when the event is activated.

RemoveEventItemsFromShop ( string shopName ) : void

Removes all event items from the given shop.

RemoveFishingGrounds ( ) : void

Removes all event fishing grounds associated with this event.

RemoveGlobalBonuses ( ) : void

Removes all global bonuses associated with this event.

RemoveGlobalDrops ( ) : void

Removes all global drops associated with this event.

ScheduleEvent ( System.DateTime from, System.DateTime till ) : void

Schedules this event to be active during the given time span.

ScheduleEvent ( System.DateTime from, System.TimeSpan timeSpan ) : void

Schedules this event to be active during the given time span.

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

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

Adds the given activation span to the event, in which it's supposed to be active.
public AddActivationSpan ( ActivationSpan span ) : void
span ActivationSpan
Результат void

AddEventItemToShop() защищенный Метод

Adds the the item to the given shop.
protected AddEventItemToShop ( string shopName, int itemId, int amount = 1, int price = -1, int stock = -1 ) : void
shopName string
itemId int
amount int
price int
stock int
Результат void

AddFishingGround() защищенный Метод

Adds fishing ground, to be considered when players fish.
The fishing grounds describe where a player can fish under which circumstances, and what they can catch. If multiple fishing grounds exist for a location, the priority and the chance determine which ground is used. For example, if you want to override the Tir fishing spots during and event, you could do the following, which would add a new ground for the Tir spots, with a high priority and a 100% chance, so it always gets selected over the default.
protected AddFishingGround ( int priority, double chance, IEnumerable locations, IEnumerable items, int rod, int bait ) : void
priority int
chance double
locations IEnumerable
items IEnumerable
rod int
bait int
Результат void

AddGlobalBonus() защищенный Метод

Adds global bonus.
protected AddGlobalBonus ( GlobalBonusStat stat, float multiplier ) : void
stat GlobalBonusStat
multiplier float
Результат void

AddGlobalDrop() защищенный Метод

Adds global drop by type.
protected AddGlobalDrop ( GlobalDropType type, DropData data ) : void
type GlobalDropType
data DropData
Результат void

AddGlobalDrop() защищенный Метод

Adds global drop by race id.
protected AddGlobalDrop ( int raceId, DropData data ) : void
raceId int
data DropData
Результат void

AddGlobalDrop() защищенный Метод

Adds global drop by race tag.
protected AddGlobalDrop ( string tag, DropData data ) : void
tag string
data DropData
Результат void

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

Called after script was registered, so it can schedule itself.
public AfterLoad ( ) : void
Результат void

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

public Dispose ( ) : void
Результат void

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

Stops event if it's active.
public End ( ) : void
Результат void

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

Loads and sets up event.
public Init ( ) : bool
Результат bool

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

Returns true if the event is supposed to be active at the given time, based on its activation spans.
public IsActiveTime ( System.DateTime time ) : bool
time System.DateTime
Результат bool

OnEnd() защищенный Метод

Called when the event is deactivated.
protected OnEnd ( ) : void
Результат void

OnStart() защищенный Метод

Called when the event is activated.
protected OnStart ( ) : void
Результат void

RemoveEventItemsFromShop() защищенный Метод

Removes all event items from the given shop.
protected RemoveEventItemsFromShop ( string shopName ) : void
shopName string
Результат void

RemoveFishingGrounds() защищенный Метод

Removes all event fishing grounds associated with this event.
protected RemoveFishingGrounds ( ) : void
Результат void

RemoveGlobalBonuses() защищенный Метод

Removes all global bonuses associated with this event.
protected RemoveGlobalBonuses ( ) : void
Результат void

RemoveGlobalDrops() защищенный Метод

Removes all global drops associated with this event.
protected RemoveGlobalDrops ( ) : void
Результат void

ScheduleEvent() защищенный Метод

Schedules this event to be active during the given time span.
protected ScheduleEvent ( System.DateTime from, System.DateTime till ) : void
from System.DateTime
till System.DateTime
Результат void

ScheduleEvent() защищенный Метод

Schedules this event to be active during the given time span.
protected ScheduleEvent ( System.DateTime from, System.TimeSpan timeSpan ) : void
from System.DateTime
timeSpan System.TimeSpan
Результат void

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

Sets event's id.
public SetId ( string id ) : void
id string
Результат void

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

Sets event's name, which is used for notices and broadcasts.
public SetName ( string name ) : void
name string
Результат void

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

Starts event if it's not active yet.
public Start ( ) : void
Результат void