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 ReplaceShogun = 34,
16 Dine = 5,
17 UpgradeBarracksShards = 7,
18 UpgradeBarracksSol = 26,
19 UpgradeForge = 8,
20 MergeShogun = 9,
21 PrestigeUpgrade = 10,
22 ClaimShards = 11,
23 ClaimReferralReward = 12,
24 ClaimRecruitReward = 36,
25 ClaimForgeReward = 37,
26 ClaimDineReward = 38,
27 ClaimDailyReward = 39,
28 ClaimCollectionReward = 40,
29 BuyBundle = 13,
30 BuyTicketsWithShards = 22,
31 BuyFlashSale = 24,
32 ClearForgeCooldown = 15,
33 Log = 20,
34 LevelUpShogun = 25,
35 RollSceneSectionAmethyst = 27,
36 RollSceneSectionShards = 31,
37 SalvageSceneSection = 28,
38 BuyChest = 29,
39 BuyScene = 33,
40 UpdateActiveScene = 30,
41 BuySceneDojo = 35,
42
43 Initialize = 0,
45 NewVar = 16,
46 SetGenesisSlot = 19,
47 SetVarAddress = 21,
48}
49
50#[repr(C)]
51#[derive(Clone, Copy, Debug, Pod, Zeroable)]
52pub struct Initialize {}
53
54#[repr(C)]
55#[derive(Clone, Copy, Debug, Pod, Zeroable)]
56pub struct BuyStarterPack {
57 pub referrer: [u8; 32], }
59
60#[repr(C)]
61#[derive(Clone, Copy, Debug, Pod, Zeroable)]
62pub struct RecruitShogunTickets {
63 pub count: [u8; 8], pub seed: [u8; 32], }
66
67#[repr(C)]
68#[derive(Clone, Copy, Debug, Pod, Zeroable)]
69pub struct RecruitShogunSol {
70 pub count: [u8; 8], pub seed: [u8; 32], }
73
74#[repr(C)]
75#[derive(Clone, Copy, Debug, Pod, Zeroable)]
76pub struct SeatShogun {
77 pub slot: [u8; 8],
78 pub pool_index: [u8; 8],
79}
80
81#[repr(C)]
82#[derive(Clone, Copy, Debug, Pod, Zeroable)]
83pub struct ReplaceShogun {
84 pub slot: [u8; 8],
85 pub new_pool_index: [u8; 8],
86}
87
88#[repr(C)]
89#[derive(Clone, Copy, Debug, Pod, Zeroable)]
90pub struct Dine {
91 pub tier: [u8; 8], pub pool_index: [u8; 8],
93}
94
95#[repr(C)]
96#[derive(Clone, Copy, Debug, Pod, Zeroable)]
97pub struct UpgradeBarracksShards {}
98
99#[repr(C)]
100#[derive(Clone, Copy, Debug, Pod, Zeroable)]
101pub struct UpgradeBarracksSol {}
102
103#[repr(C)]
104#[derive(Clone, Copy, Debug, Pod, Zeroable)]
105pub struct UpgradeForge {}
106
107#[repr(C)]
108#[derive(Clone, Copy, Debug, Pod, Zeroable)]
109pub struct MergeShogun {
110 pub merge_type: [u8; 8], pub pool_indices: [u64; 10],
113 pub seed: [u8; 32],
115}
116
117#[repr(C)]
118#[derive(Clone, Copy, Debug, Pod, Zeroable)]
119pub struct PrestigeUpgrade {
120 pub target_pool_index: [u8; 8],
122 pub fodder_1_pool_index: [u8; 8],
124 pub fodder_2_pool_index: [u8; 8],
126}
127
128#[repr(C)]
129#[derive(Clone, Copy, Debug, Pod, Zeroable)]
130pub struct LevelUpShogun {
131 pub pool_index: [u8; 8],
132}
133
134#[repr(C)]
135#[derive(Clone, Copy, Debug, Pod, Zeroable)]
136pub struct ClaimShards {} #[repr(C)]
139#[derive(Clone, Copy, Debug, Pod, Zeroable)]
140pub struct ClaimReferralReward {}
141
142#[repr(C)]
143#[derive(Clone, Copy, Debug, Pod, Zeroable)]
144pub struct ClaimRecruitReward {}
145
146#[repr(C)]
147#[derive(Clone, Copy, Debug, Pod, Zeroable)]
148pub struct ClaimForgeReward {}
149
150#[repr(C)]
151#[derive(Clone, Copy, Debug, Pod, Zeroable)]
152pub struct ClaimDineReward {}
153
154#[repr(C)]
155#[derive(Clone, Copy, Debug, Pod, Zeroable)]
156pub struct ClaimDailyReward {
157 pub signature: [u8; 64],
158}
159
160#[repr(C)]
161#[derive(Clone, Copy, Debug, Pod, Zeroable)]
162pub struct ClaimCollectionReward {
163 pub pool_indices: [u64; 3],
164}
165
166#[repr(C)]
167#[derive(Clone, Copy, Debug, Pod, Zeroable)]
168pub struct BuyBundle {} #[repr(C)]
171#[derive(Clone, Copy, Debug, Pod, Zeroable)]
172pub struct BuyTicketsWithShards {} #[repr(C)]
175#[derive(Clone, Copy, Debug, Pod, Zeroable)]
176pub struct BuyFlashSale {} #[repr(C)]
179#[derive(Clone, Copy, Debug, Pod, Zeroable)]
180pub struct ClearForgeCooldown {}
181
182#[repr(C)]
183#[derive(Clone, Copy, Debug, Pod, Zeroable)]
184pub struct NewVar {
185 pub id: [u8; 8],
186 pub commit: [u8; 32],
187 pub provider: [u8; 32],
188 pub end_at: [u8; 8],
189 pub samples: [u8; 8],
190 pub is_auto: [u8; 8],
191}
192
193#[repr(C)]
194#[derive(Clone, Copy, Debug, Pod, Zeroable)]
195pub struct SetGenesisSlot {
196 pub genesis_slot: [u8; 8],
197 pub halving_period_slots: [u8; 8],
199}
200
201#[repr(C)]
202#[derive(Clone, Copy, Debug, Pod, Zeroable)]
203pub struct Log {
204 pub _reserved: [u8; 8], }
206
207#[repr(C)]
208#[derive(Clone, Copy, Debug, Pod, Zeroable)]
209pub struct SetVarAddress {
210 pub entropy_var: [u8; 32],
211}
212
213#[repr(C)]
214#[derive(Clone, Copy, Debug, Pod, Zeroable)]
215pub struct RollSceneSectionAmethyst {
216 pub count: [u8; 8], pub seed: [u8; 32], }
219
220#[repr(C)]
221#[derive(Clone, Copy, Debug, Pod, Zeroable)]
222pub struct RollSceneSectionShards {
223 pub count: [u8; 8], pub seed: [u8; 32], }
226
227#[repr(C)]
230#[derive(Clone, Copy, Debug, Pod, Zeroable)]
231pub struct SalvageItem {
232 pub scene_id: u8,
233 pub section_id: u8,
234 pub count: u16,
235}
236
237#[repr(C)]
240#[derive(Clone, Copy, Debug, Pod, Zeroable)]
241pub struct SalvageSceneSection {
242 pub item_count: u8,
243 pub _pad: [u8; 3],
244 pub items: [SalvageItem; 64],
245}
246
247#[repr(C)]
248#[derive(Clone, Copy, Debug, Pod, Zeroable)]
249pub struct BuyChest {}
250
251#[repr(C)]
252#[derive(Clone, Copy, Debug, Pod, Zeroable)]
253pub struct BuyScene {
254 pub scene_id: [u8; 8], }
256
257#[repr(C)]
258#[derive(Clone, Copy, Debug, Pod, Zeroable)]
259pub struct UpdateActiveScene {
260 pub scene_id: [u8; 8],
261}
262
263#[repr(C)]
265#[derive(Clone, Copy, Debug, Pod, Zeroable)]
266pub struct BuySceneDojo {
267 pub scene_id: [u8; 8],
268}
269
270instruction!(DojosInstruction, Initialize);
271instruction!(DojosInstruction, BuyStarterPack);
272instruction!(DojosInstruction, RecruitShogunTickets);
273instruction!(DojosInstruction, RecruitShogunSol);
274instruction!(DojosInstruction, SeatShogun);
275instruction!(DojosInstruction, ReplaceShogun);
276instruction!(DojosInstruction, Dine);
277instruction!(DojosInstruction, UpgradeBarracksShards);
278instruction!(DojosInstruction, UpgradeBarracksSol);
279instruction!(DojosInstruction, UpgradeForge);
280instruction!(DojosInstruction, MergeShogun);
281instruction!(DojosInstruction, PrestigeUpgrade);
282instruction!(DojosInstruction, ClaimShards);
283instruction!(DojosInstruction, ClaimReferralReward);
284instruction!(DojosInstruction, ClaimRecruitReward);
285instruction!(DojosInstruction, ClaimForgeReward);
286instruction!(DojosInstruction, ClaimDineReward);
287instruction!(DojosInstruction, ClaimDailyReward);
288instruction!(DojosInstruction, ClaimCollectionReward);
289instruction!(DojosInstruction, BuyBundle);
290instruction!(DojosInstruction, BuyTicketsWithShards);
291instruction!(DojosInstruction, BuyFlashSale);
292instruction!(DojosInstruction, ClearForgeCooldown);
293instruction!(DojosInstruction, NewVar);
294instruction!(DojosInstruction, SetGenesisSlot);
295instruction!(DojosInstruction, Log);
296instruction!(DojosInstruction, SetVarAddress);
297instruction!(DojosInstruction, LevelUpShogun);
298instruction!(DojosInstruction, RollSceneSectionAmethyst);
299instruction!(DojosInstruction, RollSceneSectionShards);
300instruction!(DojosInstruction, SalvageSceneSection);
301instruction!(DojosInstruction, BuyChest);
302instruction!(DojosInstruction, BuyScene);
303instruction!(DojosInstruction, UpdateActiveScene);
304instruction!(DojosInstruction, BuySceneDojo);