mirror of
https://github.com/Melledy/Nebula.git
synced 2025-12-18 15:24:45 +01:00
Implement new event
This commit is contained in:
40
src/main/java/emu/nebula/data/resources/ActivityTaskDef.java
Normal file
40
src/main/java/emu/nebula/data/resources/ActivityTaskDef.java
Normal file
@@ -0,0 +1,40 @@
|
||||
package emu.nebula.data.resources;
|
||||
|
||||
import emu.nebula.data.BaseDef;
|
||||
import emu.nebula.data.ResourceType;
|
||||
import emu.nebula.game.inventory.ItemParamMap;
|
||||
import lombok.Getter;
|
||||
|
||||
@Getter
|
||||
@ResourceType(name = "ActivityTask.json")
|
||||
public class ActivityTaskDef extends BaseDef {
|
||||
private int Id;
|
||||
private int ActivityTaskGroupId;
|
||||
|
||||
private int CompleteCond;
|
||||
private int AimNumShow;
|
||||
|
||||
private int Tid1;
|
||||
private int Qty1;
|
||||
private int Tid2;
|
||||
private int Qty2;
|
||||
|
||||
private transient ItemParamMap rewards;
|
||||
|
||||
@Override
|
||||
public int getId() {
|
||||
return Id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoad() {
|
||||
this.rewards = new ItemParamMap();
|
||||
|
||||
if (this.Tid1 > 0) {
|
||||
this.rewards.add(this.Tid1, this.Qty1);
|
||||
}
|
||||
if (this.Tid2 > 0) {
|
||||
this.rewards.add(this.Tid2, this.Qty2);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user