2020-03-12 17:22:48 +01:00
|
|
|
import 'package:aidedejeu_flutter/models/items.dart';
|
|
|
|
|
import 'package:equatable/equatable.dart';
|
|
|
|
|
|
|
|
|
|
abstract class PlayerCharacterEvent extends Equatable {}
|
|
|
|
|
|
|
|
|
|
class SetItemEvent<T> extends PlayerCharacterEvent {
|
|
|
|
|
final T item;
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
List<Object> get props => [item];
|
|
|
|
|
|
|
|
|
|
SetItemEvent(T item) : this.item = item;
|
|
|
|
|
}
|
|
|
|
|
|
2020-03-13 09:46:17 +01:00
|
|
|
class RaceEvent extends SetItemEvent<RaceItem> {
|
|
|
|
|
RaceEvent(RaceItem item) : super(item);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class SubRaceEvent extends SetItemEvent<SubRaceItem> {
|
|
|
|
|
SubRaceEvent(SubRaceItem item) : super(item);
|
|
|
|
|
}
|
|
|
|
|
|
2020-03-12 17:22:48 +01:00
|
|
|
class BackgroundEvent extends SetItemEvent<BackgroundItem> {
|
|
|
|
|
BackgroundEvent(BackgroundItem item) : super(item);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class SubBackgroundEvent extends SetItemEvent<SubBackgroundItem> {
|
|
|
|
|
SubBackgroundEvent(SubBackgroundItem item) : super(item);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class LoadEvent extends PlayerCharacterEvent {
|
|
|
|
|
@override
|
|
|
|
|
List<Object> get props => [];
|
|
|
|
|
}
|
|
|
|
|
|