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 ClaimShards = 11,
24 ClaimReferralReward = 12,
25 ClaimRecruitReward = 36,
26 ClaimForgeReward = 37,
27 ClaimDineReward = 38,
28 ClaimDailyReward = 39,
29 ClaimCollectionReward = 40,
30 BuyBundle = 13,
31 BuyTicketsWithShards = 22,
32 BuyFlashSale = 24,
33 ClearForgeCooldown = 15,
34 Log = 20,
35 LevelUpShogun = 25,
36 RollSceneSectionAmethyst = 27,
37 RollSceneSectionShards = 31,
38 SalvageSceneSection = 28,
39 BuyChest = 29,
40 BuyScene = 33,
41 UpdateActiveScene = 30,
42 BuySceneDojo = 35,
43
44 Initialize = 0,
46 SetGenesisSlot = 19,
47
48 MigrateDojo = 42,
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 LevelUpShogun {
150 pub slot: [u8; 8],
151}
152
153#[repr(C)]
154#[derive(Clone, Copy, Debug, Pod, Zeroable)]
155pub struct ClaimShards {} #[repr(C)]
158#[derive(Clone, Copy, Debug, Pod, Zeroable)]
159pub struct ClaimReferralReward {}
160
161#[repr(C)]
162#[derive(Clone, Copy, Debug, Pod, Zeroable)]
163pub struct ClaimRecruitReward {}
164
165#[repr(C)]
166#[derive(Clone, Copy, Debug, Pod, Zeroable)]
167pub struct ClaimForgeReward {}
168
169#[repr(C)]
170#[derive(Clone, Copy, Debug, Pod, Zeroable)]
171pub struct ClaimDineReward {}
172
173#[repr(C)]
174#[derive(Clone, Copy, Debug, Pod, Zeroable)]
175pub struct ClaimDailyReward {
176 pub signature: [u8; 64],
177}
178
179#[repr(C)]
180#[derive(Clone, Copy, Debug, Pod, Zeroable)]
181pub struct ClaimCollectionReward {
182 pub collection_index: u8,
184}
185
186#[repr(C)]
187#[derive(Clone, Copy, Debug, Pod, Zeroable)]
188pub struct BuyBundle {} #[repr(C)]
191#[derive(Clone, Copy, Debug, Pod, Zeroable)]
192pub struct BuyTicketsWithShards {} #[repr(C)]
195#[derive(Clone, Copy, Debug, Pod, Zeroable)]
196pub struct BuyFlashSale {} #[repr(C)]
199#[derive(Clone, Copy, Debug, Pod, Zeroable)]
200pub struct ClearForgeCooldown {}
201
202#[repr(C)]
203#[derive(Clone, Copy, Debug, Pod, Zeroable)]
204pub struct SetGenesisSlot {
205 pub genesis_slot: [u8; 8],
206 pub halving_period_slots: [u8; 8],
208}
209
210#[repr(C)]
211#[derive(Clone, Copy, Debug, Pod, Zeroable)]
212pub struct Log {
213 pub _reserved: [u8; 8], }
215
216#[repr(C)]
217#[derive(Clone, Copy, Debug, Pod, Zeroable)]
218pub struct RollSceneSectionAmethyst {
219 pub count: [u8; 8], pub seed: [u8; 32], }
222
223#[repr(C)]
224#[derive(Clone, Copy, Debug, Pod, Zeroable)]
225pub struct RollSceneSectionShards {
226 pub count: [u8; 8], pub seed: [u8; 32], }
229
230#[repr(C)]
233#[derive(Clone, Copy, Debug, Pod, Zeroable)]
234pub struct SalvageItem {
235 pub scene_id: u8,
236 pub section_id: u8,
237 pub count: u16,
238}
239
240#[repr(C)]
243#[derive(Clone, Copy, Debug, Pod, Zeroable)]
244pub struct SalvageSceneSection {
245 pub item_count: u8,
246 pub _pad: [u8; 3],
247 pub items: [SalvageItem; 64],
248}
249
250#[repr(C)]
251#[derive(Clone, Copy, Debug, Pod, Zeroable)]
252pub struct BuyChest {}
253
254#[repr(C)]
255#[derive(Clone, Copy, Debug, Pod, Zeroable)]
256pub struct BuyScene {
257 pub scene_id: [u8; 8], }
259
260#[repr(C)]
261#[derive(Clone, Copy, Debug, Pod, Zeroable)]
262pub struct UpdateActiveScene {
263 pub scene_id: [u8; 8],
264}
265
266#[repr(C)]
268#[derive(Clone, Copy, Debug, Pod, Zeroable)]
269pub struct BuySceneDojo {
270 pub scene_id: [u8; 8],
271}
272
273#[repr(C)]
275#[derive(Clone, Copy, Debug, Pod, Zeroable)]
276pub struct MigrateDojo {}
277
278instruction!(DojosInstruction, Initialize);
279instruction!(DojosInstruction, BuyStarterPack);
280instruction!(DojosInstruction, RecruitShogunTickets);
281instruction!(DojosInstruction, RecruitShogunSol);
282instruction!(DojosInstruction, SeatShogun);
283instruction!(DojosInstruction, SeatShogunFillAll);
284instruction!(DojosInstruction, ReplaceShogun);
285instruction!(DojosInstruction, Dine);
286instruction!(DojosInstruction, UpgradeBarracksShards);
287instruction!(DojosInstruction, UpgradeBarracksSol);
288instruction!(DojosInstruction, UpgradeForge);
289instruction!(DojosInstruction, MergeShogun);
290instruction!(DojosInstruction, PrestigeUpgrade);
291instruction!(DojosInstruction, ClaimShards);
292instruction!(DojosInstruction, ClaimReferralReward);
293instruction!(DojosInstruction, ClaimRecruitReward);
294instruction!(DojosInstruction, ClaimForgeReward);
295instruction!(DojosInstruction, ClaimDineReward);
296instruction!(DojosInstruction, ClaimDailyReward);
297instruction!(DojosInstruction, ClaimCollectionReward);
298instruction!(DojosInstruction, BuyBundle);
299instruction!(DojosInstruction, BuyTicketsWithShards);
300instruction!(DojosInstruction, BuyFlashSale);
301instruction!(DojosInstruction, ClearForgeCooldown);
302instruction!(DojosInstruction, SetGenesisSlot);
303instruction!(DojosInstruction, Log);
304instruction!(DojosInstruction, LevelUpShogun);
305instruction!(DojosInstruction, RollSceneSectionAmethyst);
306instruction!(DojosInstruction, RollSceneSectionShards);
307instruction!(DojosInstruction, SalvageSceneSection);
308instruction!(DojosInstruction, BuyChest);
309instruction!(DojosInstruction, BuyScene);
310instruction!(DojosInstruction, UpdateActiveScene);
311instruction!(DojosInstruction, BuySceneDojo);
312instruction!(DojosInstruction, MigrateDojo);