Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
ziqian zhang
Grasscutter
Commits
d32f706c
Commit
d32f706c
authored
Apr 27, 2022
by
KingRainbow44
Browse files
Merge branch 'development' into api
# Conflicts: # src/main/java/emu/grasscutter/plugin/api/ServerHook.java
parents
47d8fd3c
f0d728b4
Changes
308
Hide whitespace changes
Inline
Side-by-side
src/main/java/emu/grasscutter/server/packet/send/PacketStoreItemDelNotify.java
View file @
d32f706c
...
...
@@ -2,33 +2,33 @@ package emu.grasscutter.server.packet.send;
import
java.util.Collection
;
import
emu.grasscutter.game.inventory.G
enshin
Item
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.inventory.G
ame
Item
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.StoreItemDelNotifyOuterClass.StoreItemDelNotify
;
import
emu.grasscutter.net.proto.StoreTypeOuterClass.StoreType
;
public
class
PacketStoreItemDelNotify
extends
Genshin
Packet
{
public
class
PacketStoreItemDelNotify
extends
Base
Packet
{
private
PacketStoreItemDelNotify
()
{
super
(
PacketOpcodes
.
StoreItemDelNotify
);
}
public
PacketStoreItemDelNotify
(
G
enshin
Item
item
)
{
public
PacketStoreItemDelNotify
(
G
ame
Item
item
)
{
this
();
StoreItemDelNotify
.
Builder
proto
=
StoreItemDelNotify
.
newBuilder
()
.
setStoreType
(
StoreType
.
S
torePack
)
.
setStoreType
(
StoreType
.
S
TORE_PACK
)
.
addGuidList
(
item
.
getGuid
());
this
.
setData
(
proto
);
}
public
PacketStoreItemDelNotify
(
Collection
<
G
enshin
Item
>
items
)
{
public
PacketStoreItemDelNotify
(
Collection
<
G
ame
Item
>
items
)
{
this
();
StoreItemDelNotify
.
Builder
proto
=
StoreItemDelNotify
.
newBuilder
()
.
setStoreType
(
StoreType
.
S
torePack
);
.
setStoreType
(
StoreType
.
S
TORE_PACK
);
items
.
stream
().
forEach
(
item
->
proto
.
addGuidList
(
item
.
getGuid
()));
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketStoreWeightLimitNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.Grasscutter
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.StoreTypeOuterClass.StoreType
;
import
emu.grasscutter.net.proto.StoreWeightLimitNotifyOuterClass.StoreWeightLimitNotify
;
public
class
PacketStoreWeightLimitNotify
extends
Genshin
Packet
{
public
class
PacketStoreWeightLimitNotify
extends
Base
Packet
{
public
PacketStoreWeightLimitNotify
()
{
super
(
PacketOpcodes
.
StoreWeightLimitNotify
);
StoreWeightLimitNotify
p
=
StoreWeightLimitNotify
.
newBuilder
()
.
setStoreType
(
StoreType
.
S
torePack
)
.
setStoreType
(
StoreType
.
S
TORE_PACK
)
.
setWeightLimit
(
Grasscutter
.
getConfig
().
getGameServerOptions
().
InventoryLimitAll
)
.
setWeaponCountLimit
(
Grasscutter
.
getConfig
().
getGameServerOptions
().
InventoryLimitWeapon
)
.
setReliquaryCountLimit
(
Grasscutter
.
getConfig
().
getGameServerOptions
().
InventoryLimitRelic
)
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketSyncScenePlayTeamEntityNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.
Genshin
Player
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.
player.
Player
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.SyncScenePlayTeamEntityNotifyOuterClass.SyncScenePlayTeamEntityNotify
;
public
class
PacketSyncScenePlayTeamEntityNotify
extends
Genshin
Packet
{
public
class
PacketSyncScenePlayTeamEntityNotify
extends
Base
Packet
{
public
PacketSyncScenePlayTeamEntityNotify
(
Genshin
Player
player
)
{
public
PacketSyncScenePlayTeamEntityNotify
(
Player
player
)
{
super
(
PacketOpcodes
.
SyncScenePlayTeamEntityNotify
);
SyncScenePlayTeamEntityNotify
proto
=
SyncScenePlayTeamEntityNotify
.
newBuilder
()
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketSyncTeamEntityNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.
Genshin
Player
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.
player.
Player
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.AbilitySyncStateInfoOuterClass.AbilitySyncStateInfo
;
import
emu.grasscutter.net.proto.SyncTeamEntityNotifyOuterClass.SyncTeamEntityNotify
;
import
emu.grasscutter.net.proto.TeamEntityInfoOuterClass.TeamEntityInfo
;
public
class
PacketSyncTeamEntityNotify
extends
Genshin
Packet
{
public
class
PacketSyncTeamEntityNotify
extends
Base
Packet
{
public
PacketSyncTeamEntityNotify
(
Genshin
Player
player
)
{
public
PacketSyncTeamEntityNotify
(
Player
player
)
{
super
(
PacketOpcodes
.
SyncTeamEntityNotify
);
SyncTeamEntityNotify
.
Builder
proto
=
SyncTeamEntityNotify
.
newBuilder
()
.
setSceneId
(
player
.
getSceneId
());
if
(
player
.
getWorld
().
isMultiplayer
())
{
for
(
Genshin
Player
p
:
player
.
getWorld
().
getPlayers
())
{
for
(
Player
p
:
player
.
getWorld
().
getPlayers
())
{
// Skip if same player
if
(
player
==
p
)
{
continue
;
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketTakePlayerLevelRewardRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.TakePlayerLevelRewardRspOuterClass.TakePlayerLevelRewardRsp
;
public
class
PacketTakePlayerLevelRewardRsp
extends
Genshin
Packet
{
public
class
PacketTakePlayerLevelRewardRsp
extends
Base
Packet
{
public
PacketTakePlayerLevelRewardRsp
(
int
level
,
int
rewardId
)
{
super
(
PacketOpcodes
.
TakePlayerLevelRewardRsp
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketTakeoffEquipRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.TakeoffEquipRspOuterClass.TakeoffEquipRsp
;
public
class
PacketTakeoffEquipRsp
extends
Genshin
Packet
{
public
class
PacketTakeoffEquipRsp
extends
Base
Packet
{
public
PacketTakeoffEquipRsp
(
long
avatarGuid
,
int
slot
)
{
super
(
PacketOpcodes
.
TakeoffEquipRsp
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketTowerAllDataRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.TowerAllDataRspOuterClass.TowerAllDataRsp
;
import
emu.grasscutter.net.proto.TowerCurLevelRecordOuterClass.TowerCurLevelRecord
;
import
emu.grasscutter.net.proto.TowerFloorRecordOuterClass.TowerFloorRecord
;
public
class
PacketTowerAllDataRsp
extends
Genshin
Packet
{
public
class
PacketTowerAllDataRsp
extends
Base
Packet
{
public
PacketTowerAllDataRsp
()
{
super
(
PacketOpcodes
.
TowerAllDataRsp
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketUnlockAvatarTalentRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.avatar.
Genshin
Avatar
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.avatar.Avatar
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.UnlockAvatarTalentRspOuterClass.UnlockAvatarTalentRsp
;
public
class
PacketUnlockAvatarTalentRsp
extends
Genshin
Packet
{
public
class
PacketUnlockAvatarTalentRsp
extends
Base
Packet
{
public
PacketUnlockAvatarTalentRsp
(
Genshin
Avatar
avatar
,
int
talentId
)
{
public
PacketUnlockAvatarTalentRsp
(
Avatar
avatar
,
int
talentId
)
{
super
(
PacketOpcodes
.
UnlockAvatarTalentRsp
);
UnlockAvatarTalentRsp
proto
=
UnlockAvatarTalentRsp
.
newBuilder
()
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketUnlockNameCardNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.UnlockNameCardNotifyOuterClass.UnlockNameCardNotify
;
public
class
PacketUnlockNameCardNotify
extends
Genshin
Packet
{
public
class
PacketUnlockNameCardNotify
extends
Base
Packet
{
public
PacketUnlockNameCardNotify
(
int
nameCard
)
{
super
(
PacketOpcodes
.
UnlockNameCardNotify
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketUseItemRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.inventory.G
enshin
Item
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.inventory.G
ame
Item
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.RetcodeOuterClass
;
import
emu.grasscutter.net.proto.UseItemRspOuterClass.UseItemRsp
;
public
class
PacketUseItemRsp
extends
Genshin
Packet
{
public
class
PacketUseItemRsp
extends
Base
Packet
{
public
PacketUseItemRsp
(
long
targetGuid
,
G
enshin
Item
useItem
)
{
public
PacketUseItemRsp
(
long
targetGuid
,
G
ame
Item
useItem
)
{
super
(
PacketOpcodes
.
UseItemRsp
);
UseItemRsp
proto
=
UseItemRsp
.
newBuilder
()
...
...
@@ -22,7 +23,7 @@ public class PacketUseItemRsp extends GenshinPacket {
public
PacketUseItemRsp
()
{
super
(
PacketOpcodes
.
UseItemRsp
);
UseItemRsp
proto
=
UseItemRsp
.
newBuilder
().
setRetcode
(
1
).
build
();
UseItemRsp
proto
=
UseItemRsp
.
newBuilder
().
setRetcode
(
RetcodeOuterClass
.
Retcode
.
RET_SVR_ERROR_VALUE
).
build
();
this
.
setData
(
proto
);
}
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWeaponAwakenRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.avatar.
Genshin
Avatar
;
import
emu.grasscutter.game.inventory.G
enshin
Item
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.avatar.Avatar
;
import
emu.grasscutter.game.inventory.G
ame
Item
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.WeaponAwakenRspOuterClass.WeaponAwakenRsp
;
public
class
PacketWeaponAwakenRsp
extends
Genshin
Packet
{
public
class
PacketWeaponAwakenRsp
extends
Base
Packet
{
public
PacketWeaponAwakenRsp
(
Genshin
Avatar
avatar
,
G
enshin
Item
item
,
G
enshin
Item
feedWeapon
,
int
oldRefineLevel
)
{
public
PacketWeaponAwakenRsp
(
Avatar
avatar
,
G
ame
Item
item
,
G
ame
Item
feedWeapon
,
int
oldRefineLevel
)
{
super
(
PacketOpcodes
.
WeaponAwakenRsp
);
WeaponAwakenRsp
.
Builder
proto
=
WeaponAwakenRsp
.
newBuilder
()
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWeaponPromoteRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.inventory.G
enshin
Item
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.inventory.G
ame
Item
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.WeaponPromoteRspOuterClass.WeaponPromoteRsp
;
public
class
PacketWeaponPromoteRsp
extends
Genshin
Packet
{
public
class
PacketWeaponPromoteRsp
extends
Base
Packet
{
public
PacketWeaponPromoteRsp
(
G
enshin
Item
item
,
int
oldPromoteLevel
)
{
public
PacketWeaponPromoteRsp
(
G
ame
Item
item
,
int
oldPromoteLevel
)
{
super
(
PacketOpcodes
.
WeaponPromoteRsp
);
WeaponPromoteRsp
proto
=
WeaponPromoteRsp
.
newBuilder
()
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWeaponUpgradeRsp.java
View file @
d32f706c
...
...
@@ -2,15 +2,15 @@ package emu.grasscutter.server.packet.send;
import
java.util.List
;
import
emu.grasscutter.game.inventory.G
enshin
Item
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.inventory.G
ame
Item
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.ItemParamOuterClass.ItemParam
;
import
emu.grasscutter.net.proto.WeaponUpgradeRspOuterClass.WeaponUpgradeRsp
;
public
class
PacketWeaponUpgradeRsp
extends
Genshin
Packet
{
public
class
PacketWeaponUpgradeRsp
extends
Base
Packet
{
public
PacketWeaponUpgradeRsp
(
G
enshin
Item
item
,
int
oldLevel
,
List
<
ItemParam
>
leftoverOres
)
{
public
PacketWeaponUpgradeRsp
(
G
ame
Item
item
,
int
oldLevel
,
List
<
ItemParam
>
leftoverOres
)
{
super
(
PacketOpcodes
.
WeaponUpgradeRsp
);
WeaponUpgradeRsp
proto
=
WeaponUpgradeRsp
.
newBuilder
()
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWearEquipRsp.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.WearEquipRspOuterClass.WearEquipRsp
;
public
class
PacketWearEquipRsp
extends
Genshin
Packet
{
public
class
PacketWearEquipRsp
extends
Base
Packet
{
public
PacketWearEquipRsp
(
long
avatarGuid
,
long
equipGuid
)
{
super
(
PacketOpcodes
.
WearEquipRsp
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWorldDataNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.World
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.
world.
World
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.PropValueOuterClass.PropValue
;
import
emu.grasscutter.net.proto.WorldDataNotifyOuterClass.WorldDataNotify
;
public
class
PacketWorldDataNotify
extends
Genshin
Packet
{
public
class
PacketWorldDataNotify
extends
Base
Packet
{
public
PacketWorldDataNotify
(
World
world
)
{
super
(
PacketOpcodes
.
WorldDataNotify
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWorldPlayerDieNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.PlayerDieTypeOuterClass.PlayerDieType
;
import
emu.grasscutter.net.proto.WorldPlayerDieNotifyOuterClass.WorldPlayerDieNotify
;
public
class
PacketWorldPlayerDieNotify
extends
Genshin
Packet
{
public
class
PacketWorldPlayerDieNotify
extends
Base
Packet
{
public
PacketWorldPlayerDieNotify
(
PlayerDieType
playerDieType
,
int
killerId
)
{
super
(
PacketOpcodes
.
WorldPlayerDieNotify
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWorldPlayerInfoNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.
Genshin
Player
;
import
emu.grasscutter.game.World
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.
player.
Player
;
import
emu.grasscutter.game.
world.
World
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.WorldPlayerInfoNotifyOuterClass.WorldPlayerInfoNotify
;
public
class
PacketWorldPlayerInfoNotify
extends
Genshin
Packet
{
public
class
PacketWorldPlayerInfoNotify
extends
Base
Packet
{
public
PacketWorldPlayerInfoNotify
(
World
world
)
{
super
(
PacketOpcodes
.
WorldPlayerInfoNotify
);
...
...
@@ -14,7 +14,7 @@ public class PacketWorldPlayerInfoNotify extends GenshinPacket {
WorldPlayerInfoNotify
.
Builder
proto
=
WorldPlayerInfoNotify
.
newBuilder
();
for
(
int
i
=
0
;
i
<
world
.
getPlayers
().
size
();
i
++)
{
Genshin
Player
p
=
world
.
getPlayers
().
get
(
i
);
Player
p
=
world
.
getPlayers
().
get
(
i
);
proto
.
addPlayerInfoList
(
p
.
getOnlinePlayerInfo
());
proto
.
addPlayerUidList
(
p
.
getUid
());
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWorldPlayerLocationNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.
Genshin
Player
;
import
emu.grasscutter.game.World
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.
player.
Player
;
import
emu.grasscutter.game.
world.
World
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.WorldPlayerLocationNotifyOuterClass.WorldPlayerLocationNotify
;
public
class
PacketWorldPlayerLocationNotify
extends
Genshin
Packet
{
public
class
PacketWorldPlayerLocationNotify
extends
Base
Packet
{
public
PacketWorldPlayerLocationNotify
(
World
world
)
{
super
(
PacketOpcodes
.
WorldPlayerLocationNotify
);
WorldPlayerLocationNotify
.
Builder
proto
=
WorldPlayerLocationNotify
.
newBuilder
();
for
(
Genshin
Player
p
:
world
.
getPlayers
())
{
proto
.
addPlayerLocList
(
p
.
getWorldPlayerLocationInfo
());
for
(
Player
p
:
world
.
getPlayers
())
{
proto
.
addPlayer
World
LocList
(
p
.
getWorldPlayerLocationInfo
());
}
this
.
setData
(
proto
);
...
...
src/main/java/emu/grasscutter/server/packet/send/PacketWorldPlayerRTTNotify.java
View file @
d32f706c
package
emu.grasscutter.server.packet.send
;
import
emu.grasscutter.game.
Genshin
Player
;
import
emu.grasscutter.game.World
;
import
emu.grasscutter.net.packet.
Genshin
Packet
;
import
emu.grasscutter.game.
player.
Player
;
import
emu.grasscutter.game.
world.
World
;
import
emu.grasscutter.net.packet.
Base
Packet
;
import
emu.grasscutter.net.packet.PacketOpcodes
;
import
emu.grasscutter.net.proto.PlayerRTTInfoOuterClass.PlayerRTTInfo
;
import
emu.grasscutter.net.proto.WorldPlayerRTTNotifyOuterClass.WorldPlayerRTTNotify
;
public
class
PacketWorldPlayerRTTNotify
extends
Genshin
Packet
{
public
class
PacketWorldPlayerRTTNotify
extends
Base
Packet
{
public
PacketWorldPlayerRTTNotify
(
World
world
)
{
super
(
PacketOpcodes
.
WorldPlayerRTTNotify
);
WorldPlayerRTTNotify
.
Builder
proto
=
WorldPlayerRTTNotify
.
newBuilder
();
for
(
Genshin
Player
player
:
world
.
getPlayers
())
{
for
(
Player
player
:
world
.
getPlayers
())
{
proto
.
addPlayerRttList
(
PlayerRTTInfo
.
newBuilder
()
.
setUid
(
player
.
getUid
())
...
...
src/main/java/emu/grasscutter/task/Task.java
0 → 100644
View file @
d32f706c
package
emu.grasscutter.task
;
import
org.quartz.JobDataMap
;
import
java.lang.annotation.Retention
;
import
java.lang.annotation.RetentionPolicy
;
/*
* So what is cron expression?
The format of a Cron expression is as follows.
Second Minute Hour Day Month Week Year
Seconds: 0-59
Minute: 0-59
hour: 0-23
Day: 1-31
Month: 1-12
Week: 1-7 (0-6 sometimes)
Year: Specify your own
If you want to express every second or every minute or something like that, use the * symbol in that position;
if you want to express more than one such as every 15 minutes and every 30 minutes, you can write:`15, 30`.
For the rest of the wildcard characters, please Google them yourself
*/
@Retention
(
RetentionPolicy
.
RUNTIME
)
public
@interface
Task
{
String
taskName
()
default
"NO_NAME"
;
String
taskCronExpression
()
default
"0 0 0 0 0 ?"
;
String
triggerName
()
default
"NO_NAME"
;
boolean
executeImmediatelyAfterReset
()
default
false
;
boolean
executeImmediately
()
default
false
;
}
Prev
1
…
11
12
13
14
15
16
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment