mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-01-23 10:52:56 +08:00
Merge remote-tracking branch 'origin/unstable' into unstable
This commit is contained in:
commit
fc79c72d48
@ -1,7 +1,6 @@
|
|||||||
package emu.grasscutter.game.ability.actions;
|
package emu.grasscutter.game.ability.actions;
|
||||||
|
|
||||||
import com.google.protobuf.ByteString;
|
import com.google.protobuf.ByteString;
|
||||||
|
|
||||||
import emu.grasscutter.Grasscutter;
|
import emu.grasscutter.Grasscutter;
|
||||||
import emu.grasscutter.data.binout.AbilityModifier.AbilityModifierAction;
|
import emu.grasscutter.data.binout.AbilityModifier.AbilityModifierAction;
|
||||||
import emu.grasscutter.game.ability.Ability;
|
import emu.grasscutter.game.ability.Ability;
|
||||||
@ -12,12 +11,17 @@ import emu.grasscutter.game.quest.enums.QuestContent;
|
|||||||
@AbilityAction(AbilityModifierAction.Type.AvatarSkillStart)
|
@AbilityAction(AbilityModifierAction.Type.AvatarSkillStart)
|
||||||
public class ActionAvatarSkillStart extends AbilityActionHandler {
|
public class ActionAvatarSkillStart extends AbilityActionHandler {
|
||||||
@Override
|
@Override
|
||||||
public boolean execute(Ability ability, AbilityModifierAction action, ByteString abilityData, GameEntity target) {
|
public boolean execute(
|
||||||
|
Ability ability, AbilityModifierAction action, ByteString abilityData, GameEntity target) {
|
||||||
var owner = ability.getOwner();
|
var owner = ability.getOwner();
|
||||||
if (owner instanceof EntityAvatar avatar) {
|
if (owner instanceof EntityAvatar avatar) {
|
||||||
avatar.getPlayer().getQuestManager().queueEvent(QuestContent.QUEST_CONTENT_SKILL, action.skillID);
|
avatar
|
||||||
|
.getPlayer()
|
||||||
|
.getQuestManager()
|
||||||
|
.queueEvent(QuestContent.QUEST_CONTENT_SKILL, action.skillID);
|
||||||
} else {
|
} else {
|
||||||
Grasscutter.getLogger().warn("AvatarSkillStart not implemented for other entities than EntityAvatar right now");
|
Grasscutter.getLogger()
|
||||||
|
.warn("AvatarSkillStart not implemented for other entities than EntityAvatar right now");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
package emu.grasscutter.game.player;
|
package emu.grasscutter.game.player;
|
||||||
|
|
||||||
|
import static emu.grasscutter.config.Configuration.GAME_OPTIONS;
|
||||||
|
import static emu.grasscutter.scripts.constants.EventType.EVENT_UNLOCK_TRANS_POINT;
|
||||||
|
|
||||||
import emu.grasscutter.data.GameData;
|
import emu.grasscutter.data.GameData;
|
||||||
import emu.grasscutter.data.binout.ScenePointEntry;
|
import emu.grasscutter.data.binout.ScenePointEntry;
|
||||||
import emu.grasscutter.data.excels.OpenStateData;
|
import emu.grasscutter.data.excels.OpenStateData;
|
||||||
@ -9,13 +12,9 @@ import emu.grasscutter.game.quest.enums.*;
|
|||||||
import emu.grasscutter.net.proto.RetcodeOuterClass.Retcode;
|
import emu.grasscutter.net.proto.RetcodeOuterClass.Retcode;
|
||||||
import emu.grasscutter.scripts.data.ScriptArgs;
|
import emu.grasscutter.scripts.data.ScriptArgs;
|
||||||
import emu.grasscutter.server.packet.send.*;
|
import emu.grasscutter.server.packet.send.*;
|
||||||
|
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import static emu.grasscutter.config.Configuration.GAME_OPTIONS;
|
|
||||||
import static emu.grasscutter.scripts.constants.EventType.EVENT_UNLOCK_TRANS_POINT;
|
|
||||||
|
|
||||||
// @Entity
|
// @Entity
|
||||||
public final class PlayerProgressManager extends BasePlayerDataManager {
|
public final class PlayerProgressManager extends BasePlayerDataManager {
|
||||||
/******************************************************************************************************************
|
/******************************************************************************************************************
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
package emu.grasscutter.scripts;
|
package emu.grasscutter.scripts;
|
||||||
|
|
||||||
|
import static emu.grasscutter.scripts.constants.EventType.EVENT_TIMER_EVENT;
|
||||||
|
|
||||||
import com.github.davidmoten.rtreemulti.RTree;
|
import com.github.davidmoten.rtreemulti.RTree;
|
||||||
import com.github.davidmoten.rtreemulti.geometry.Geometry;
|
import com.github.davidmoten.rtreemulti.geometry.Geometry;
|
||||||
import emu.grasscutter.Grasscutter;
|
import emu.grasscutter.Grasscutter;
|
||||||
@ -19,20 +21,17 @@ import emu.grasscutter.server.packet.send.PacketGroupSuiteNotify;
|
|||||||
import emu.grasscutter.utils.*;
|
import emu.grasscutter.utils.*;
|
||||||
import io.netty.util.concurrent.FastThreadLocalThread;
|
import io.netty.util.concurrent.FastThreadLocalThread;
|
||||||
import it.unimi.dsi.fastutil.ints.*;
|
import it.unimi.dsi.fastutil.ints.*;
|
||||||
import kotlin.Pair;
|
|
||||||
import lombok.val;
|
|
||||||
import org.luaj.vm2.*;
|
|
||||||
import org.luaj.vm2.lib.jse.CoerceJavaToLua;
|
|
||||||
|
|
||||||
import javax.annotation.*;
|
|
||||||
import java.io.*;
|
import java.io.*;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.concurrent.*;
|
import java.util.concurrent.*;
|
||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
import javax.annotation.*;
|
||||||
import static emu.grasscutter.scripts.constants.EventType.EVENT_TIMER_EVENT;
|
import kotlin.Pair;
|
||||||
|
import lombok.val;
|
||||||
|
import org.luaj.vm2.*;
|
||||||
|
import org.luaj.vm2.lib.jse.CoerceJavaToLua;
|
||||||
|
|
||||||
public class SceneScriptManager {
|
public class SceneScriptManager {
|
||||||
private final Scene scene;
|
private final Scene scene;
|
||||||
|
Loading…
Reference in New Issue
Block a user