package Ġnet . dbl sa iko . r sw ires . common . init Ċ Ċ import Ġnet . dbl sa iko . h ct m . common . util . deleg ated NotNull Ċ import Ġnet . dbl sa iko . h ct m . common . util . flatten Ċ import Ġnet . dbl sa iko . r sw ires . MOD _ ID Ċ import Ġnet . dbl sa iko . r sw ires . common . block . Bund led Cable Block Ċ import Ġnet . dbl sa iko . r sw ires . common . block . Ins ulated Wire Block Ċ import Ġnet . dbl sa iko . r sw ires . common . block . Red Al loy Wire Block Ċ import Ġnet . fabric mc . fabric . api .` object `. builder . v 1 . block . Fabric Block Settings Ċ import Ġnet . minecraft . block . Block Ċ import Ġnet . minecraft . block . Material Ċ import Ġnet . minecraft . util . D ye Color Ċ import Ġnet . minecraft . util . Identifier Ċ import Ġnet . minecraft . util . registry . Registry Ċ import Ġkotlin . properties . ReadOnly Property Ċ Ċ object ĠBlocks Ġ{ ĊĊĠ Ġprivate Ġval Ġtasks Ġ= Ġmutable ListOf < () Ġ-> ĠUnit >() ĊĊĠ Ġprivate Ġval ĠW I RE _ SETTINGS Ġ= ĠFabric Block Settings . of ( Material . ST ONE ) ĊĠĠĠ Ġ. break By Hand ( true ) ĊĠĠĠ Ġ. no Collision () ĊĠĠĠ Ġ. strength ( 0 . 0 5 f , Ġ 0 . 0 5 f ) ĊĊĠ Ġval ĠRED _ AL LOY _ WI RE Ġby Ġcreate (" red _ al loy _ wire ", ĠRed Al loy Wire Block ( WI RE _ SETTINGS )) ĊĠ Ġval ĠIN S UL ATED _ WI RES Ġby ĠD ye Color . values (). associate Ġ{ Ġit Ġto Ġcreate ("${ it . getName ()} _ ins ulated _ wire ", ĠIns ulated Wire Block ( WI RE _ SETTINGS , Ġit )) Ġ}. flatten () ĊĠ Ġval ĠUN CO LO RED _ B UND LED _ C ABLE Ġby Ġcreate (" bund led _ c able ", ĠBund led Cable Block ( WI RE _ SETTINGS , Ġnull )) ĊĠ Ġval ĠCO LO RED _ B UND LED _ C ABLE S Ġby ĠD ye Color . values (). associate Ġ{ Ġit Ġto Ġcreate ("${ it . getName ()} _ bund led _ c able ", ĠBund led Cable Block ( WI RE _ SETTINGS , Ġit )) Ġ}. flatten () ĊĊĠ Ġprivate Ġfun Ġ< T Ġ: ĠBlock > Ġcreate ( name : ĠString , Ġblock : ĠT ): ĠReadOnly Property < Blocks , ĠT > Ġ{ ĊĠĠĠ Ġvar Ġreg Block : ĠT ? Ġ= Ġnull ĊĠĠĠ Ġtasks Ġ+= Ġ{ Ġreg Block Ġ= ĠRegistry . register ( Registry . BLOCK , ĠIdentifier ( MOD _ ID , Ġname ), Ġblock ) Ġ} ĊĠĠĠ Ġreturn Ġdeleg ated NotNull Ġ{ Ġreg Block Ġ} ĊĠ Ġ} ĊĊĠ Ġinternal Ġfun Ġregister () Ġ{ ĊĠĠĠ Ġtasks . forEach Ġ{ Ġit () Ġ} ĊĠĠĠ Ġtasks . clear () ĊĠ Ġ} Ċ Ċ }