Grasscutter/src/main/java/emu/grasscutter/server/packet/send/PacketDungeonChallengeBeginNotify.java
Melledy 1b97b4afa0 Fixed dungeon challenge scoreboard and implement dungeon drops
Also fixed a few dungeon script handlers
2022-05-03 23:24:43 -07:00

24 lines
852 B
Java

package emu.grasscutter.server.packet.send;
import emu.grasscutter.game.dungeons.DungeonChallenge;
import emu.grasscutter.net.packet.BasePacket;
import emu.grasscutter.net.packet.PacketOpcodes;
import emu.grasscutter.net.proto.DungeonChallengeBeginNotifyOuterClass.DungeonChallengeBeginNotify;
public class PacketDungeonChallengeBeginNotify extends BasePacket {
public PacketDungeonChallengeBeginNotify(DungeonChallenge challenge) {
super(PacketOpcodes.DungeonChallengeBeginNotify, true);
DungeonChallengeBeginNotify proto = DungeonChallengeBeginNotify.newBuilder()
.setChallengeId(challenge.getChallengeId())
.setChallengeIndex(challenge.getChallengeIndex())
.setGroupId(challenge.getGroup().id)
.addParamList(challenge.getObjective())
.addParamList(challenge.getTimeLimit())
.build();
this.setData(proto);
}
}