1use steel::*;
4
5#[repr(u8)]
6#[derive(Clone, Copy, Debug, Eq, PartialEq, num_enum::TryFromPrimitive)]
7pub enum DojosInstruction {
8 BuyStarterPack = 1,
10
11 RecruitShogunTickets = 2,
13 RecruitShogunSol = 32,
14 SeatShogun = 3,
15 SeatShogunFillAll = 41,
16 ReplaceShogun = 34,
17 Dine = 5,
18 UpgradeBarracksShards = 7,
19 UpgradeBarracksSol = 26,
20 UpgradeForge = 8,
21 MergeShogun = 9,
22 PrestigeUpgrade = 10,
23 PrestigeFodderShogun = 42,
24 ClaimShards = 11,
25 ClaimReferralReward = 12,
26 ClaimRecruitReward = 36,
27 ClaimForgeReward = 37,
28 ClaimDineReward = 38,
29 ClaimDailyReward = 39,
30 ClaimCollectionReward = 40,
31 ClaimOffChainTaskReward = 43,
32 ClaimSeekerTaskReward = 44,
33 BuyBundle = 13,
34 BuyTicketsWithShards = 22,
35 BuyFlashSale = 24,
36 ClearForgeCooldown = 15,
37 Log = 20,
38 LevelUpShogun = 25,
39 RollSceneSectionAmethyst = 27,
40 RollSceneSectionShards = 31,
41 SalvageSceneSection = 28,
42 BuyChest = 29,
43 BuyScene = 33,
44 UpdateActiveScene = 30,
45 BuySceneDojo = 35,
46
47 Initialize = 0,
49 SetGenesisSlot = 19,
50}
51
52#[repr(C)]
53#[derive(Clone, Copy, Debug, Pod, Zeroable)]
54pub struct Initialize {}
55
56#[repr(C)]
57#[derive(Clone, Copy, Debug, Pod, Zeroable)]
58pub struct BuyStarterPack {
59 pub referrer: [u8; 32], }
61
62#[repr(C)]
63#[derive(Clone, Copy, Debug, Pod, Zeroable)]
64pub struct RecruitShogunTickets {
65 pub count: [u8; 8], pub seed: [u8; 32], }
68
69#[repr(C)]
70#[derive(Clone, Copy, Debug, Pod, Zeroable)]
71pub struct RecruitShogunSol {
72 pub count: [u8; 8], pub seed: [u8; 32], }
75
76#[repr(C)]
78#[derive(Clone, Copy, Debug, Pod, Zeroable)]
79pub struct SeatShogun {
80 pub slot: [u8; 8],
81 pub rarity: [u8; 8],
82 pub element: [u8; 8],
83}
84
85#[repr(C)]
87#[derive(Clone, Copy, Debug, Pod, Zeroable)]
88pub struct SeatShogunFillAllEntry {
89 pub rarity: [u8; 8],
90 pub element: [u8; 8],
91}
92
93#[repr(C)]
95#[derive(Clone, Copy, Debug, Pod, Zeroable)]
96pub struct SeatShogunFillAll {
97 pub count: u8,
98 pub _pad: [u8; 7],
99 pub entries: [SeatShogunFillAllEntry; 12],
100}
101
102#[repr(C)]
104#[derive(Clone, Copy, Debug, Pod, Zeroable)]
105pub struct ReplaceShogun {
106 pub slot: [u8; 8],
107 pub new_rarity: [u8; 8],
108 pub new_element: [u8; 8],
109}
110
111#[repr(C)]
113#[derive(Clone, Copy, Debug, Pod, Zeroable)]
114pub struct Dine {
115 pub tier: [u8; 8],
116 pub slot: [u8; 8],
117}
118
119#[repr(C)]
120#[derive(Clone, Copy, Debug, Pod, Zeroable)]
121pub struct UpgradeBarracksShards {}
122
123#[repr(C)]
124#[derive(Clone, Copy, Debug, Pod, Zeroable)]
125pub struct UpgradeBarracksSol {}
126
127#[repr(C)]
128#[derive(Clone, Copy, Debug, Pod, Zeroable)]
129pub struct UpgradeForge {}
130
131#[repr(C)]
133#[derive(Clone, Copy, Debug, Pod, Zeroable)]
134pub struct MergeShogun {
135 pub merge_type: [u8; 8], pub seed: [u8; 32],
137}
138
139#[repr(C)]
141#[derive(Clone, Copy, Debug, Pod, Zeroable)]
142pub struct PrestigeUpgrade {
143 pub slot: [u8; 8],
144}
145
146#[repr(C)]
148#[derive(Clone, Copy, Debug, Pod, Zeroable)]
149pub struct PrestigeFodderShogun {
150 pub collection_index: u8,
152 pub _pad: [u8; 7],
153 pub from_prestige: [u8; 8],
155}
156
157#[repr(C)]
159#[derive(Clone, Copy, Debug, Pod, Zeroable)]
160pub struct LevelUpShogun {
161 pub slot: [u8; 8],
162}
163
164#[repr(C)]
165#[derive(Clone, Copy, Debug, Pod, Zeroable)]
166pub struct ClaimShards {} #[repr(C)]
169#[derive(Clone, Copy, Debug, Pod, Zeroable)]
170pub struct ClaimReferralReward {}
171
172#[repr(C)]
173#[derive(Clone, Copy, Debug, Pod, Zeroable)]
174pub struct ClaimRecruitReward {}
175
176#[repr(C)]
177#[derive(Clone, Copy, Debug, Pod, Zeroable)]
178pub struct ClaimForgeReward {}
179
180#[repr(C)]
181#[derive(Clone, Copy, Debug, Pod, Zeroable)]
182pub struct ClaimDineReward {}
183
184#[repr(C)]
185#[derive(Clone, Copy, Debug, Pod, Zeroable)]
186pub struct ClaimDailyReward {
187 pub signature: [u8; 64],
188}
189
190#[repr(C)]
191#[derive(Clone, Copy, Debug, Pod, Zeroable)]
192pub struct ClaimCollectionReward {
193 pub collection_index: u8,
195}
196
197#[repr(C)]
199#[derive(Clone, Copy, Debug, Pod, Zeroable)]
200pub struct ClaimOffChainTaskReward {
201 pub task_id: [u8; 8],
202 pub signature: [u8; 64],
203}
204
205#[repr(C)]
207#[derive(Clone, Copy, Debug, Pod, Zeroable)]
208pub struct ClaimSeekerTaskReward {}
209
210#[repr(C)]
211#[derive(Clone, Copy, Debug, Pod, Zeroable)]
212pub struct BuyBundle {} #[repr(C)]
215#[derive(Clone, Copy, Debug, Pod, Zeroable)]
216pub struct BuyTicketsWithShards {} #[repr(C)]
219#[derive(Clone, Copy, Debug, Pod, Zeroable)]
220pub struct BuyFlashSale {} #[repr(C)]
223#[derive(Clone, Copy, Debug, Pod, Zeroable)]
224pub struct ClearForgeCooldown {}
225
226#[repr(C)]
227#[derive(Clone, Copy, Debug, Pod, Zeroable)]
228pub struct SetGenesisSlot {
229 pub genesis_slot: [u8; 8],
230 pub halving_period_slots: [u8; 8],
232}
233
234#[repr(C)]
235#[derive(Clone, Copy, Debug, Pod, Zeroable)]
236pub struct Log {
237 pub _reserved: [u8; 8], }
239
240#[repr(C)]
241#[derive(Clone, Copy, Debug, Pod, Zeroable)]
242pub struct RollSceneSectionAmethyst {
243 pub count: [u8; 8], pub seed: [u8; 32], }
246
247#[repr(C)]
248#[derive(Clone, Copy, Debug, Pod, Zeroable)]
249pub struct RollSceneSectionShards {
250 pub count: [u8; 8], pub seed: [u8; 32], }
253
254#[repr(C)]
256#[derive(Clone, Copy, Debug, Pod, Zeroable)]
257pub struct SalvageSceneSection {}
258
259#[repr(C)]
260#[derive(Clone, Copy, Debug, Pod, Zeroable)]
261pub struct BuyChest {}
262
263#[repr(C)]
264#[derive(Clone, Copy, Debug, Pod, Zeroable)]
265pub struct BuyScene {
266 pub scene_id: [u8; 8], }
268
269#[repr(C)]
270#[derive(Clone, Copy, Debug, Pod, Zeroable)]
271pub struct UpdateActiveScene {
272 pub scene_id: [u8; 8],
273}
274
275#[repr(C)]
277#[derive(Clone, Copy, Debug, Pod, Zeroable)]
278pub struct BuySceneDojo {
279 pub scene_id: [u8; 8],
280}
281
282instruction!(DojosInstruction, Initialize);
283instruction!(DojosInstruction, BuyStarterPack);
284instruction!(DojosInstruction, RecruitShogunTickets);
285instruction!(DojosInstruction, RecruitShogunSol);
286instruction!(DojosInstruction, SeatShogun);
287instruction!(DojosInstruction, SeatShogunFillAll);
288instruction!(DojosInstruction, ReplaceShogun);
289instruction!(DojosInstruction, Dine);
290instruction!(DojosInstruction, UpgradeBarracksShards);
291instruction!(DojosInstruction, UpgradeBarracksSol);
292instruction!(DojosInstruction, UpgradeForge);
293instruction!(DojosInstruction, MergeShogun);
294instruction!(DojosInstruction, PrestigeUpgrade);
295instruction!(DojosInstruction, PrestigeFodderShogun);
296instruction!(DojosInstruction, ClaimShards);
297instruction!(DojosInstruction, ClaimReferralReward);
298instruction!(DojosInstruction, ClaimRecruitReward);
299instruction!(DojosInstruction, ClaimForgeReward);
300instruction!(DojosInstruction, ClaimDineReward);
301instruction!(DojosInstruction, ClaimDailyReward);
302instruction!(DojosInstruction, ClaimCollectionReward);
303instruction!(DojosInstruction, ClaimOffChainTaskReward);
304instruction!(DojosInstruction, ClaimSeekerTaskReward);
305instruction!(DojosInstruction, BuyBundle);
306instruction!(DojosInstruction, BuyTicketsWithShards);
307instruction!(DojosInstruction, BuyFlashSale);
308instruction!(DojosInstruction, ClearForgeCooldown);
309instruction!(DojosInstruction, SetGenesisSlot);
310instruction!(DojosInstruction, Log);
311instruction!(DojosInstruction, LevelUpShogun);
312instruction!(DojosInstruction, RollSceneSectionAmethyst);
313instruction!(DojosInstruction, RollSceneSectionShards);
314instruction!(DojosInstruction, SalvageSceneSection);
315instruction!(DojosInstruction, BuyChest);
316instruction!(DojosInstruction, BuyScene);
317instruction!(DojosInstruction, UpdateActiveScene);
318instruction!(DojosInstruction, BuySceneDojo);