From Asgard
Jump to: navigation, search

Data Members

-target: Fighter

The Fighter that the transaction is being executed on. Can be the same as executor.

-stat: string

The stat name. i.e. "hp", "mp", "level"

-change: int

How much the stat is changed. This maybe a problem, please examine.

-status: string

The status this transaction inflicts


Transaction(target: Fighter, stat: string, change: int)

Construct a Transaction for modifying Statistics.

Transaction(target: Fighter, status: string, add: bool)

Construct a Transaction for adding removing a Status. If add is true, it adds the Status.

execute(): void

Perform transaction in target. Called by Event.execute().
Note: If change = 0 and status != "", generate the Status object and it's Transactions based off the target's Statistics.
If add is set to True, add the status, if add is set to False, remove it. (if this is a Status Transaction)

getTarget(): Fighter

setTarget(target: Fighter): void

getStat(): string

setStat(stat: string): void

getChange(): int

setChange(change: int): void

getStatus(): string

setStatus(status: string): void

See Also