mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-06 09:09:40 +02:00
Artifacts discharging
This commit is contained in:
@@ -916,7 +916,8 @@ struct DLL_LINKAGE GrowUpArtifact : CArtifactOperationPack
|
||||
: id(id)
|
||||
{
|
||||
}
|
||||
void applyGs(CGameState * gs) override;
|
||||
|
||||
void visitTyped(ICPackVisitor & visitor) override;
|
||||
|
||||
template <typename Handler> void serialize(Handler & h)
|
||||
{
|
||||
@@ -1022,6 +1023,27 @@ struct DLL_LINKAGE BulkMoveArtifacts : CArtifactOperationPack
|
||||
}
|
||||
};
|
||||
|
||||
struct DLL_LINKAGE DischargeArtifact : CArtifactOperationPack
|
||||
{
|
||||
ArtifactInstanceID id;
|
||||
uint16_t charges;
|
||||
|
||||
DischargeArtifact() = default;
|
||||
DischargeArtifact(const ArtifactInstanceID & id, const uint16_t charges)
|
||||
: id(id)
|
||||
, charges(charges)
|
||||
{
|
||||
}
|
||||
|
||||
void visitTyped(ICPackVisitor & visitor) override;
|
||||
|
||||
template <typename Handler> void serialize(Handler & h)
|
||||
{
|
||||
h & id;
|
||||
h & charges;
|
||||
}
|
||||
};
|
||||
|
||||
struct DLL_LINKAGE AssembledArtifact : CArtifactOperationPack
|
||||
{
|
||||
ArtifactLocation al;
|
||||
|
||||
Reference in New Issue
Block a user