File tree Expand file tree Collapse file tree 3 files changed +2
-59
lines changed
Expand file tree Collapse file tree 3 files changed +2
-59
lines changed Original file line number Diff line number Diff line change @@ -94,12 +94,6 @@ struct UgRandMark {
9494 file_name : String ,
9595 min : u8 ,
9696 max : u8 ,
97- smax : u8 ,
98- mmax : u8 ,
99- lmax : u8 ,
100- llmax : u8 ,
101- #[ allow( dead_code) ]
102- watermax : u8 ,
10397 typerate : Vec < u16 > ,
10498}
10599
Original file line number Diff line number Diff line change @@ -135,11 +135,6 @@ fn write_pokemon(pokemon: &Pokemon, string: &mut String) {
135135}
136136
137137fn main ( ) {
138- println ! (
139- "{:?}" ,
140- available_pokemon( Version :: BD , 6 , RoomType :: SpaciousCave )
141- ) ;
142-
143138 let cli: Cli = Cli :: parse ( ) ;
144139
145140 println ! ( "Advances: {}" , cli. advances) ;
Original file line number Diff line number Diff line change @@ -163,33 +163,6 @@ pub fn run_results(
163163 . find ( |t| t. id == room as u8 )
164164 . unwrap ( )
165165 . clone ( ) ;
166- let mut smax = rand_mark_data. smax ;
167- let mut mmax = rand_mark_data. mmax ;
168- let mut lmax = rand_mark_data. lmax ;
169- let mut llmax = rand_mark_data. llmax ;
170-
171- let mut sizes =
172- Vec :: with_capacity ( smax as usize + mmax as usize + llmax as usize + lmax as usize ) ;
173-
174- while smax > 0 {
175- sizes. push ( 0 ) ;
176- smax -= 1 ;
177- }
178-
179- while mmax > 0 {
180- sizes. push ( 1 ) ;
181- mmax -= 1 ;
182- }
183-
184- while lmax > 0 {
185- sizes. push ( 2 ) ;
186- lmax -= 1 ;
187- }
188-
189- while llmax > 0 {
190- sizes. push ( 3 ) ;
191- llmax -= 1 ;
192- }
193166
194167 let egg_move_table = serde_json:: from_str :: < TamagoWazaTable > ( TAMAGO_WAZA_TABLE ) . unwrap ( ) ;
195168 let egg_move_ignore_table =
@@ -255,27 +228,8 @@ pub fn run_results(
255228 }
256229 }
257230
258- if sizes. iter ( ) . all ( |s| exist_size_list. contains ( s) ) {
259- sizes = sizes
260- . into_iter ( )
261- . filter ( |s| !exist_size_list. contains ( s) )
262- . collect ( ) ;
263- } else {
264- sizes = sizes
265- . into_iter ( )
266- . filter ( |s| exist_size_list. contains ( s) )
267- . collect ( ) ;
268- }
269-
270- let size = if !sizes. is_empty ( ) {
271- let size_rand = clone. rand_range ( 0 , sizes. len ( ) as u32 ) ;
272- let size = sizes[ size_rand as usize ] ;
273- sizes. remove ( size_rand as usize ) ;
274- size
275- } else {
276- let size_rand = clone. rand_range ( 0 , exist_size_list. len ( ) as u32 ) ;
277- exist_size_list[ size_rand as usize ]
278- } ;
231+ let size_rand = clone. rand_range ( 0 , exist_size_list. len ( ) as u32 ) ;
232+ let size = exist_size_list[ size_rand as usize ] ;
279233
280234 poke_slots. push ( TypeAndSize {
281235 r#type,
You can’t perform that action at this time.
0 commit comments