ETH Price: $4,305.64 (+7.17%)

Transaction Decoder

Block:
13652792 at Nov-20-2021 03:49:32 PM +UTC
Transaction Fee:
0.254408164412605 ETH $1,095.39
Gas Used:
2,287,880 Gas / 111.198211625 Gwei

Emitted Events:

38 UniswapV2Factory.PairCreated( token0=WOOL, token1=WETH9, pair=UniswapV2Pair, 2263 )
39 WOOL.Transfer( from=[Sender] 0xeea357ce1a449c6e67c86d4d3cd3691b41d68f35, to=UniswapV2Pair, value=21200000000000000000000 )
40 WOOL.Approval( owner=[Sender] 0xeea357ce1a449c6e67c86d4d3cd3691b41d68f35, spender=[Receiver] UniswapV2Router02, value=115792089237316195423570985008687907853269984665640564018257584007913129639935 )
41 WETH9.Deposit( dst=[Receiver] UniswapV2Router02, wad=800000000000000000 )
42 WETH9.Transfer( src=[Receiver] UniswapV2Router02, dst=UniswapV2Pair, wad=800000000000000000 )
43 UniswapV2Pair.Transfer( from=0x0000000000000000000000000000000000000000, to=0x0000000000000000000000000000000000000000, value=1000 )
44 UniswapV2Pair.Transfer( from=0x0000000000000000000000000000000000000000, to=[Sender] 0xeea357ce1a449c6e67c86d4d3cd3691b41d68f35, value=130230564768797650098 )
45 UniswapV2Pair.Sync( reserve0=21200000000000000000000, reserve1=800000000000000000 )
46 UniswapV2Pair.Mint( sender=[Receiver] UniswapV2Router02, amount0=21200000000000000000000, amount1=800000000000000000 )

Account State Difference:

  Address   Before After State Difference Code
0x63d364FD...956E0A324
0 Eth
Nonce: 0
0 Eth
Nonce: 1
From: 0 To: 970373714831926824185720946407840263919885073365469911651691774426946431665543512266471865775868962627047669120248256871330625770147892446909619397165810409821289694709588701323306867677257649208384978349326387418445535411191118173905878669248600552166591791127934899764776865837522151370137666890102937838273775714968403856071175813256007843767997955403679486028211556891105243817726967350283407681114102132506579105125304277564748167815342846397024705072290664688887558303342418259078870337858807302319256353732814537234856888289613708027399674335981848864884958452594500448750123709185757271799691704594825598460045237586046981286669973607497255811248054916336618770260591883114344560407110384952401173472315603951832690057890728508533745208338355059829327548814715428518717514222047513979665697375218597595236539309508342917627352671706653209120529696995353248818356303163358689521388719239190242456394183021189172097977158907875657912486338605550512879487546676611633302271475230667775383719586180157187006417919294738744302779946465631339458792305308388695808298977436244150528688722984158355049284028840226995683127551502032244556088325501540382610106837793499207544745847718703884658674971349811778799823186899170503086682057503015478989252616739182840170696904121594239897477811643131587177762472373252413961045631116709127211075498543319742453850377373997193487204507937988130627395736990058948639391539526660279803561610920474370751025762940139057313015758758177084944501064026665275431427980754256105434841498616423371358100769582975367394534305839627596757926422255187488652424989920991106699704285218110087276668191579082991838055940384641216906778353396018761511726797808610883741967942439137978054277212926284323547744109748783704275823053134686965394765704525445335194995340096279909491669098968935048953229629943910852066846595255766003226661174563949284052662117683721297660878592752685812469412066226405256310300438123619122828358311956300515948584897168820181311307515960755566624820143581320130400436732430638757868105953235466201800551590642755199648768273840591217733703620122243046325177668875516589566186636552174328659351513829282183884728262737218293545660596090969194471746871639948423418133586283866848948755311858692792320015436705816826440167723594281725277786605652770607698595900860223296437361927414376806437454204221244562486431899121071258780478379713316090152930112403133360327562653887016859083131040153889215211323340813891512208835582785595562532764709571103779102385994607473767759168295977624053955553512127361136426538721787686273453511216321239183520203588811113863626898343603784694118873851299330941956336018763877641535415884115710877740619706271918898464309749601333378501029178035189073363581003538216114898931114069302906737007051217887941611058391704483961983559785678569226084393692748550358504162988262743787900735768854607548925214343876751173683240824537308869801034098086776090912184840943364789608450108459058933828983365323127039638227524786338618000741006805641404819667044578037513628325173792992961824268689937669803599385494531623006692678868266120342454231855367906672560857809652908409078712367240635083658783854998584107465781037693112513504825080582332559347701051998974052053888576433850257906421102691284722864269704993003259908294704731616967666654167264848619972686653049260286109671848420793729709370897804926875423209863906428649310141041420009308127692597213921785490932788250583591674330356319897647747966146273898207930464771640539235830297333795401391504913652002320834613139741729368076652639464809773036076522969727659814124493464736987149809623832179451960770442040089734066312381297621879209022972801995571207352139151813089383646316351003310088139583590200672467808917264244386886686780453034140252637399180853260893922871128134433658609402748592130103963716546418725297520172944253857179183372468597190740759330590535670086374039630566975022955063170235065419296211949925273534052166004931987053298744637680011520831696542439607935300090502442438628514704477777102077986400176928856421605465129904174375972069211884462686883127713983467366860696368293716646956430672441424157258002385728282981306401694519326352934263298910982764980359652051223655655973714964833272423536068705931065645195932747891957766635776607472853023498124125964636568569512510264833392965747882773042738073847722385153647116948377688001424405819072114441606023784819011307292593178371303550296069228919741033823614181671434165165421383404767918836111241485989602761334449249466478212271691824027973863031222508351251598385598912343174008560798462069422639468405381063772605084007897065125907501478031106752086726688148537339128408569442511472471975545649657946884040962639071287276756275296263185109094564560920665709490772570679214129986144483752172595065335376963118597353944360246948948707586104853443176504880336918799957791065013022708627522814449711198702971114199024767133622346271292454993091805558177225768153096898303215097794211384523665473480643159410975016566620094591227052545319983765731532882350692747959420304224788485546890539259456085729469644680536986534637473170030708752822844772728987369817960256444094330702380885247926779415102435230803511443387105218505773040253262681523812180336520174794063087828241652218468762070586639746038321444642339626887634561153005479829608775330513173749405949716488789916381320425408414358752168817056559748812376244000590762854954314312663591755959405349006342640619098860796240062136157017719308399118564718743424013383953737720966358025713878278595430321887831137936259968296108592516513885707646624386380588008284583091803577117355591715374847170183589884461644255753143821210520303003100589083442202872479208287982760509683028047435613917926769745754618786845568335164562199183803448267307125507647424953068096864047151973851978073177428952839368627496204245025512138852305067922475400744111741971427173134495092218577816898603979675657754170230151168303366348265812641753106106772591540444252313523596780852703861172946736140246608460295875532543210426388979849381559833437039563435941549222227434569151633120212031453018819385630747722690813161762643419447206720512857089685827237039229397153740701597393287473724788562809034793328475823300677471937317677691837237894690439996426670181098526505342455729605979013749562452983747978768114552446856852023712514155703336513599427920772230682119186309321861914970213987289588275852035719372336659513573113656877618591862649326611914128580797181101364248322503230781633164186818231899634001311333258722839527336120702530738349212452416436300664085922190387117741793094198905592333357837426362099693208264568304704344967573770233806317187230870419409670937264725195884319274347207104410975884158365820401269043531976282629352504595598126046414093102768964092394311909425922966147107009361287347299428758092883122692136112630686169998346027329153711259532475731043582179362533519845870327551250060165488318315803827996089999110430800065530467920180163722884927674657200276626081910461803269368952628730875439204264162932081120527913006557957744514889818853925809011263078396276018428867706926005115509213333228605275574890553026955179599871709202395034822652888141269309109734322733264506756420204739831230530880327169751198067980692564160862893983370283465694590183203769738224718314349984179540394198676053375664759977675702219997771811838247986690461023015927827429492578944271012650006574408024585377051203614603729660654456777990209191502022990197729818969864410828865017479646361979476453851484691304981448346016038824075560134472665066664491496179478999648935490294701429779929315619388575702574357785786090451257694788109101210639982684833459404824653248740920617108408548887935240960839050302685749957466576524637031585237207339666450432711265151975751341773671998379757237804933942228055834687721941426537564376739573344032146862045259319183351508814511830286739243982365210781714974458897247497697002057154545892946110509547543471449083690747604826499673393514629399722431455689436350763458074168064888197070393968390438977228630761766093119655774395698612836974355327985124028054520638396868898892736959571058738421473425384929489113548813840860074487898330414801765855587748553806713906105440614678759954262871936381480236279852264806909516711341688548750501337587387672360221244371172177671200922024952651391556899415437579417011797401592989444457073058275514205956201848924217964835016415954656336252152856491521595231297454269241938277131439704423551330612117358046164730806832601160288390874769930872202629213600971363540576274141782381535247172155304749605615723096656469063547236276388170374855879792917902148058601928565499982491144692486083511159333922403948467825631315716451899262083934011171848498437165726363619725429738272768068275481148343272357717715150724633570307392266973671384031024725364695855198542436416424360582961266612568697466028541562876786082163927073662080043144889766409119138448855762360858613202880414776752522467635049718129289638698721065221925939135759391754085175391096464080040023095105645093813002457184029379826150339976731647337702786957691568399488647262699092137030247089786860088628392311411861836543300617935577226081902113340564338782783648633548985274420679526628794356405839072220764943487632464344256729379647295745097693846466289646792591875466815860796571268171492137772810924090844967592335574781754716685784691014495046993523459358222061397503969885568467212847294389127064062045960751855865770410518730507699373418760658333677112957244072117879293498465127102270950754390673539046312444324669390947895797211606548479473329353848576117136172619357906471019074036841450925640565889945574682536528223276622784642449667081724706674034033565494717346503769515040472385946502596541182491529408987820922111880322587337440286877512839054470637984159200451631314592617512951699433153475235051530534244418897306687989511134122202108387116023928323393685624348550174007518071030991921987960670005320336877725964006729509639764597879335793850991602353340061558978051791300636366553862753724370623567968749783743310780965036384605460691415194433689969011792973782473666950781224341315781450260035537719069704919720787263675816258532654591347236112761126400845251037826580843692724311711333112779225989883101744757245522183925999092166378829399827665359320744176108182791920430631066099517964732943588800249683483552673364253912775513166306788502375427615776030682207304558057915785891170359083003506646568939144125975464897708668342017234594621007650504231529767738963839937251500725868969894569417717880486314264631787016280709740788000085743995949795467514386081601265876195773210554156664380919010352067746586927874956968642069823898907824505385129849954983593151006664078692024277439343794964900380458144271983561819401740504889542906704033311834295862042680157208880708862945239096085854099675739746647198632047949942242766670969367007119626619843275096008868870903165501506054102277734036597006432439849426382928680483878929115980449437248303103730604604592219926788689799174953705421826252975210132506850942122495828640523632088798819600172273825009705603169474652888941308494136146681775574600873672105369458799174990461031795705196541081814131638647046005745470256316096326843752906192320328546785563701780636829801898881528702809091457681100156525220118941327671513095786900017264775058641975182773252443580703006370973152943735735742285548548294699790631541248592989241957243039395060417242697132769629526041535322521567995031721284554356733693331592393104973550169047476203721814936589454528872745901630224615442989086815050052787690939530838859133503778297474896311126790406655466517562847539984021903454365389210667011353422460804557274316638803784710865430830008710699929583983043198766622348864987925050304298262827118935540356738701427925554624732808712109260530989348886248024089487130530404851035088670778246702210209088813805811907431148698396276997459378045504728422691255167219358992301084830132326603177696930466301600864085761755561999092577471792763261997877124626854601292477204157934995386209866950649217732587631957987512932767561879105467656889358094535660718173509156619154285903745112199448970760461006993780614112378281744018991808106630713891427374272023679690978206418934655911079191164789255422133484034273841768693139752423025910110946595652958417442477329430614244980753983362977720871460234864332771053833672737385209965600946595217766006705509026335509477823549003356986161630450925451471756599928476953844115491317427518347142728294936900654063320919079169285734763420505042430799660052417974812293277574774495634371192624279092678522520750496435533666954262462791923797130294327609327848256088663585250685505553614974996756806161687704484071008834742737611940384249653338719817823413378421369601095501312144948495855539403060945885081617073278655682049319069029345671477101366796090736510647364543619064229138844873187388727093530914503627954549241832721488528113846291486541998769962403140919120192937910762917046598457816085658368084945362999807914843368403160449927534613376645197123266144917645477745760744680788271770438533853528044263031585396537896973379066873050363663459138939627619811565049002466703204632171381254017627402046149919219222020468226407743716190862780972009870633237901970906872167286590335348007321748183330880831894517946593143311518075865318361769843573639749478724865189109381609191603639419492707737523586307085883952245365881699264388059523295084962136196858877919464742499682778558150008055864043696561294304075526720560755837319200301322870360611477376950704864996348223704493049371991873583715766288717661124660410740528994164578954884549269315702207501467717456235970416775885723625865136800179170019783518699285177100551996746978063703196484468562083725332025707044434502088998828479479935003802489408559691117390918028532713442605962854364008870636177674215829292274920743064007902408674319602358727755590116931326808886237063800930049816855086360319557479555013074872388376341102936941754783044200240784242710394470642411624545509452881918665007454852507591464153777301531200239259909053527415489780939592604428584244320185608386164260830273792287943771437987254680616514172054163699428650966604299326846676724140554046037026358221667172911863956259956146392339729150490341959475539432842841141291469534887669781319320656658212488599163215819826442113023979743609333804460131078449584535247009672860018797780828507186528033076747945754492845689280056680647094379994572606617159879968580198913830564139884066633170040829394173706681535220794401477997987297977107820559276833700338101970959709324601486316626605489272080540314560766531860937959035948430083007800045007498518871400943035382833985896842761282512388069238975577827426697859409780907813757482456128103770110049604561331276909028069992448008029939400269044378012410359306419624436057392323165033306556216096491999516197862147320234261339461472875683397169521907905600043631231781545801925083891329614246023591374927606105723616711484545890671142513058556377532998707736458954171149864129939436464074335169248506525066785276675491136322415743917982962584043021663863398460998832644169959399215000217933991974541747409945961883326242580638764259996984016881380781908912159725686109466173134328173490210619158958787033625142640585491171826024862706826915229042224704272380700947928026391349311581425246007287881064209097727176917170386929944486570017097816833310615319893425627747705549542341524222988418400819813694851686348251611424033769185244888235358798548729476924616796051964418542426166888025984387570148732403732506194193958217393623861731246348752581987043707580411196754241659650238869269631716706528956281317686833691822617354461178650995225853844606121132325199558969976375822009166098747524107639013101062599029451378959339390202342582736335599652325505465353986683813946071192018081076312208629765395621209488277395784640860911514039728018066531901659516572197637400575476983162933776715620891736835679339575538095711271758873450076801737906029045336800888123127161425737942261238783698288429238591871878369623243006466420827979809623303915097870501405730419021175864637866787640746589858208013269149415851747981650993140293347620441621505600556855327715304808824122988766738348767312367920204976341982114621575157364390735118188857538091797048990788865248803972209514274999813436635362075827698706353693009242065402727925570603883194574478422993054092064842160983021821541991745086159871539488371195275996694643200450371024090799232120447690997852642261610238429040502221826879328337883986261627726469661275043050945235000486318691012267622286024896456957752092888038622148980772634110200921305608258748205519856430442107346888546461133463542594736137007567199019364607312049451945117486753334499685446808143117559430109302310294457260699168509577665465389348009093500969317952850435509882319600829023179999141813601449202487279621273466315052248272311214774245835781000744915320708917707088419286083855697539420164684989694373887539791225273805431250987945559717884299875590380599141739447481123798946068305286992390176788967266661487863056742269454724613458743877244970441960417040989608269799571037982994082675722414785707995176423374816524171512633509935054437801803310248384314285954281462633920453516986844165643310740186901428295734074251032436825760578410365476902843686484707897486327323001802570292298821730078302732901129606491355573740245413060205772816910805639747087366487474436402913952818642505822608211221231677940391464488526521617830036965405717227879288032834017163260707269715179086414548635459287296187665159532791005266513787039098259163867770236806630346145864154316664216357850431592592359357446437001032934265550512830069601314834263788955728577079168572371414522895094750990390037111638813956940038739336834117961630269344815833094571050603534124731144224664253090404674455179570848947414318901227315544465021017836111627574376422404611915266696378634541371628288275606736107092316640721239149189865613035653407405711253689628930932536948673165561694357200020411829896891576446318915146439820526504623011486554989516165667323335693414934814004410278644054000879039077833478222322272172872756103371354890899347688095119987051466357536009129562866823329151434447032893988942430150070946911349522553627858194947768274263084245629745183222615730004776379639668442725598279874930308244088933008485396959917666681610999955901665756196851949672769851203664125707554741540254559589839455890674210549613366744628250073940092320601238917734706503162753930994533684587838945685931212495222992599246372012582151929497212649486853033780275395201624953847297781180136653199208638796247411753539601271520979109694681051203539727904805097294418844970859034890974420496664672055334861261760577417100136846408252492277891862905518897820428967259414938247580001447414510879102374696398833681566184073453099383668886595163928620965172752288672765029891029325085087456675823219540845532470723299624971609531611152834905485995656999320694510613883917811326120587965945992437257752500815632041698885255900054689108235889290415209428332936722366764889127234155667730465019401160065463007229392807541321336673902417329345781330121820189416588185054182834106503659033695040889811794590145458037336891808190609892824794636329808967954256162631834596750615551750885506661417008739876427848834173792022477826960766473390684073275311664976029919411152403305472706182649305024864582120589644917212074489284683189328610953965037460607871739534360932914668243598486662868330241318289838917701751649537035731801559759342829825067798963468992656715072809773251050799601512114788075674879299224408300911146471181524820624990967218578355354523595632118493281309130872723834470866206629973887965161739406193341212336262793271639852531306838133337615718728319588810050542270596956328567969570294887381238958194557914489771335585918386940508644713954522805652967236056982078861155491811377171122930283117015403615649057864389322174134638420880929447094682133107475402227582325798127425448778476048451495428393366905468431691919308127178234473964052772617886621785434581352325198198055102133905256578806269728104359955638474987554997853220494348754346661779775947650590800195501275865742243509974608314470088293937303056528230079665296631935180049276802937989044278604178623082423213142113594479981759246054400064387201884459817337594764911691628527252625205351851767408034075053271423174343509950819755385274072523521130743043892243679459309153516863691890342691490453628793924053747111342564967146040090893591274974111127466787240729067426868324690634630052613037171225116580863468738108996853020180544491645000100174575664012894587507333228928354119713825262406933537472892720657172973712656680598385724687705359141398533994684371207343695251028367425700446320896600152962617022752618119262643853347831915167751822676880325218838130722794593790105951383826557724427909166920523335397976410875362536439098738683685984789647681920089933271389419332348794542537281522986540989318881267423868328272321517940529382711784095183479130385844905903202668137163485645250252636181922893427516074609054230102691384884727058499011448444251554567015759544508413009302584592842680906254129887071647426059491020839771430126624782157841259965956947711701654222689895616224767511443599054979604607211348567169816537828949827685467972847719691791084849022596830103592906915740960569411166874579067131092771723878155546100222088541325901052260690681040153958893918600970285548717664354906966339614995694273180466886605408349453805523472862965155943740978752213097794321902761534688209534705436678922666950115252179355448276882854139279907243975102208610580905971149150181109773352077055509317246966021606859379181045294031105163315
0x8355DBE8...FC855e525
0xC02aaA39...83C756Cc2 7,487,504.684273889549823781 Eth7,487,505.484273889549823781 Eth0.8
0xC0AEe478...cE9e4f2Ac
(SushiSwap: SushiV2Factory)
(Ethermine)
1,563.239479483478118413 Eth1,563.244055243478118413 Eth0.00457576
0xEea357CE...b41d68F35
1.209985638645130783 Eth
Nonce: 141
0.155577474232525783 Eth
Nonce: 142
1.054408164412605

Execution Trace

ETH 0.8 UniswapV2Router02.addLiquidityETH( token=0x8355DBE8B0e275ABAd27eB843F3eaF3FC855e525, amountTokenDesired=21200000000000000000000, amountTokenMin=21200000000000000000000, amountETHMin=800000000000000000, to=0xEea357CE1a449C6E67c86d4d3cD3691b41d68F35, deadline=1637425011 ) => ( amountToken=21200000000000000000000, amountETH=800000000000000000, liquidity=130230564768797650098 )
  • UniswapV2Factory.getPair( 0x8355DBE8B0e275ABAd27eB843F3eaF3FC855e525, 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2 ) => ( 0x0000000000000000000000000000000000000000 )
  • UniswapV2Factory.createPair( tokenA=0x8355DBE8B0e275ABAd27eB843F3eaF3FC855e525, tokenB=0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2 ) => ( pair=0x63d364FDaBe9D768b979249F0969f20956E0A324 )
    • UniswapV2Pair.60806040( )
    • UniswapV2Pair.initialize( _token0=0x8355DBE8B0e275ABAd27eB843F3eaF3FC855e525, _token1=0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2 )
    • UniswapV2Pair.STATICCALL( )
    • WOOL.transferFrom( sender=0xEea357CE1a449C6E67c86d4d3cD3691b41d68F35, recipient=0x63d364FDaBe9D768b979249F0969f20956E0A324, amount=21200000000000000000000 ) => ( True )
    • ETH 0.8 WETH9.CALL( )
    • WETH9.transfer( dst=0x63d364FDaBe9D768b979249F0969f20956E0A324, wad=800000000000000000 ) => ( True )
    • UniswapV2Pair.mint( to=0xEea357CE1a449C6E67c86d4d3cD3691b41d68F35 ) => ( liquidity=130230564768797650098 )
      • WOOL.balanceOf( account=0x63d364FDaBe9D768b979249F0969f20956E0A324 ) => ( 21200000000000000000000 )
      • WETH9.balanceOf( 0x63d364FDaBe9D768b979249F0969f20956E0A324 ) => ( 800000000000000000 )
      • UniswapV2Factory.STATICCALL( )
      • UniswapV2Factory.STATICCALL( )
        File 1 of 5: UniswapV2Router02
        1
        2
        3
        4
        5
        6
        7
        8
        9
        10
        11
        12
        13
        14
        15
        16
        // File: contracts/uniswapv2/interfaces/IUniswapV2Pair.sol
        pragma solidity >=0.5.0;
        interface IUniswapV2Pair {
        event Approval(address indexed owner, address indexed spender, uint value);
        event Transfer(address indexed from, address indexed to, uint value);
        function name() external pure returns (string memory);
        function symbol() external pure returns (string memory);
        function decimals() external pure returns (uint8);
        function totalSupply() external view returns (uint);
        function balanceOf(address owner) external view returns (uint);
        function allowance(address owner, address spender) external view returns (uint);
        function approve(address spender, uint value) external returns (bool);
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

        File 2 of 5: UniswapV2Factory
        1
        2
        3
        4
        5
        6
        7
        8
        9
        10
        11
        12
        13
        14
        15
        16
        // File: contracts/uniswapv2/interfaces/IUniswapV2Factory.sol
        pragma solidity >=0.5.0;
        interface IUniswapV2Factory {
        event PairCreated(address indexed token0, address indexed token1, address pair, uint);
        function feeTo() external view returns (address);
        function feeToSetter() external view returns (address);
        function migrator() external view returns (address);
        function getPair(address tokenA, address tokenB) external view returns (address pair);
        function allPairs(uint) external view returns (address pair);
        function allPairsLength() external view returns (uint);
        function createPair(address tokenA, address tokenB) external returns (address pair);
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

        File 3 of 5: UniswapV2Pair
        1
        2
        3
        4
        5
        6
        7
        8
        9
        10
        11
        12
        13
        14
        15
        16
        // File: contracts/uniswapv2/interfaces/IUniswapV2Factory.sol
        pragma solidity >=0.5.0;
        interface IUniswapV2Factory {
        event PairCreated(address indexed token0, address indexed token1, address pair, uint);
        function feeTo() external view returns (address);
        function feeToSetter() external view returns (address);
        function migrator() external view returns (address);
        function getPair(address tokenA, address tokenB) external view returns (address pair);
        function allPairs(uint) external view returns (address pair);
        function allPairsLength() external view returns (uint);
        function createPair(address tokenA, address tokenB) external returns (address pair);
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

        File 4 of 5: WOOL
        1
        {"Address.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Collection of functions related to the address
            type\n */\nlibrary Address {\n /**\n * @dev Returns true if `account` is a contract.\n *\n * [IMPORTANT]\n * ====\n * It is
            unsafe to assume that an address for which this function returns\n * false is an externally-owned account (EOA) and not a contract.\n *\n
             * Among others, `isContract` will return false for the following\n * types of addresses:\n *\n * - an externally-owned account\n
             * - a contract in construction\n * - an address where a contract will be created\n * - an address where a contract lived, but was
            destroyed\n * ====\n */\n function isContract(address account) internal view returns (bool) {\n // This method relies on
            extcodesize, which returns 0 for contracts in\n // construction, since the code is only stored at the end of the\n // constructor
            execution.\n\n uint256 size;\n assembly {\n size := extcodesize(account)\n }\n return size \u003e 0;\n
            }\n\n /**\n * @dev Replacement for Solidity\u0027s `transfer`: sends `amount` wei to\n * `recipient`, forwarding all available gas and
            reverting on errors.\n *\n * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\n * of certain opcodes, possibly
            making contracts go over the 2300 gas limit\n * imposed by `transfer`, making them unable to receive funds via\n * `transfer`. {sendValue}
            removes this limitation.\n *\n * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n *\n
             * IMPORTANT: because control is transferred to `recipient`, care must be\n * taken to not create reentrancy vulnerabilities. Consider using\n
             * {ReentrancyGuard} or the\n * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions
            -pattern[checks-effects-interactions pattern].\n */\n function sendValue(address payable recipient, uint256 amount) internal {\n
            require(address(this).balance \u003e= amount, \"Address: insufficient balance\");\n\n (bool success, ) = recipient.call{value: amount}(\"\"
            );\n require(success, \"Address: unable to send value, recipient may have reverted\");\n }\n\n /**\n * @dev Performs a Solidity
            function call using a low level `call`. A\n * plain `call` is an unsafe replacement for a function call: use this\n * function instead.\n
             *\n * If `target` reverts with a revert reason, it is bubbled up by this\n * function (like regular Solidity function calls).\n *\n
             * Returns the raw returned data. To convert to the expected return value,\n * use https://solidity.readthedocs.io/en/latest/units-and
            -global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\n *\n * Requirements:\n *\n * -
            `target` must be a contract.\n * - calling `target` with `data` must not revert.\n *\n * _Available since v3.1._\n */\n function
            functionCall(address target, bytes memory data) internal returns (bytes memory) {\n return functionCall(target, data, \"Address: low-level
            call failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\n * `errorMessage`
            as a fallback revert reason when `target` reverts.\n *\n * _Available since v3.1._\n */\n function functionCall(\n address
            target,\n bytes memory data,\n string memory errorMessage\n ) internal returns (bytes memory) {\n return
            functionCallWithValue(target, data, 0, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes
            -}[`functionCall`],\n * but also transferring `value` wei to `target`.\n *\n * Requirements:\n *\n * - the calling contract
            must have an ETH balance of at least `value`.\n * - the called Solidity function must be `payable`.\n *\n * _Available since v3.1._\n
             */\n function functionCallWithValue(\n address target,\n bytes memory data,\n uint256 value\n ) internal returns
            (bytes memory) {\n return functionCallWithValue(target, data, value, \"Address: low-level call with value failed\");\n }\n\n /**\n
             * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\n * with `errorMessage` as a fallback
            revert reason when `target` reverts.\n *\n * _Available since v3.1._\n */\n function functionCallWithValue(\n address target
            ,\n bytes memory data,\n uint256 value,\n string memory errorMessage\n ) internal returns (bytes memory) {\n require
            (address(this).balance \u003e= value, \"Address: insufficient balance for call\");\n require(isContract(target), \"Address: call to non
            -contract\");\n\n (bool success, bytes memory returndata) = target.call{value: value}(data);\n return verifyCallResult(success,
            returndata, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but
            performing a static call.\n *\n * _Available since v3.3._\n */\n function functionStaticCall(address target, bytes memory data)
            internal view returns (bytes memory) {\n return functionStaticCall(target, data, \"Address: low-level static call failed\");\n }\n\n
            /**\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n * but performing a static call.\n *\n *
            _Available since v3.3._\n */\n function functionStaticCall(\n address target,\n bytes memory data,\n string memory
            errorMessage\n ) internal view returns (bytes memory) {\n require(isContract(target), \"Address: static call to non-contract\");\n\n
             (bool success, bytes memory returndata) = target.staticcall(data);\n return verifyCallResult(success, returndata, errorMessage);\n
            }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but performing a delegate call.\n *\n
             * _Available since v3.4._\n */\n function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {\n
             return functionDelegateCall(target, data, \"Address: low-level delegate call failed\");\n }\n\n /**\n * @dev Same as {xref-Address
            -functionCall-address-bytes-string-}[`functionCall`],\n * but performing a delegate call.\n *\n * _Available since v3.4._\n */\n
             function functionDelegateCall(\n address target,\n bytes memory data,\n string memory errorMessage\n ) internal returns
            (bytes memory) {\n require(isContract(target), \"Address: delegate call to non-contract\");\n\n (bool success, bytes memory
            returndata) = target.delegatecall(data);\n return verifyCallResult(success, returndata, errorMessage);\n }\n\n /**\n * @dev Tool
            to verifies that a low level call was successful, and revert if it wasn\u0027t, either by bubbling the\n * revert reason using the provided one
            .\n *\n * _Available since v4.3._\n */\n function verifyCallResult(\n bool success,\n bytes memory returndata,\n
             string memory errorMessage\n ) internal pure returns (bytes memory) {\n if (success) {\n return returndata;\n } else
            {\n // Look for revert reason and bubble it up if present\n if (returndata.length \u003e 0) {\n // The easiest
            way to bubble the revert reason is using memory via assembly\n\n assembly {\n let returndata_size := mload
            (returndata)\n revert(add(32, returndata), returndata_size)\n }\n } else {\n revert
            (errorMessage);\n }\n }\n }\n}\n"},"Barn.sol":{"content":"// SPDX-License-Identifier: MIT LICENSE\n\npragma solidity ^0.8.0
            ;\n\nimport \"./IERC721Receiver.sol\";\nimport \"./Pausable.sol\";\nimport \"./Woolf.sol\";\nimport \"./WOOL.sol\";\n\ncontract Barn is Ownable,
            IERC721Receiver, Pausable {\n \n // maximum alpha score for a Wolf\n uint8 public constant MAX_ALPHA = 8;\n\n // struct to store a stake\u0027s
            token, owner, and earning values\n struct Stake {\n uint16 tokenId;\n uint80 value;\n address owner;\n }\n\n event TokenStaked(address
            owner, uint256 tokenId, uint256 value);\n event SheepClaimed(uint256 tokenId, uint256 earned, bool unstaked);\n event WolfClaimed(uint256 tokenId
            , uint256 earned, bool unstaked);\n\n // reference to the Woolf NFT contract\n Woolf woolf;\n // reference to the $WOOL contract for minting
            $WOOL earnings\n WOOL wool;\n\n // maps tokenId to stake\n mapping(uint256 =\u003e Stake) public barn; \n // maps alpha to all Wolf stakes with
            that alpha\n mapping(uint256 =\u003e Stake[]) public pack; \n // tracks location of each Wolf in Pack\n mapping(uint256 =\u003e uint256) public
            packIndices; \n // total alpha scores staked\n uint256 public totalAlphaStaked = 0; \n // any rewards distributed when no wolves are staked\n
            uint256 public unaccountedRewards = 0; \n // amount of $WOOL due for each alpha point staked\n uint256 public woolPerAlpha = 0; \n\n // sheep
            earn 10000 $WOOL per day\n uint256 public constant DAILY_WOOL_RATE = 10000 ether;\n // sheep must have 2 days worth of $WOOL to unstake or else
            it\u0027s too cold\n uint256 public constant MINIMUM_TO_EXIT = 2 days;\n // wolves take a 20% tax on all $WOOL claimed\n uint256 public constant
            WOOL_CLAIM_TAX_PERCENTAGE = 20;\n // there will only ever be (roughly) 2.4 billion $WOOL earned through staking\n uint256 public constant
            MAXIMUM_GLOBAL_WOOL = 2400000000 ether;\n\n // amount of $WOOL earned so far\n uint256 public totalWoolEarned;\n // number of Sheep staked in
            the Barn\n uint256 public totalSheepStaked;\n // the last time $WOOL was claimed\n uint256 public lastClaimTimestamp;\n\n // emergency rescue
            to allow unstaking without any checks but without $WOOL\n bool public rescueEnabled = false;\n\n /**\n * @param _woolf reference to the Woolf
            NFT contract\n * @param _wool reference to the $WOOL token\n */\n constructor(address _woolf, address _wool) { \n woolf = Woolf(_woolf);\n
             wool = WOOL(_wool);\n }\n\n /** STAKING */\n\n /**\n * adds Sheep and Wolves to the Barn and Pack\n * @param account the address of the
            staker\n * @param tokenIds the IDs of the Sheep and Wolves to stake\n */\n function addManyToBarnAndPack(address account, uint16[] calldata
            tokenIds) external {\n require(account == _msgSender() || _msgSender() == address(woolf), \"DONT GIVE YOUR TOKENS AWAY\");\n for (uint i = 0;
            i \u003c tokenIds.length; i++) {\n if (_msgSender() != address(woolf)) { // dont do this step if its a mint + stake\n require(woolf
            .ownerOf(tokenIds[i]) == _msgSender(), \"AINT YO TOKEN\");\n woolf.transferFrom(_msgSender(), address(this), tokenIds[i]);\n } else if
            (tokenIds[i] == 0) {\n continue; // there may be gaps in the array for stolen tokens\n }\n\n if (isSheep(tokenIds[i])) \n
            _addSheepToBarn(account, tokenIds[i]);\n else \n _addWolfToPack(account, tokenIds[i]);\n }\n }\n\n /**\n * adds a single Sheep
            to the Barn\n * @param account the address of the staker\n * @param tokenId the ID of the Sheep to add to the Barn\n */\n function
            _addSheepToBarn(address account, uint256 tokenId) internal whenNotPaused _updateEarnings {\n barn[tokenId] = Stake({\n owner: account,\n
             tokenId: uint16(tokenId),\n value: uint80(block.timestamp)\n });\n totalSheepStaked += 1;\n emit TokenStaked(account, tokenId,
            block.timestamp);\n }\n\n /**\n * adds a single Wolf to the Pack\n * @param account the address of the staker\n * @param tokenId the ID of
            the Wolf to add to the Pack\n */\n function _addWolfToPack(address account, uint256 tokenId) internal {\n uint256 alpha = _alphaForWolf
            (tokenId);\n totalAlphaStaked += alpha; // Portion of earnings ranges from 8 to 5\n packIndices[tokenId] = pack[alpha].length; // Store the
            location of the wolf in the Pack\n pack[alpha].push(Stake({\n owner: account,\n tokenId: uint16(tokenId),\n value: uint80
            (woolPerAlpha)\n })); // Add the wolf to the Pack\n emit TokenStaked(account, tokenId, woolPerAlpha);\n }\n\n /** CLAIMING / UNSTAKING
            */\n\n /**\n * realize $WOOL earnings and optionally unstake tokens from the Barn / Pack\n * to unstake a Sheep it will require it has 2 days
            worth of $WOOL unclaimed\n * @param tokenIds the IDs of the tokens to claim earnings from\n * @param unstake whether or not to unstake ALL of
            the tokens listed in tokenIds\n */\n function claimManyFromBarnAndPack(uint16[] calldata tokenIds, bool unstake) external whenNotPaused
            _updateEarnings {\n uint256 owed = 0;\n for (uint i = 0; i \u003c tokenIds.length; i++) {\n if (isSheep(tokenIds[i]))\n owed +=
            _claimSheepFromBarn(tokenIds[i], unstake);\n else\n owed += _claimWolfFromPack(tokenIds[i], unstake);\n }\n if (owed == 0) return
            ;\n wool.mint(_msgSender(), owed);\n }\n\n /**\n * realize $WOOL earnings for a single Sheep and optionally unstake it\n * if not
            unstaking, pay a 20% tax to the staked Wolves\n * if unstaking, there is a 50% chance all $WOOL is stolen\n * @param tokenId the ID of the
            Sheep to claim earnings from\n * @param unstake whether or not to unstake the Sheep\n * @return owed - the amount of $WOOL earned\n */\n
            function _claimSheepFromBarn(uint256 tokenId, bool unstake) internal returns (uint256 owed) {\n Stake memory stake = barn[tokenId];\n require
            (stake.owner == _msgSender(), \"SWIPER, NO SWIPING\");\n require(!(unstake \u0026\u0026 block.timestamp - stake.value \u003c MINIMUM_TO_EXIT),
            \"GONNA BE COLD WITHOUT TWO DAY\u0027S WOOL\");\n if (totalWoolEarned \u003c MAXIMUM_GLOBAL_WOOL) {\n owed = (block.timestamp - stake.value
            ) * DAILY_WOOL_RATE / 1 days;\n } else if (stake.value \u003e lastClaimTimestamp) {\n owed = 0; // $WOOL production stopped already\n }
            else {\n owed = (lastClaimTimestamp - stake.value) * DAILY_WOOL_RATE / 1 days; // stop earning additional $WOOL if it\u0027s all been earned\n
             }\n if (unstake) {\n if (random(tokenId) \u0026 1 == 1) { // 50% chance of all $WOOL stolen\n _payWolfTax(owed);\n owed =
            0;\n }\n woolf.safeTransferFrom(address(this), _msgSender(), tokenId, \"\"); // send back Sheep\n delete barn[tokenId];\n
            totalSheepStaked -= 1;\n } else {\n _payWolfTax(owed * WOOL_CLAIM_TAX_PERCENTAGE / 100); // percentage tax to staked wolves\n owed =
            owed * (100 - WOOL_CLAIM_TAX_PERCENTAGE) / 100; // remainder goes to Sheep owner\n barn[tokenId] = Stake({\n owner: _msgSender(),\n
             tokenId: uint16(tokenId),\n value: uint80(block.timestamp)\n }); // reset stake\n }\n emit SheepClaimed(tokenId, owed,
            unstake);\n }\n\n /**\n * realize $WOOL earnings for a single Wolf and optionally unstake it\n * Wolves earn $WOOL proportional to their
            Alpha rank\n * @param tokenId the ID of the Wolf to claim earnings from\n * @param unstake whether or not to unstake the Wolf\n * @return
            owed - the amount of $WOOL earned\n */\n function _claimWolfFromPack(uint256 tokenId, bool unstake) internal returns (uint256 owed) {\n
            require(woolf.ownerOf(tokenId) == address(this), \"AINT A PART OF THE PACK\");\n uint256 alpha = _alphaForWolf(tokenId);\n Stake memory stake
            = pack[alpha][packIndices[tokenId]];\n require(stake.owner == _msgSender(), \"SWIPER, NO SWIPING\");\n owed = (alpha) * (woolPerAlpha - stake
            .value); // Calculate portion of tokens based on Alpha\n if (unstake) {\n totalAlphaStaked -= alpha; // Remove Alpha from total staked\n
             woolf.safeTransferFrom(address(this), _msgSender(), tokenId, \"\"); // Send back Wolf\n Stake memory lastStake = pack[alpha][pack[alpha]
            .length - 1];\n pack[alpha][packIndices[tokenId]] = lastStake; // Shuffle last Wolf to current position\n packIndices[lastStake.tokenId]
            = packIndices[tokenId];\n pack[alpha].pop(); // Remove duplicate\n delete packIndices[tokenId]; // Delete old mapping\n } else {\n
             pack[alpha][packIndices[tokenId]] = Stake({\n owner: _msgSender(),\n tokenId: uint16(tokenId),\n value: uint80(woolPerAlpha
            )\n }); // reset stake\n }\n emit WolfClaimed(tokenId, owed, unstake);\n }\n\n /**\n * emergency unstake tokens\n * @param
            tokenIds the IDs of the tokens to claim earnings from\n */\n function rescue(uint256[] calldata tokenIds) external {\n require(rescueEnabled,
            \"RESCUE DISABLED\");\n uint256 tokenId;\n Stake memory stake;\n Stake memory lastStake;\n uint256 alpha;\n for (uint i = 0; i
            \u003c tokenIds.length; i++) {\n tokenId = tokenIds[i];\n if (isSheep(tokenId)) {\n stake = barn[tokenId];\n require(stake
            .owner == _msgSender(), \"SWIPER, NO SWIPING\");\n woolf.safeTransferFrom(address(this), _msgSender(), tokenId, \"\"); // send back Sheep\n
             delete barn[tokenId];\n totalSheepStaked -= 1;\n emit SheepClaimed(tokenId, 0, true);\n } else {\n alpha =
            _alphaForWolf(tokenId);\n stake = pack[alpha][packIndices[tokenId]];\n require(stake.owner == _msgSender(), \"SWIPER, NO SWIPING\"
            );\n totalAlphaStaked -= alpha; // Remove Alpha from total staked\n woolf.safeTransferFrom(address(this), _msgSender(), tokenId, \"\"
            ); // Send back Wolf\n lastStake = pack[alpha][pack[alpha].length - 1];\n pack[alpha][packIndices[tokenId]] = lastStake; // Shuffle
            last Wolf to current position\n packIndices[lastStake.tokenId] = packIndices[tokenId];\n pack[alpha].pop(); // Remove duplicate\n
             delete packIndices[tokenId]; // Delete old mapping\n emit WolfClaimed(tokenId, 0, true);\n }\n }\n }\n\n /** ACCOUNTING */\n\n
             /** \n * add $WOOL to claimable pot for the Pack\n * @param amount $WOOL to add to the pot\n */\n function _payWolfTax(uint256 amount)
            internal {\n if (totalAlphaStaked == 0) { // if there\u0027s no staked wolves\n unaccountedRewards += amount; // keep track of $WOOL due to
            wolves\n return;\n }\n // makes sure to include any unaccounted $WOOL \n woolPerAlpha += (amount + unaccountedRewards) /
            totalAlphaStaked;\n unaccountedRewards = 0;\n }\n\n /**\n * tracks $WOOL earnings to ensure it stops once 2.4 billion is eclipsed\n */\n
            modifier _updateEarnings() {\n if (totalWoolEarned \u003c MAXIMUM_GLOBAL_WOOL) {\n totalWoolEarned += \n (block.timestamp -
            lastClaimTimestamp)\n * totalSheepStaked\n * DAILY_WOOL_RATE / 1 days; \n lastClaimTimestamp = block.timestamp;\n }\n _;\n
             }\n\n /** ADMIN */\n\n /**\n * allows owner to enable \"rescue mode\"\n * simplifies accounting, prioritizes tokens out in emergency\n
            */\n function setRescueEnabled(bool _enabled) external onlyOwner {\n rescueEnabled = _enabled;\n }\n\n /**\n * enables owner to pause /
            unpause minting\n */\n function setPaused(bool _paused) external onlyOwner {\n if (_paused) _pause();\n else _unpause();\n }\n\n /**
            READ ONLY */\n\n /**\n * checks if a token is a Sheep\n * @param tokenId the ID of the token to check\n * @return sheep - whether or not a
            token is a Sheep\n */\n function isSheep(uint256 tokenId) public view returns (bool sheep) {\n (sheep, , , , , , , , , ) = woolf.tokenTraits
            (tokenId);\n }\n\n /**\n * gets the alpha score for a Wolf\n * @param tokenId the ID of the Wolf to get the alpha score for\n * @return the
            alpha score of the Wolf (5-8)\n */\n function _alphaForWolf(uint256 tokenId) internal view returns (uint8) {\n ( , , , , , , , , , uint8
            alphaIndex) = woolf.tokenTraits(tokenId);\n return MAX_ALPHA - alphaIndex; // alpha index is 0-3\n }\n\n /**\n * chooses a random Wolf thief
            when a newly minted token is stolen\n * @param seed a random value to choose a Wolf from\n * @return the owner of the randomly selected Wolf
            thief\n */\n function randomWolfOwner(uint256 seed) external view returns (address) {\n if (totalAlphaStaked == 0) return address(0x0);\n
            uint256 bucket = (seed \u0026 0xFFFFFFFF) % totalAlphaStaked; // choose a value from 0 to total alpha staked\n uint256 cumulative;\n seed
            \u003e\u003e= 32;\n // loop through each bucket of Wolves with the same alpha score\n for (uint i = MAX_ALPHA - 3; i \u003c= MAX_ALPHA; i++)
            {\n cumulative += pack[i].length * i;\n // if the value is not inside of that bucket, keep going\n if (bucket \u003e= cumulative)
            continue;\n // get the address of a random Wolf with that alpha score\n return pack[i][seed % pack[i].length].owner;\n }\n return
            address(0x0);\n }\n\n /**\n * generates a pseudorandom number\n * @param seed a value ensure different outcomes for different sources in the
            same block\n * @return a pseudorandom value\n */\n function random(uint256 seed) internal view returns (uint256) {\n return uint256
            (keccak256(abi.encodePacked(\n tx.origin,\n blockhash(block.number - 1),\n block.timestamp,\n seed\n )));\n }\n\n function
            onERC721Received(\n address,\n address from,\n uint256,\n bytes calldata\n ) external pure override returns (bytes4)
            {\n require(from == address(0x0), \"Cannot send tokens to Barn directly\");\n return IERC721Receiver.onERC721Received.selector;\n
            }\n\n \n}"},"Context.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Provides information about the
            current execution context, including the\n * sender of the transaction and its data. While these are generally available\n * via msg.sender and msg
            .data, they should not be accessed in such a direct\n * manner, since when dealing with meta-transactions the account sending and\n * paying for
            execution may not be the actual sender (as far as an application\n * is concerned).\n *\n * This contract is only required for intermediate,
            library-like contracts.\n */\nabstract contract Context {\n function _msgSender() internal view virtual returns (address) {\n return msg
            .sender;\n }\n\n function _msgData() internal view virtual returns (bytes calldata) {\n return msg.data;\n }\n}\n"},"ERC165.sol"
            :{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC165.sol\";\n\n/**\n * @dev Implementation of the
            {IERC165} interface.\n *\n * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check\n
            * for the additional interface id that will be supported. For example:\n *\n * ```solidity\n * function supportsInterface(bytes4 interfaceId)
            public view virtual override returns (bool) {\n * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId
            );\n * }\n * ```\n *\n * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.\n */\nabstract contract ERC165
            is IERC165 {\n /**\n * @dev See {IERC165-supportsInterface}.\n */\n function supportsInterface(bytes4 interfaceId) public view
            virtual override returns (bool) {\n return interfaceId == type(IERC165).interfaceId;\n }\n}\n"},"ERC20.sol":{"content":"// SPDX-License
            -Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC20.sol\";\nimport \"./IERC20Metadata.sol\";\nimport \"./Context.sol\";\n\n/**\n *
            @dev Implementation of the {IERC20} interface.\n *\n * This implementation is agnostic to the way tokens are created. This means\n * that a supply
            mechanism has to be added in a derived contract using {_mint}.\n * For a generic mechanism see {ERC20PresetMinterPauser}.\n *\n * TIP: For a
            detailed writeup see our guide\n * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How\n * to implement supply
            mechanisms].\n *\n * We have followed general OpenZeppelin Contracts guidelines: functions revert\n * instead returning `false` on failure. This
            behavior is nonetheless\n * conventional and does not conflict with the expectations of ERC20\n * applications.\n *\n * Additionally, an {Approval}
            event is emitted on calls to {transferFrom}.\n * This allows applications to reconstruct the allowance for all accounts just\n * by listening to
            said events. Other implementations of the EIP may not emit\n * these events, as it isn\u0027t required by the specification.\n *\n * Finally, the
            non-standard {decreaseAllowance} and {increaseAllowance}\n * functions have been added to mitigate the well-known issues around setting\n *
            allowances. See {IERC20-approve}.\n */\ncontract ERC20 is Context, IERC20, IERC20Metadata {\n mapping(address =\u003e uint256) private _balances
            ;\n\n mapping(address =\u003e mapping(address =\u003e uint256)) private _allowances;\n\n uint256 private _totalSupply;\n\n string private
            _name;\n string private _symbol;\n\n /**\n * @dev Sets the values for {name} and {symbol}.\n *\n * The default value of
            {decimals} is 18. To select a different value for\n * {decimals} you should overload it.\n *\n * All two of these values are immutable:
            they can only be set once during\n * construction.\n */\n constructor(string memory name_, string memory symbol_) {\n _name =
            name_;\n _symbol = symbol_;\n }\n\n /**\n * @dev Returns the name of the token.\n */\n function name() public view virtual
            override returns (string memory) {\n return _name;\n }\n\n /**\n * @dev Returns the symbol of the token, usually a shorter version
            of the\n * name.\n */\n function symbol() public view virtual override returns (string memory) {\n return _symbol;\n }\n\n
            /**\n * @dev Returns the number of decimals used to get its user representation.\n * For example, if `decimals` equals `2`, a balance of
            `505` tokens should\n * be displayed to a user as `5.05` (`505 / 10 ** 2`).\n *\n * Tokens usually opt for a value of 18, imitating the
            relationship between\n * Ether and Wei. This is the value {ERC20} uses, unless this function is\n * overridden;\n *\n * NOTE: This
            information is only used for _display_ purposes: it in\n * no way affects any of the arithmetic of the contract, including\n * {IERC20
            -balanceOf} and {IERC20-transfer}.\n */\n function decimals() public view virtual override returns (uint8) {\n return 18;\n }\n\n
             /**\n * @dev See {IERC20-totalSupply}.\n */\n function totalSupply() public view virtual override returns (uint256) {\n return
            _totalSupply;\n }\n\n /**\n * @dev See {IERC20-balanceOf}.\n */\n function balanceOf(address account) public view virtual override
            returns (uint256) {\n return _balances[account];\n }\n\n /**\n * @dev See {IERC20-transfer}.\n *\n * Requirements:\n
            *\n * - `recipient` cannot be the zero address.\n * - the caller must have a balance of at least `amount`.\n */\n function transfer
            (address recipient, uint256 amount) public virtual override returns (bool) {\n _transfer(_msgSender(), recipient, amount);\n return
            true;\n }\n\n /**\n * @dev See {IERC20-allowance}.\n */\n function allowance(address owner, address spender) public view virtual
            override returns (uint256) {\n return _allowances[owner][spender];\n }\n\n /**\n * @dev See {IERC20-approve}.\n *\n *
            Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function approve(address spender, uint256 amount) public
            virtual override returns (bool) {\n _approve(_msgSender(), spender, amount);\n return true;\n }\n\n /**\n * @dev See
            {IERC20-transferFrom}.\n *\n * Emits an {Approval} event indicating the updated allowance. This is not\n * required by the EIP. See the
            note at the beginning of {ERC20}.\n *\n * Requirements:\n *\n * - `sender` and `recipient` cannot be the zero address.\n * -
            `sender` must have a balance of at least `amount`.\n * - the caller must have allowance for ``sender``\u0027s tokens of at least\n *
            `amount`.\n */\n function transferFrom(\n address sender,\n address recipient,\n uint256 amount\n ) public virtual
            override returns (bool) {\n _transfer(sender, recipient, amount);\n\n uint256 currentAllowance = _allowances[sender][_msgSender()];\n
             require(currentAllowance \u003e= amount, \"ERC20: transfer amount exceeds allowance\");\n unchecked {\n _approve(sender,
            _msgSender(), currentAllowance - amount);\n }\n\n return true;\n }\n\n /**\n * @dev Atomically increases the allowance
            granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems
            described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n
             * - `spender` cannot be the zero address.\n */\n function increaseAllowance(address spender, uint256 addedValue) public virtual returns
            (bool) {\n _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue);\n return true;\n }\n\n /**\n *
            @dev Atomically decreases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as
            a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n
            *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n * - `spender` must have allowance for the caller of at
            least\n * `subtractedValue`.\n */\n function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool)
            {\n uint256 currentAllowance = _allowances[_msgSender()][spender];\n require(currentAllowance \u003e= subtractedValue, \"ERC20:
            decreased allowance below zero\");\n unchecked {\n _approve(_msgSender(), spender, currentAllowance - subtractedValue);\n
            }\n\n return true;\n }\n\n /**\n * @dev Moves `amount` of tokens from `sender` to `recipient`.\n *\n * This internal
            function is equivalent to {transfer}, and can be used to\n * e.g. implement automatic token fees, slashing mechanisms, etc.\n *\n *
            Emits a {Transfer} event.\n *\n * Requirements:\n *\n * - `sender` cannot be the zero address.\n * - `recipient` cannot be the
            zero address.\n * - `sender` must have a balance of at least `amount`.\n */\n function _transfer(\n address sender,\n
            address recipient,\n uint256 amount\n ) internal virtual {\n require(sender != address(0), \"ERC20: transfer from the zero
            address\");\n require(recipient != address(0), \"ERC20: transfer to the zero address\");\n\n _beforeTokenTransfer(sender, recipient,
            amount);\n\n uint256 senderBalance = _balances[sender];\n require(senderBalance \u003e= amount, \"ERC20: transfer amount exceeds
            balance\");\n unchecked {\n _balances[sender] = senderBalance - amount;\n }\n _balances[recipient] += amount;\n\n
             emit Transfer(sender, recipient, amount);\n\n _afterTokenTransfer(sender, recipient, amount);\n }\n\n /** @dev Creates `amount`
            tokens and assigns them to `account`, increasing\n * the total supply.\n *\n * Emits a {Transfer} event with `from` set to the zero
            address.\n *\n * Requirements:\n *\n * - `account` cannot be the zero address.\n */\n function _mint(address account,
            uint256 amount) internal virtual {\n require(account != address(0), \"ERC20: mint to the zero address\");\n\n _beforeTokenTransfer
            (address(0), account, amount);\n\n _totalSupply += amount;\n _balances[account] += amount;\n emit Transfer(address(0), account
            , amount);\n\n _afterTokenTransfer(address(0), account, amount);\n }\n\n /**\n * @dev Destroys `amount` tokens from `account`,
            reducing the\n * total supply.\n *\n * Emits a {Transfer} event with `to` set to the zero address.\n *\n * Requirements:\n
            *\n * - `account` cannot be the zero address.\n * - `account` must have at least `amount` tokens.\n */\n function _burn(address
            account, uint256 amount) internal virtual {\n require(account != address(0), \"ERC20: burn from the zero address\");\n\n
            _beforeTokenTransfer(account, address(0), amount);\n\n uint256 accountBalance = _balances[account];\n require(accountBalance \u003e=
            amount, \"ERC20: burn amount exceeds balance\");\n unchecked {\n _balances[account] = accountBalance - amount;\n }\n
             _totalSupply -= amount;\n\n emit Transfer(account, address(0), amount);\n\n _afterTokenTransfer(account, address(0), amount);\n
            }\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.\n *\n * This internal function is
            equivalent to `approve`, and can be used to\n * e.g. set automatic allowances for certain subsystems, etc.\n *\n * Emits an {Approval}
            event.\n *\n * Requirements:\n *\n * - `owner` cannot be the zero address.\n * - `spender` cannot be the zero address.\n
            */\n function _approve(\n address owner,\n address spender,\n uint256 amount\n ) internal virtual {\n require
            (owner != address(0), \"ERC20: approve from the zero address\");\n require(spender != address(0), \"ERC20: approve to the zero address\"
            );\n\n _allowances[owner][spender] = amount;\n emit Approval(owner, spender, amount);\n }\n\n /**\n * @dev Hook that is
            called before any transfer of tokens. This includes\n * minting and burning.\n *\n * Calling conditions:\n *\n * - when `from`
            and `to` are both non-zero, `amount` of ``from``\u0027s tokens\n * will be transferred to `to`.\n * - when `from` is zero, `amount` tokens
            will be minted for `to`.\n * - when `to` is zero, `amount` of ``from``\u0027s tokens will be burned.\n * - `from` and `to` are never both
            zero.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n function
            _beforeTokenTransfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {}\n\n /**\n * @dev Hook
            that is called after any transfer of tokens. This includes\n * minting and burning.\n *\n * Calling conditions:\n *\n * - when
            `from` and `to` are both non-zero, `amount` of ``from``\u0027s tokens\n * has been transferred to `to`.\n * - when `from` is zero, `amount`
            tokens have been minted for `to`.\n * - when `to` is zero, `amount` of ``from``\u0027s tokens have been burned.\n * - `from` and `to` are
            never both zero.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n
            function _afterTokenTransfer(\n address from,\n address to,\n uint256 amount\n ) internal virtual {}\n}\n"},"ERC721.sol"
            :{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC721.sol\";\nimport \"./IERC721Receiver.sol\";\nimport \"
            ./IERC721Metadata.sol\";\nimport \"./Address.sol\";\nimport \"./Context.sol\";\nimport \"./Strings.sol\";\nimport \"./ERC165.sol\";\n\n/**\n * @dev
            Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including\n * the Metadata extension, but not
            including the Enumerable extension, which is available separately as\n * {ERC721Enumerable}.\n */\ncontract ERC721 is Context, ERC165, IERC721,
            IERC721Metadata {\n using Address for address;\n using Strings for uint256;\n\n // Token name\n string private _name;\n\n // Token
            symbol\n string private _symbol;\n\n // Mapping from token ID to owner address\n mapping(uint256 =\u003e address) private _owners;\n\n
            // Mapping owner address to token count\n mapping(address =\u003e uint256) private _balances;\n\n // Mapping from token ID to approved
            address\n mapping(uint256 =\u003e address) private _tokenApprovals;\n\n // Mapping from owner to operator approvals\n mapping(address
            =\u003e mapping(address =\u003e bool)) private _operatorApprovals;\n\n /**\n * @dev Initializes the contract by setting a `name` and a
            `symbol` to the token collection.\n */\n constructor(string memory name_, string memory symbol_) {\n _name = name_;\n _symbol
            = symbol_;\n }\n\n /**\n * @dev See {IERC165-supportsInterface}.\n */\n function supportsInterface(bytes4 interfaceId) public view
            virtual override(ERC165, IERC165) returns (bool) {\n return\n interfaceId == type(IERC721).interfaceId ||\n
            interfaceId == type(IERC721Metadata).interfaceId ||\n super.supportsInterface(interfaceId);\n }\n\n /**\n * @dev See {IERC721
            -balanceOf}.\n */\n function balanceOf(address owner) public view virtual override returns (uint256) {\n require(owner != address(0),
            \"ERC721: balance query for the zero address\");\n return _balances[owner];\n }\n\n /**\n * @dev See {IERC721-ownerOf}.\n */\n
             function ownerOf(uint256 tokenId) public view virtual override returns (address) {\n address owner = _owners[tokenId];\n require
            (owner != address(0), \"ERC721: owner query for nonexistent token\");\n return owner;\n }\n\n /**\n * @dev See {IERC721Metadata
            -name}.\n */\n function name() public view virtual override returns (string memory) {\n return _name;\n }\n\n /**\n * @dev
            See {IERC721Metadata-symbol}.\n */\n function symbol() public view virtual override returns (string memory) {\n return _symbol;\n
            }\n\n /**\n * @dev See {IERC721Metadata-tokenURI}.\n */\n function tokenURI(uint256 tokenId) public view virtual override returns
            (string memory) {\n require(_exists(tokenId), \"ERC721Metadata: URI query for nonexistent token\");\n\n string memory baseURI =
            _baseURI();\n return bytes(baseURI).length \u003e 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : \"\";\n }\n\n /**\n
            * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each\n * token will be the concatenation of the `baseURI` and the
            `tokenId`. Empty\n * by default, can be overriden in child contracts.\n */\n function _baseURI() internal view virtual returns (string
            memory) {\n return \"\";\n }\n\n /**\n * @dev See {IERC721-approve}.\n */\n function approve(address to, uint256 tokenId)
            public virtual override {\n address owner = ERC721.ownerOf(tokenId);\n require(to != owner, \"ERC721: approval to current owner\"
            );\n\n require(\n _msgSender() == owner || isApprovedForAll(owner, _msgSender()),\n \"ERC721: approve caller is not
            owner nor approved for all\"\n );\n\n _approve(to, tokenId);\n }\n\n /**\n * @dev See {IERC721-getApproved}.\n */\n
            function getApproved(uint256 tokenId) public view virtual override returns (address) {\n require(_exists(tokenId), \"ERC721: approved query
            for nonexistent token\");\n\n return _tokenApprovals[tokenId];\n }\n\n /**\n * @dev See {IERC721-setApprovalForAll}.\n */\n
             function setApprovalForAll(address operator, bool approved) public virtual override {\n require(operator != _msgSender(), \"ERC721: approve
            to caller\");\n\n _operatorApprovals[_msgSender()][operator] = approved;\n emit ApprovalForAll(_msgSender(), operator, approved);\n
             }\n\n /**\n * @dev See {IERC721-isApprovedForAll}.\n */\n function isApprovedForAll(address owner, address operator) public view
            virtual override returns (bool) {\n return _operatorApprovals[owner][operator];\n }\n\n /**\n * @dev See {IERC721-transferFrom}.\n
             */\n function transferFrom(\n address from,\n address to,\n uint256 tokenId\n ) public virtual override {\n
            //solhint-disable-next-line max-line-length\n require(_isApprovedOrOwner(_msgSender(), tokenId), \"ERC721: transfer caller is not owner nor
            approved\");\n\n _transfer(from, to, tokenId);\n }\n\n /**\n * @dev See {IERC721-safeTransferFrom}.\n */\n function
            safeTransferFrom(\n address from,\n address to,\n uint256 tokenId\n ) public virtual override {\n safeTransferFrom
            (from, to, tokenId, \"\");\n }\n\n /**\n * @dev See {IERC721-safeTransferFrom}.\n */\n function safeTransferFrom(\n address
            from,\n address to,\n uint256 tokenId,\n bytes memory _data\n ) public virtual override {\n require
            (_isApprovedOrOwner(_msgSender(), tokenId), \"ERC721: transfer caller is not owner nor approved\");\n _safeTransfer(from, to, tokenId, _data
            );\n }\n\n /**\n * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients\n * are aware
            of the ERC721 protocol to prevent tokens from being forever locked.\n *\n * `_data` is additional data, it has no specified format and it
            is sent in call to `to`.\n *\n * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.\n * implement
            alternative mechanisms to perform token transfer, such as signature-based.\n *\n * Requirements:\n *\n * - `from` cannot be the
            zero address.\n * - `to` cannot be the zero address.\n * - `tokenId` token must exist and be owned by `from`.\n * - If `to` refers to a
            smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.\n *\n * Emits a {Transfer}
            event.\n */\n function _safeTransfer(\n address from,\n address to,\n uint256 tokenId,\n bytes memory _data\n
             ) internal virtual {\n _transfer(from, to, tokenId);\n require(_checkOnERC721Received(from, to, tokenId, _data), \"ERC721: transfer
            to non ERC721Receiver implementer\");\n }\n\n /**\n * @dev Returns whether `tokenId` exists.\n *\n * Tokens can be managed by
            their owner or approved accounts via {approve} or {setApprovalForAll}.\n *\n * Tokens start existing when they are minted (`_mint`),\n
            * and stop existing when they are burned (`_burn`).\n */\n function _exists(uint256 tokenId) internal view virtual returns (bool) {\n
             return _owners[tokenId] != address(0);\n }\n\n /**\n * @dev Returns whether `spender` is allowed to manage `tokenId`.\n *\n *
            Requirements:\n *\n * - `tokenId` must exist.\n */\n function _isApprovedOrOwner(address spender, uint256 tokenId) internal view
            virtual returns (bool) {\n require(_exists(tokenId), \"ERC721: operator query for nonexistent token\");\n address owner = ERC721
            .ownerOf(tokenId);\n return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));\n }\n\n /**\n
             * @dev Safely mints `tokenId` and transfers it to `to`.\n *\n * Requirements:\n *\n * - `tokenId` must not exist.\n * - If
            `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.\n *\n * Emits
            a {Transfer} event.\n */\n function _safeMint(address to, uint256 tokenId) internal virtual {\n _safeMint(to, tokenId, \"\");\n
            }\n\n /**\n * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is\n *
            forwarded in {IERC721Receiver-onERC721Received} to contract recipients.\n */\n function _safeMint(\n address to,\n uint256
            tokenId,\n bytes memory _data\n ) internal virtual {\n _mint(to, tokenId);\n require(\n _checkOnERC721Received
            (address(0), to, tokenId, _data),\n \"ERC721: transfer to non ERC721Receiver implementer\"\n );\n }\n\n /**\n * @dev
            Mints `tokenId` and transfers it to `to`.\n *\n * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible\n *\n
             * Requirements:\n *\n * - `tokenId` must not exist.\n * - `to` cannot be the zero address.\n *\n * Emits a {Transfer} event
            .\n */\n function _mint(address to, uint256 tokenId) internal virtual {\n require(to != address(0), \"ERC721: mint to the zero
            address\");\n require(!_exists(tokenId), \"ERC721: token already minted\");\n\n _beforeTokenTransfer(address(0), to, tokenId);\n\n
             _balances[to] += 1;\n _owners[tokenId] = to;\n\n emit Transfer(address(0), to, tokenId);\n }\n\n /**\n * @dev Destroys
            `tokenId`.\n * The approval is cleared when the token is burned.\n *\n * Requirements:\n *\n * - `tokenId` must exist.\n
            *\n * Emits a {Transfer} event.\n */\n function _burn(uint256 tokenId) internal virtual {\n address owner = ERC721.ownerOf
            (tokenId);\n\n _beforeTokenTransfer(owner, address(0), tokenId);\n\n // Clear approvals\n _approve(address(0), tokenId);\n\n
             _balances[owner] -= 1;\n delete _owners[tokenId];\n\n emit Transfer(owner, address(0), tokenId);\n }\n\n /**\n * @dev
            Transfers `tokenId` from `from` to `to`.\n * As opposed to {transferFrom}, this imposes no restrictions on msg.sender.\n *\n *
            Requirements:\n *\n * - `to` cannot be the zero address.\n * - `tokenId` token must be owned by `from`.\n *\n * Emits a
            {Transfer} event.\n */\n function _transfer(\n address from,\n address to,\n uint256 tokenId\n ) internal virtual
            {\n require(ERC721.ownerOf(tokenId) == from, \"ERC721: transfer of token that is not own\");\n require(to != address(0), \"ERC721:
            transfer to the zero address\");\n\n _beforeTokenTransfer(from, to, tokenId);\n\n // Clear approvals from the previous owner\n
             _approve(address(0), tokenId);\n\n _balances[from] -= 1;\n _balances[to] += 1;\n _owners[tokenId] = to;\n\n emit
            Transfer(from, to, tokenId);\n }\n\n /**\n * @dev Approve `to` to operate on `tokenId`\n *\n * Emits a {Approval} event.\n
            */\n function _approve(address to, uint256 tokenId) internal virtual {\n _tokenApprovals[tokenId] = to;\n emit Approval(ERC721
            .ownerOf(tokenId), to, tokenId);\n }\n\n /**\n * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address
            .\n * The call is not executed if the target address is not a contract.\n *\n * @param from address representing the previous owner of
            the given token ID\n * @param to target address that will receive the tokens\n * @param tokenId uint256 ID of the token to be transferred\n
             * @param _data bytes optional data to send along with the call\n * @return bool whether the call correctly returned the expected magic
            value\n */\n function _checkOnERC721Received(\n address from,\n address to,\n uint256 tokenId,\n bytes memory
            _data\n ) private returns (bool) {\n if (to.isContract()) {\n try IERC721Receiver(to).onERC721Received(_msgSender(), from,
            tokenId, _data) returns (bytes4 retval) {\n return retval == IERC721Receiver.onERC721Received.selector;\n } catch (bytes
            memory reason) {\n if (reason.length == 0) {\n revert(\"ERC721: transfer to non ERC721Receiver implementer\");\n
             } else {\n assembly {\n revert(add(32, reason), mload(reason))\n }\n
             }\n }\n } else {\n return true;\n }\n }\n\n /**\n * @dev Hook that is called before any
            token transfer. This includes minting\n * and burning.\n *\n * Calling conditions:\n *\n * - When `from` and `to` are both non
            -zero, ``from``\u0027s `tokenId` will be\n * transferred to `to`.\n * - When `from` is zero, `tokenId` will be minted for `to`.\n * -
            When `to` is zero, ``from``\u0027s `tokenId` will be burned.\n * - `from` and `to` are never both zero.\n *\n * To learn more about
            hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\n */\n function _beforeTokenTransfer(\n address from,\n
             address to,\n uint256 tokenId\n ) internal virtual {}\n}\n"},"ERC721Enumerable.sol":{"content":"// SPDX-License-Identifier:
            MIT\n\npragma solidity ^0.8.0;\n\nimport \"./ERC721.sol\";\nimport \"./IERC721Enumerable.sol\";\n\n/**\n * @dev This implements an optional
            extension of {ERC721} defined in the EIP that adds\n * enumerability of all the token ids in the contract as well as all token ids owned by each\n
            * account.\n */\nabstract contract ERC721Enumerable is ERC721, IERC721Enumerable {\n // Mapping from owner to list of owned token IDs\n
            mapping(address =\u003e mapping(uint256 =\u003e uint256)) private _ownedTokens;\n\n // Mapping from token ID to index of the owner tokens list\n
             mapping(uint256 =\u003e uint256) private _ownedTokensIndex;\n\n // Array with all token ids, used for enumeration\n uint256[] private
            _allTokens;\n\n // Mapping from token id to position in the allTokens array\n mapping(uint256 =\u003e uint256) private _allTokensIndex;\n\n
             /**\n * @dev See {IERC165-supportsInterface}.\n */\n function supportsInterface(bytes4 interfaceId) public view virtual override
            (IERC165, ERC721) returns (bool) {\n return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId);\n
             }\n\n /**\n * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.\n */\n function tokenOfOwnerByIndex(address owner, uint256 index)
            public view virtual override returns (uint256) {\n require(index \u003c ERC721.balanceOf(owner), \"ERC721Enumerable: owner index out of
            bounds\");\n return _ownedTokens[owner][index];\n }\n\n /**\n * @dev See {IERC721Enumerable-totalSupply}.\n */\n function
            totalSupply() public view virtual override returns (uint256) {\n return _allTokens.length;\n }\n\n /**\n * @dev See
            {IERC721Enumerable-tokenByIndex}.\n */\n function tokenByIndex(uint256 index) public view virtual override returns (uint256) {\n
            require(index \u003c ERC721Enumerable.totalSupply(), \"ERC721Enumerable: global index out of bounds\");\n return _allTokens[index];\n
            }\n\n /**\n * @dev Hook that is called before any token transfer. This includes minting\n * and burning.\n *\n * Calling
            conditions:\n *\n * - When `from` and `to` are both non-zero, ``from``\u0027s `tokenId` will be\n * transferred to `to`.\n * - When
            `from` is zero, `tokenId` will be minted for `to`.\n * - When `to` is zero, ``from``\u0027s `tokenId` will be burned.\n * - `from` cannot
            be the zero address.\n * - `to` cannot be the zero address.\n *\n * To learn more about hooks, head to xref:ROOT:extending-contracts
            .adoc#using-hooks[Using Hooks].\n */\n function _beforeTokenTransfer(\n address from,\n address to,\n uint256 tokenId\n
             ) internal virtual override {\n super._beforeTokenTransfer(from, to, tokenId);\n\n if (from == address(0)) {\n
            _addTokenToAllTokensEnumeration(tokenId);\n } else if (from != to) {\n _removeTokenFromOwnerEnumeration(from, tokenId);\n
            }\n if (to == address(0)) {\n _removeTokenFromAllTokensEnumeration(tokenId);\n } else if (to != from) {\n
            _addTokenToOwnerEnumeration(to, tokenId);\n }\n }\n\n /**\n * @dev Private function to add a token to this extension\u0027s
            ownership-tracking data structures.\n * @param to address representing the new owner of the given token ID\n * @param tokenId uint256 ID of
            the token to be added to the tokens list of the given address\n */\n function _addTokenToOwnerEnumeration(address to, uint256 tokenId)
            private {\n uint256 length = ERC721.balanceOf(to);\n _ownedTokens[to][length] = tokenId;\n _ownedTokensIndex[tokenId] = length
            ;\n }\n\n /**\n * @dev Private function to add a token to this extension\u0027s token tracking data structures.\n * @param tokenId
            uint256 ID of the token to be added to the tokens list\n */\n function _addTokenToAllTokensEnumeration(uint256 tokenId) private {\n
            _allTokensIndex[tokenId] = _allTokens.length;\n _allTokens.push(tokenId);\n }\n\n /**\n * @dev Private function to remove a token
            from this extension\u0027s ownership-tracking data structures. Note that\n * while the token is not assigned a new owner, the
            `_ownedTokensIndex` mapping is _not_ updated: this allows for\n * gas optimizations e.g. when performing a transfer operation (avoiding double
            writes).\n * This has O(1) time complexity, but alters the order of the _ownedTokens array.\n * @param from address representing the
            previous owner of the given token ID\n * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address\n
            */\n function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {\n // To prevent a gap in from\u0027s tokens array
            , we store the last token in the index of the token to delete, and\n // then delete the last slot (swap and pop).\n\n uint256
            lastTokenIndex = ERC721.balanceOf(from) - 1;\n uint256 tokenIndex = _ownedTokensIndex[tokenId];\n\n // When the token to delete is
            the last token, the swap operation is unnecessary\n if (tokenIndex != lastTokenIndex) {\n uint256 lastTokenId =
            _ownedTokens[from][lastTokenIndex];\n\n _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to
            -delete token\n _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token\u0027s index\n }\n\n // This also
            deletes the contents at the last position of the array\n delete _ownedTokensIndex[tokenId];\n delete
            _ownedTokens[from][lastTokenIndex];\n }\n\n /**\n * @dev Private function to remove a token from this extension\u0027s token tracking
            data structures.\n * This has O(1) time complexity, but alters the order of the _allTokens array.\n * @param tokenId uint256 ID of the
            token to be removed from the tokens list\n */\n function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {\n // To
            prevent a gap in the tokens array, we store the last token in the index of the token to delete, and\n // then delete the last slot (swap and
            pop).\n\n uint256 lastTokenIndex = _allTokens.length - 1;\n uint256 tokenIndex = _allTokensIndex[tokenId];\n\n // When the
            token to delete is the last token, the swap operation is unnecessary. However, since this occurs so\n // rarely (when the last minted token
            is burnt) that we still do the swap here to avoid the gas cost of adding\n // an \u0027if\u0027 statement (like in
            _removeTokenFromOwnerEnumeration)\n uint256 lastTokenId = _allTokens[lastTokenIndex];\n\n _allTokens[tokenIndex] = lastTokenId; //
            Move the last token to the slot of the to-delete token\n _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token\u0027s
            index\n\n // This also deletes the contents at the last position of the array\n delete _allTokensIndex[tokenId];\n _allTokens
            .pop();\n }\n}\n"},"IBarn.sol":{"content":"// SPDX-License-Identifier: MIT LICENSE \n\npragma solidity ^0.8.0;\n\ninterface IBarn {\n function
            addManyToBarnAndPack(address account, uint16[] calldata tokenIds) external;\n function randomWolfOwner(uint256 seed) external view returns
            (address);\n}"},"IERC165.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC165
            standard, as defined in the\n * https://eips.ethereum.org/EIPS/eip-165[EIP].\n *\n * Implementers can declare support of contract interfaces, which
            can then be\n * queried by others ({ERC165Checker}).\n *\n * For an implementation, see {ERC165}.\n */\ninterface IERC165 {\n /**\n * @dev
            Returns true if this contract implements the interface defined by\n * `interfaceId`. See the corresponding\n * https://eips.ethereum.org
            /EIPS/eip-165#how-interfaces-are-identified[EIP section]\n * to learn more about how these ids are created.\n *\n * This function call
            must use less than 30 000 gas.\n */\n function supportsInterface(bytes4 interfaceId) external view returns (bool);\n}\n"},"IERC20.sol"
            :{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP.\n
            */\ninterface IERC20 {\n /**\n * @dev Returns the amount of tokens in existence.\n */\n function totalSupply() external view returns
            (uint256);\n\n /**\n * @dev Returns the amount of tokens owned by `account`.\n */\n function balanceOf(address account) external view
            returns (uint256);\n\n /**\n * @dev Moves `amount` tokens from the caller\u0027s account to `recipient`.\n *\n * Returns a boolean
            value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transfer(address recipient,
            uint256 amount) external returns (bool);\n\n /**\n * @dev Returns the remaining number of tokens that `spender` will be\n * allowed to
            spend on behalf of `owner` through {transferFrom}. This is\n * zero by default.\n *\n * This value changes when {approve} or
            {transferFrom} are called.\n */\n function allowance(address owner, address spender) external view returns (uint256);\n\n /**\n *
            @dev Sets `amount` as the allowance of `spender` over the caller\u0027s tokens.\n *\n * Returns a boolean value indicating whether the
            operation succeeded.\n *\n * IMPORTANT: Beware that changing an allowance with this method brings the risk\n * that someone may use
            both the old and the new allowance by unfortunate\n * transaction ordering. One possible solution to mitigate this race\n * condition is to
            first reduce the spender\u0027s allowance to 0 and set the\n * desired value afterwards:\n * https://github.com/ethereum/EIPs/issues
            /20#issuecomment-263524729\n *\n * Emits an {Approval} event.\n */\n function approve(address spender, uint256 amount) external
            returns (bool);\n\n /**\n * @dev Moves `amount` tokens from `sender` to `recipient` using the\n * allowance mechanism. `amount` is then
            deducted from the caller\u0027s\n * allowance.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n
             * Emits a {Transfer} event.\n */\n function transferFrom(\n address sender,\n address recipient,\n uint256 amount\n
             ) external returns (bool);\n\n /**\n * @dev Emitted when `value` tokens are moved from one account (`from`) to\n * another (`to`).\n
             *\n * Note that `value` may be zero.\n */\n event Transfer(address indexed from, address indexed to, uint256 value);\n\n /**\n
             * @dev Emitted when the allowance of a `spender` for an `owner` is set by\n * a call to {approve}. `value` is the new allowance.\n */\n
             event Approval(address indexed owner, address indexed spender, uint256 value);\n}\n"},"IERC20Metadata.sol":{"content":"// SPDX-License-Identifier:
            MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC20.sol\";\n\n/**\n * @dev Interface for the optional metadata functions from the ERC20 standard.\n
            *\n * _Available since v4.1._\n */\ninterface IERC20Metadata is IERC20 {\n /**\n * @dev Returns the name of the token.\n */\n
            function name() external view returns (string memory);\n\n /**\n * @dev Returns the symbol of the token.\n */\n function symbol()
            external view returns (string memory);\n\n /**\n * @dev Returns the decimals places of the token.\n */\n function decimals() external
            view returns (uint8);\n}\n"},"IERC721.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC165.sol\";\n\n
            /**\n * @dev Required interface of an ERC721 compliant contract.\n */\ninterface IERC721 is IERC165 {\n /**\n * @dev Emitted when `tokenId`
            token is transferred from `from` to `to`.\n */\n event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);\n\n
            /**\n * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.\n */\n event Approval(address indexed owner, address
            indexed approved, uint256 indexed tokenId);\n\n /**\n * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all
            of its assets.\n */\n event ApprovalForAll(address indexed owner, address indexed operator, bool approved);\n\n /**\n * @dev Returns
            the number of tokens in ``owner``\u0027s account.\n */\n function balanceOf(address owner) external view returns (uint256 balance);\n\n
            /**\n * @dev Returns the owner of the `tokenId` token.\n *\n * Requirements:\n *\n * - `tokenId` must exist.\n */\n
            function ownerOf(uint256 tokenId) external view returns (address owner);\n\n /**\n * @dev Safely transfers `tokenId` token from `from` to
            `to`, checking first that contract recipients\n * are aware of the ERC721 protocol to prevent tokens from being forever locked.\n *\n *
            Requirements:\n *\n * - `from` cannot be the zero address.\n * - `to` cannot be the zero address.\n * - `tokenId` token must exist
            and be owned by `from`.\n * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or
            {setApprovalForAll}.\n * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a
            safe transfer.\n *\n * Emits a {Transfer} event.\n */\n function safeTransferFrom(\n address from,\n address to,\n
             uint256 tokenId\n ) external;\n\n /**\n * @dev Transfers `tokenId` token from `from` to `to`.\n *\n * WARNING: Usage of this
            method is discouraged, use {safeTransferFrom} whenever possible.\n *\n * Requirements:\n *\n * - `from` cannot be the zero address
            .\n * - `to` cannot be the zero address.\n * - `tokenId` token must be owned by `from`.\n * - If the caller is not `from`, it must be
            approved to move this token by either {approve} or {setApprovalForAll}.\n *\n * Emits a {Transfer} event.\n */\n function
            transferFrom(\n address from,\n address to,\n uint256 tokenId\n ) external;\n\n /**\n * @dev Gives permission to
            `to` to transfer `tokenId` token to another account.\n * The approval is cleared when the token is transferred.\n *\n * Only a single
            account can be approved at a time, so approving the zero address clears previous approvals.\n *\n * Requirements:\n *\n * - The
            caller must own the token or be an approved operator.\n * - `tokenId` must exist.\n *\n * Emits an {Approval} event.\n */\n
            function approve(address to, uint256 tokenId) external;\n\n /**\n * @dev Returns the account approved for `tokenId` token.\n *\n *
            Requirements:\n *\n * - `tokenId` must exist.\n */\n function getApproved(uint256 tokenId) external view returns (address operator
            );\n\n /**\n * @dev Approve or remove `operator` as an operator for the caller.\n * Operators can call {transferFrom} or
            {safeTransferFrom} for any token owned by the caller.\n *\n * Requirements:\n *\n * - The `operator` cannot be the caller.\n
            *\n * Emits an {ApprovalForAll} event.\n */\n function setApprovalForAll(address operator, bool _approved) external;\n\n /**\n *
            @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.\n *\n * See {setApprovalForAll}\n */\n function
            isApprovedForAll(address owner, address operator) external view returns (bool);\n\n /**\n * @dev Safely transfers `tokenId` token from
            `from` to `to`.\n *\n * Requirements:\n *\n * - `from` cannot be the zero address.\n * - `to` cannot be the zero address.\n
             * - `tokenId` token must exist and be owned by `from`.\n * - If the caller is not `from`, it must be approved to move this token by either
            {approve} or {setApprovalForAll}.\n * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is
            called upon a safe transfer.\n *\n * Emits a {Transfer} event.\n */\n function safeTransferFrom(\n address from,\n
            address to,\n uint256 tokenId,\n bytes calldata data\n ) external;\n}\n"},"IERC721Enumerable.sol":{"content":"// SPDX-License
            -Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC721.sol\";\n\n/**\n * @title ERC-721 Non-Fungible Token Standard, optional
            enumeration extension\n * @dev See https://eips.ethereum.org/EIPS/eip-721\n */\ninterface IERC721Enumerable is IERC721 {\n /**\n * @dev
            Returns the total amount of tokens stored by the contract.\n */\n function totalSupply() external view returns (uint256);\n\n /**\n *
            @dev Returns a token ID owned by `owner` at a given `index` of its token list.\n * Use along with {balanceOf} to enumerate all of
            ``owner``\u0027s tokens.\n */\n function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);\n\n
            /**\n * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.\n * Use along with {totalSupply} to enumerate
            all tokens.\n */\n function tokenByIndex(uint256 index) external view returns (uint256);\n}\n"},"IERC721Metadata.sol":{"content":"// SPDX
            -License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\nimport \"./IERC721.sol\";\n\n/**\n * @title ERC-721 Non-Fungible Token Standard, optional
            metadata extension\n * @dev See https://eips.ethereum.org/EIPS/eip-721\n */\ninterface IERC721Metadata is IERC721 {\n /**\n * @dev Returns
            the token collection name.\n */\n function name() external view returns (string memory);\n\n /**\n * @dev Returns the token
            collection symbol.\n */\n function symbol() external view returns (string memory);\n\n /**\n * @dev Returns the Uniform Resource
            Identifier (URI) for `tokenId` token.\n */\n function tokenURI(uint256 tokenId) external view returns (string memory);\n}\n"}
            ,"IERC721Receiver.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @title ERC721 token receiver interface\n *
            @dev Interface for any contract that wants to support safeTransfers\n * from ERC721 asset contracts.\n */\ninterface IERC721Receiver {\n /**\n
             * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}\n * by `operator` from `from`,
            this function is called.\n *\n * It must return its Solidity selector to confirm the token transfer.\n * If any other value is returned
            or the interface is not implemented by the recipient, the transfer will be reverted.\n *\n * The selector can be obtained in Solidity with
            `IERC721.onERC721Received.selector`.\n */\n function onERC721Received(\n address operator,\n address from,\n uint256
            tokenId,\n bytes calldata data\n ) external returns (bytes4);\n}\n"},"ITraits.sol":{"content":"// SPDX-License-Identifier: MIT LICENSE
            \n\npragma solidity ^0.8.0;\n\ninterface ITraits {\n function tokenURI(uint256 tokenId) external view returns (string memory);\n}"},"IWoolf.sol"
            :{"content":"// SPDX-License-Identifier: MIT LICENSE\n\npragma solidity ^0.8.0;\n\ninterface IWoolf {\n\n // struct to store each token\u0027s
            traits\n struct SheepWolf {\n bool isSheep;\n uint8 fur;\n uint8 head;\n uint8 ears;\n uint8 eyes;\n uint8 nose;\n uint8
            mouth;\n uint8 neck;\n uint8 feet;\n uint8 alphaIndex;\n }\n\n\n function getPaidTokens() external view returns (uint256);\n function
            getTokenTraits(uint256 tokenId) external view returns (SheepWolf memory);\n}"},"Ownable.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma
            solidity ^0.8.0;\n\nimport \"./Context.sol\";\n\n/**\n * @dev Contract module which provides a basic access control mechanism, where\n * there is
            an account (an owner) that can be granted exclusive access to\n * specific functions.\n *\n * By default, the owner account will be the one that
            deploys the contract. This\n * can later be changed with {transferOwnership}.\n *\n * This module is used through inheritance. It will make
            available the modifier\n * `onlyOwner`, which can be applied to your functions to restrict their use to\n * the owner.\n */\nabstract contract
            Ownable is Context {\n address private _owner;\n\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\n\n
             /**\n * @dev Initializes the contract setting the deployer as the initial owner.\n */\n constructor() {\n _setOwner(_msgSender
            ());\n }\n\n /**\n * @dev Returns the address of the current owner.\n */\n function owner() public view virtual returns (address)
            {\n return _owner;\n }\n\n /**\n * @dev Throws if called by any account other than the owner.\n */\n modifier onlyOwner()
            {\n require(owner() == _msgSender(), \"Ownable: caller is not the owner\");\n _;\n }\n\n /**\n * @dev Leaves the contract
            without owner. It will not be possible to call\n * `onlyOwner` functions anymore. Can only be called by the current owner.\n *\n * NOTE
            : Renouncing ownership will leave the contract without an owner,\n * thereby removing any functionality that is only available to the owner.\n
             */\n function renounceOwnership() public virtual onlyOwner {\n _setOwner(address(0));\n }\n\n /**\n * @dev Transfers
            ownership of the contract to a new account (`newOwner`).\n * Can only be called by the current owner.\n */\n function transferOwnership
            (address newOwner) public virtual onlyOwner {\n require(newOwner != address(0), \"Ownable: new owner is the zero address\");\n
            _setOwner(newOwner);\n }\n\n function _setOwner(address newOwner) private {\n address oldOwner = _owner;\n _owner = newOwner;\n
             emit OwnershipTransferred(oldOwner, newOwner);\n }\n}\n"},"Pausable.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity
            ^0.8.0;\n\nimport \"./Context.sol\";\n\n/**\n * @dev Contract module which allows children to implement an emergency stop\n * mechanism that can be
            triggered by an authorized account.\n *\n * This module is used through inheritance. It will make available the\n * modifiers `whenNotPaused` and
            `whenPaused`, which can be applied to\n * the functions of your contract. Note that they will not be pausable by\n * simply including this module,
            only once the modifiers are put in place.\n */\nabstract contract Pausable is Context {\n /**\n * @dev Emitted when the pause is triggered
            by `account`.\n */\n event Paused(address account);\n\n /**\n * @dev Emitted when the pause is lifted by `account`.\n */\n
            event Unpaused(address account);\n\n bool private _paused;\n\n /**\n * @dev Initializes the contract in unpaused state.\n */\n
            constructor() {\n _paused = false;\n }\n\n /**\n * @dev Returns true if the contract is paused, and false otherwise.\n */\n
             function paused() public view virtual returns (bool) {\n return _paused;\n }\n\n /**\n * @dev Modifier to make a function
            callable only when the contract is not paused.\n *\n * Requirements:\n *\n * - The contract must not be paused.\n */\n
            modifier whenNotPaused() {\n require(!paused(), \"Pausable: paused\");\n _;\n }\n\n /**\n * @dev Modifier to make a
            function callable only when the contract is paused.\n *\n * Requirements:\n *\n * - The contract must be paused.\n */\n
            modifier whenPaused() {\n require(paused(), \"Pausable: not paused\");\n _;\n }\n\n /**\n * @dev Triggers stopped state.\n
             *\n * Requirements:\n *\n * - The contract must not be paused.\n */\n function _pause() internal virtual whenNotPaused {\n
             _paused = true;\n emit Paused(_msgSender());\n }\n\n /**\n * @dev Returns to normal state.\n *\n * Requirements:\n
             *\n * - The contract must be paused.\n */\n function _unpause() internal virtual whenPaused {\n _paused = false;\n emit
            Unpaused(_msgSender());\n }\n}\n"},"Strings.sol":{"content":"// SPDX-License-Identifier: MIT\n\npragma solidity ^0.8.0;\n\n/**\n * @dev String
            operations.\n */\nlibrary Strings {\n bytes16 private constant _HEX_SYMBOLS = \"0123456789abcdef\";\n\n /**\n * @dev Converts a `uint256`
            to its ASCII `string` decimal representation.\n */\n function toString(uint256 value) internal pure returns (string memory) {\n //
            Inspired by OraclizeAPI\u0027s implementation - MIT licence\n // https://github.com/oraclize/ethereum-api/blob
            /b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol\n\n if (value == 0) {\n return \"0\";\n }\n
            uint256 temp = value;\n uint256 digits;\n while (temp != 0) {\n digits++;\n temp /= 10;\n }\n
            bytes memory buffer = new bytes(digits);\n while (value != 0) {\n digits -= 1;\n buffer[digits] = bytes1(uint8(48 +
            uint256(value % 10)));\n value /= 10;\n }\n return string(buffer);\n }\n\n /**\n * @dev Converts a `uint256` to
            its ASCII `string` hexadecimal representation.\n */\n function toHexString(uint256 value) internal pure returns (string memory) {\n
            if (value == 0) {\n return \"0x00\";\n }\n uint256 temp = value;\n uint256 length = 0;\n while (temp != 0)
            {\n length++;\n temp \u003e\u003e= 8;\n }\n return toHexString(value, length);\n }\n\n /**\n * @dev
            Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.\n */\n function toHexString(uint256 value, uint256
            length) internal pure returns (string memory) {\n bytes memory buffer = new bytes(2 * length + 2);\n buffer[0] = \"0\";\n
            buffer[1] = \"x\";\n for (uint256 i = 2 * length + 1; i \u003e 1; --i) {\n buffer[i] = _HEX_SYMBOLS[value \u0026 0xf];\n
             value \u003e\u003e= 4;\n }\n require(value == 0, \"Strings: hex length insufficient\");\n return string(buffer);\n
            }\n}\n"},"Traits.sol":{"content":"// SPDX-License-Identifier: MIT LICENSE\n\npragma solidity ^0.8.0;\nimport \"./Ownable.sol\";\nimport \"./Strings
            .sol\";\nimport \"./ITraits.sol\";\nimport \"./IWoolf.sol\";\n\ncontract Traits is Ownable, ITraits {\n\n using Strings for uint256;\n\n //
            struct to store each trait\u0027s data for metadata and rendering\n struct Trait {\n string name;\n string png;\n }\n\n // mapping from
            trait type (index) to its name\n string[9] _traitTypes = [\n \"Fur\",\n \"Head\",\n \"Ears\",\n \"Eyes\",\n \"Nose\",\n
            \"Mouth\",\n \"Neck\",\n \"Feet\",\n \"Alpha\"\n ];\n // storage of each traits name and base64 PNG data\n mapping(uint8 =\u003e
            mapping(uint8 =\u003e Trait)) public traitData;\n // mapping from alphaIndex to its score\n string[4] _alphas = [\n \"8\",\n \"7\",\n
            \"6\",\n \"5\"\n ];\n\n IWoolf public woolf;\n\n constructor() {}\n\n /** ADMIN */\n\n function setWoolf(address _woolf) external onlyOwner
            {\n woolf = IWoolf(_woolf);\n }\n\n /**\n * administrative to upload the names and images associated with each trait\n * @param traitType
            the trait type to upload the traits for (see traitTypes for a mapping)\n * @param traits the names and base64 encoded PNGs for each trait\n
            */\n function uploadTraits(uint8 traitType, uint8[] calldata traitIds, Trait[] calldata traits) external onlyOwner {\n require(traitIds.length
            == traits.length, \"Mismatched inputs\");\n for (uint i = 0; i \u003c traits.length; i++) {\n traitData[traitType][traitIds[i]] = Trait(\n
             traits[i].name,\n traits[i].png\n );\n }\n }\n\n /** RENDER */\n\n /**\n * generates an \u003cimage\u003e element using
            base64 encoded PNGs\n * @param trait the trait storing the PNG data\n * @return the \u003cimage\u003e element\n */\n function drawTrait
            (Trait memory trait) internal pure returns (string memory) {\n return string(abi.encodePacked(\n \u0027\u003cimage x=\"4\" y=\"4\" width
            =\"32\" height=\"32\" image-rendering=\"pixelated\" preserveAspectRatio=\"xMidYMid\" xlink:href=\"data:image/png;base64,\u0027,\n trait.png,\n
             \u0027\"/\u003e\u0027\n ));\n }\n\n /**\n * generates an entire SVG by composing multiple \u003cimage\u003e elements of PNGs\n *
            @param tokenId the ID of the token to generate an SVG for\n * @return a valid SVG of the Sheep / Wolf\n */\n function drawSVG(uint256 tokenId)
            public view returns (string memory) {\n IWoolf.SheepWolf memory s = woolf.getTokenTraits(tokenId);\n uint8 shift = s.isSheep ? 0 : 9;\n\n
            string memory svgString = string(abi.encodePacked(\n drawTrait(traitData[0 + shift][s.fur]),\n s.isSheep ? drawTrait(traitData[1 +
            shift][s.head]) : drawTrait(traitData[1 + shift][s.alphaIndex]),\n s.isSheep ? drawTrait(traitData[2 + shift][s.ears]) : \u0027\u0027,\n
            drawTrait(traitData[3 + shift][s.eyes]),\n s.isSheep ? drawTrait(traitData[4 + shift][s.nose]) : \u0027\u0027,\n drawTrait(traitData[5 +
            shift][s.mouth]),\n s.isSheep ? \u0027\u0027 : drawTrait(traitData[6 + shift][s.neck]),\n s.isSheep ? drawTrait(traitData[7 + shift][s
            .feet]) : \u0027\u0027\n ));\n\n return string(abi.encodePacked(\n \u0027\u003csvg id=\"woolf\" width=\"100%\" height=\"100%\" version
            =\"1.1\" viewBox=\"0 0 40 40\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\"\u003e\u0027,\n svgString,\n
             \"\u003c/svg\u003e\"\n ));\n }\n\n /**\n * generates an attribute for the attributes array in the ERC721 metadata standard\n * @param
            traitType the trait type to reference as the metadata key\n * @param value the token\u0027s trait associated with the key\n * @return a JSON
            dictionary for the single attribute\n */\n function attributeForTypeAndValue(string memory traitType, string memory value) internal pure returns
            (string memory) {\n return string(abi.encodePacked(\n \u0027{\"trait_type\":\"\u0027,\n traitType,\n \u0027\",\"value\":\"\u0027
            ,\n value,\n \u0027\"}\u0027\n ));\n }\n\n /**\n * generates an array composed of all the individual traits and values\n *
            @param tokenId the ID of the token to compose the metadata for\n * @return a JSON array of all of the attributes for given token ID\n */\n
            function compileAttributes(uint256 tokenId) public view returns (string memory) {\n IWoolf.SheepWolf memory s = woolf.getTokenTraits(tokenId);\n
             string memory traits;\n if (s.isSheep) {\n traits = string(abi.encodePacked(\n attributeForTypeAndValue(_traitTypes[0],
            traitData[0][s.fur].name),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[1], traitData[1][s.head].name),\u0027,\u0027,\n
            attributeForTypeAndValue(_traitTypes[2], traitData[2][s.ears].name),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[3], traitData[3][s
            .eyes].name),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[4], traitData[4][s.nose].name),\u0027,\u0027,\n
            attributeForTypeAndValue(_traitTypes[5], traitData[5][s.mouth].name),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[7],
            traitData[7][s.feet].name),\u0027,\u0027\n ));\n } else {\n traits = string(abi.encodePacked(\n attributeForTypeAndValue
            (_traitTypes[0], traitData[9][s.fur].name),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[1], traitData[10][s.alphaIndex].name
            ),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[3], traitData[12][s.eyes].name),\u0027,\u0027,\n attributeForTypeAndValue
            (_traitTypes[5], traitData[14][s.mouth].name),\u0027,\u0027,\n attributeForTypeAndValue(_traitTypes[6], traitData[15][s.neck].name),\u0027
            ,\u0027,\n attributeForTypeAndValue(\"Alpha Score\", _alphas[s.alphaIndex]),\u0027,\u0027\n ));\n }\n return string(abi
            .encodePacked(\n \u0027[\u0027,\n traits,\n \u0027{\"trait_type\":\"Generation\",\"value\":\u0027,\n tokenId \u003c= woolf
            .getPaidTokens() ? \u0027\"Gen 0\"\u0027 : \u0027\"Gen 1\"\u0027,\n \u0027},{\"trait_type\":\"Type\",\"value\":\u0027,\n s.isSheep ?
            \u0027\"Sheep\"\u0027 : \u0027\"Wolf\"\u0027,\n \u0027}]\u0027\n ));\n }\n\n /**\n * generates a base64 encoded metadata response
            without referencing off-chain content\n * @param tokenId the ID of the token to generate the metadata for\n * @return a base64 encoded JSON
            dictionary of the token\u0027s metadata and SVG\n */\n function tokenURI(uint256 tokenId) public view override returns (string memory) {\n
            IWoolf.SheepWolf memory s = woolf.getTokenTraits(tokenId);\n\n string memory metadata = string(abi.encodePacked(\n \u0027{\"name\":
            \"\u0027,\n s.isSheep ? \u0027Sheep #\u0027 : \u0027Wolf #\u0027,\n tokenId.toString(),\n \u0027\", \"description\": \"Thousands of
            Sheep and Wolves compete on a farm in the metaverse. A tempting prize of $WOOL awaits, with deadly high stakes. All the metadata and images are
            generated and stored 100% on-chain. No IPFS. NO API. Just the Ethereum blockchain.\", \"image\": \"data:image/svg+xml;base64,\u0027,\n base64
            (bytes(drawSVG(tokenId))),\n \u0027\", \"attributes\":\u0027,\n compileAttributes(tokenId),\n \"}\"\n ));\n\n return string
            (abi.encodePacked(\n \"data:application/json;base64,\",\n base64(bytes(metadata))\n ));\n }\n\n /** BASE 64 - Written by Brech Devos
            */\n \n string internal constant TABLE = \u0027ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\u0027;\n\n function base64(bytes
            memory data) internal pure returns (string memory) {\n if (data.length == 0) return \u0027\u0027;\n \n // load the table into memory\n
            string memory table = TABLE;\n\n // multiply by 4/3 rounded up\n uint256 encodedLen = 4 * ((data.length + 2) / 3);\n\n // add some extra
            buffer at the end required for the writing\n string memory result = new string(encodedLen + 32);\n\n assembly {\n // set the actual
            output length\n mstore(result, encodedLen)\n \n // prepare the lookup table\n let tablePtr := add(table, 1)\n \n //
            input ptr\n let dataPtr := data\n let endPtr := add(dataPtr, mload(data))\n \n // result ptr, jump over length\n let
            resultPtr := add(result, 32)\n \n // run over the input, 3 bytes at a time\n for {} lt(dataPtr, endPtr) {}\n {\n
            dataPtr := add(dataPtr, 3)\n \n // read 3 bytes\n let input := mload(dataPtr)\n \n // write 4
            characters\n mstore(resultPtr, shl(248, mload(add(tablePtr, and(shr(18, input), 0x3F)))))\n resultPtr := add(resultPtr, 1)\n
             mstore(resultPtr, shl(248, mload(add(tablePtr, and(shr(12, input), 0x3F)))))\n resultPtr := add(resultPtr, 1)\n mstore
            (resultPtr, shl(248, mload(add(tablePtr, and(shr( 6, input), 0x3F)))))\n resultPtr := add(resultPtr, 1)\n mstore(resultPtr, shl
            (248, mload(add(tablePtr, and( input, 0x3F)))))\n resultPtr := add(resultPtr, 1)\n }\n \n // padding with \u0027
            =\u0027\n switch mod(mload(data), 3)\n case 1 { mstore(sub(resultPtr, 2), shl(240, 0x3d3d)) }\n case 2 { mstore(sub(resultPtr, 1),
            shl(248, 0x3d)) }\n }\n \n return result;\n }\n}"},"WOOL.sol":{"content":"// SPDX-License-Identifier: MIT LICENSE\n\npragma solidity ^0.8
            .0;\nimport \"./ERC20.sol\";\nimport \"./Ownable.sol\";\n\ncontract WOOL is ERC20, Ownable {\n\n // a mapping from an address to whether or not it
            can mint / burn\n mapping(address =\u003e bool) controllers;\n \n constructor() ERC20(\"WOOL\", \"WOOL\") { }\n\n /**\n * mints $WOOL to a
            recipient\n * @param to the recipient of the $WOOL\n * @param amount the amount of $WOOL to mint\n */\n function mint(address to, uint256
            amount) external {\n require(controllers[msg.sender], \"Only controllers can mint\");\n _mint(to, amount);\n }\n\n /**\n * burns $WOOL
            from a holder\n * @param from the holder of the $WOOL\n * @param amount the amount of $WOOL to burn\n */\n function burn(address from,
            uint256 amount) external {\n require(controllers[msg.sender], \"Only controllers can burn\");\n _burn(from, amount);\n }\n\n /**\n *
            enables an address to mint / burn\n * @param controller the address to enable\n */\n function addController(address controller) external
            onlyOwner {\n controllers[controller] = true;\n }\n\n /**\n * disables an address from minting / burning\n * @param controller the address
            to disbale\n */\n function removeController(address controller) external onlyOwner {\n controllers[controller] = false;\n }\n}"},"Woolf.sol"
            :{"content":"// SPDX-License-Identifier: MIT LICENSE\n\npragma solidity ^0.8.0;\nimport \"./Ownable.sol\";\nimport \"./Pausable.sol\";\nimport \"
            ./ERC721Enumerable.sol\";\nimport \"./IWoolf.sol\";\nimport \"./IBarn.sol\";\nimport \"./ITraits.sol\";\nimport \"./WOOL.sol\";\n\n\ncontract Woolf
            is IWoolf, ERC721Enumerable, Ownable, Pausable {\n\n // mint price\n uint256 public constant MINT_PRICE = .069420 ether;\n // max number of
            tokens that can be minted - 50000 in production\n uint256 public immutable MAX_TOKENS;\n // number of tokens that can be claimed for free - 20%
            of MAX_TOKENS\n uint256 public PAID_TOKENS;\n // number of tokens have been minted so far\n uint16 public minted;\n\n // mapping from tokenId
            to a struct containing the token\u0027s traits\n mapping(uint256 =\u003e SheepWolf) public tokenTraits;\n // mapping from hashed(tokenTrait) to
            the tokenId it\u0027s associated with\n // used to ensure there are no duplicates\n mapping(uint256 =\u003e uint256) public existingCombinations
            ;\n\n // list of probabilities for each trait type\n // 0 - 9 are associated with Sheep, 10 - 18 are associated with Wolves\n uint8[][18] public
            rarities;\n // list of aliases for Walker\u0027s Alias algorithm\n // 0 - 9 are associated with Sheep, 10 - 18 are associated with Wolves\n
            uint8[][18] public aliases;\n\n // reference to the Barn for choosing random Wolf thieves\n IBarn public barn;\n // reference to $WOOL for
            burning on mint\n WOOL public wool;\n // reference to Traits\n ITraits public traits;\n\n /** \n * instantiates contract and rarity tables\n
             */\n constructor(address _wool, address _traits, uint256 _maxTokens) ERC721(\"Wolf Game\", \u0027WGAME\u0027) { \n wool = WOOL(_wool);\n
            traits = ITraits(_traits);\n MAX_TOKENS = _maxTokens;\n PAID_TOKENS = _maxTokens / 5;\n\n // I know this looks weird but it saves users
            gas by making lookup O(1)\n // A.J. Walker\u0027s Alias Algorithm\n // sheep\n // fur\n rarities[0] = [15, 50, 200, 250, 255];\n
            aliases[0] = [4, 4, 4, 4, 4];\n // head\n rarities[1] = [190, 215, 240, 100, 110, 135, 160, 185, 80, 210, 235, 240, 80, 80, 100, 100, 100,
            245, 250, 255];\n aliases[1] = [1, 2, 4, 0, 5, 6, 7, 9, 0, 10, 11, 17, 0, 0, 0, 0, 4, 18, 19, 19];\n // ears\n rarities[2] = [255, 30, 60
            , 60, 150, 156];\n aliases[2] = [0, 0, 0, 0, 0, 0];\n // eyes\n rarities[3] = [221, 100, 181, 140, 224, 147, 84, 228, 140, 224, 250, 160,
            241, 207, 173, 84, 254, 220, 196, 140, 168, 252, 140, 183, 236, 252, 224, 255];\n aliases[3] = [1, 2, 5, 0, 1, 7, 1, 10, 5, 10, 11, 12, 13, 14,
            16, 11, 17, 23, 13, 14, 17, 23, 23, 24, 27, 27, 27, 27];\n // nose\n rarities[4] = [175, 100, 40, 250, 115, 100, 185, 175, 180, 255];\n
            aliases[4] = [3, 0, 4, 6, 6, 7, 8, 8, 9, 9];\n // mouth\n rarities[5] = [80, 225, 227, 228, 112, 240, 64, 160, 167, 217, 171, 64, 240, 126,
            80, 255];\n aliases[5] = [1, 2, 3, 8, 2, 8, 8, 9, 9, 10, 13, 10, 13, 15, 13, 15];\n // neck\n rarities[6] = [255];\n aliases[6] = [0]
            ;\n // feet\n rarities[7] = [243, 189, 133, 133, 57, 95, 152, 135, 133, 57, 222, 168, 57, 57, 38, 114, 114, 114, 255];\n aliases[7] = [1,
            7, 0, 0, 0, 0, 0, 10, 0, 0, 11, 18, 0, 0, 0, 1, 7, 11, 18];\n // alphaIndex\n rarities[8] = [255];\n aliases[8] = [0];\n\n // wolves\n
             // fur\n rarities[9] = [210, 90, 9, 9, 9, 150, 9, 255, 9];\n aliases[9] = [5, 0, 0, 5, 5, 7, 5, 7, 5];\n // head\n rarities[10] =
            [255];\n aliases[10] = [0];\n // ears\n rarities[11] = [255];\n aliases[11] = [0];\n // eyes\n rarities[12] = [135, 177, 219, 141
            , 183, 225, 147, 189, 231, 135, 135, 135, 135, 246, 150, 150, 156, 165, 171, 180, 186, 195, 201, 210, 243, 252, 255];\n aliases[12] = [1, 2, 3,
            4, 5, 6, 7, 8, 13, 3, 6, 14, 15, 16, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 26, 26];\n // nose\n rarities[13] = [255];\n aliases[13]
            = [0];\n // mouth\n rarities[14] = [239, 244, 249, 234, 234, 234, 234, 234, 234, 234, 130, 255, 247];\n aliases[14] = [1, 2, 11, 0, 11, 11
            , 11, 11, 11, 11, 11, 11, 11];\n // neck\n rarities[15] = [75, 180, 165, 120, 60, 150, 105, 195, 45, 225, 75, 45, 195, 120, 255];\n
            aliases[15] = [1, 9, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 14, 12, 14];\n // feet \n rarities[16] = [255];\n aliases[16] = [0];\n //
            alphaIndex\n rarities[17] = [8, 160, 73, 255]; \n aliases[17] = [2, 3, 3, 3];\n }\n\n /** EXTERNAL */\n\n /** \n * mint a token - 90%
            Sheep, 10% Wolves\n * The first 20% are free to claim, the remaining cost $WOOL\n */\n function mint(uint256 amount, bool stake) external
            payable whenNotPaused {\n require(tx.origin == _msgSender(), \"Only EOA\");\n require(minted + amount \u003c= MAX_TOKENS, \"All tokens
            minted\");\n require(amount \u003e 0 \u0026\u0026 amount \u003c= 10, \"Invalid mint amount\");\n if (minted \u003c PAID_TOKENS) {\n
            require(minted + amount \u003c= PAID_TOKENS, \"All tokens on-sale already sold\");\n require(amount * MINT_PRICE == msg.value, \"Invalid
            payment amount\");\n } else {\n require(msg.value == 0);\n }\n\n uint256 totalWoolCost = 0;\n uint16[] memory tokenIds = stake ?
            new uint16[](amount) : new uint16[](0);\n uint256 seed;\n for (uint i = 0; i \u003c amount; i++) {\n minted++;\n seed = random
            (minted);\n generate(minted, seed);\n address recipient = selectRecipient(seed);\n if (!stake || recipient != _msgSender()) {\n
             _safeMint(recipient, minted);\n } else {\n _safeMint(address(barn), minted);\n tokenIds[i] = minted;\n }\n
            totalWoolCost += mintCost(minted);\n }\n \n if (totalWoolCost \u003e 0) wool.burn(_msgSender(), totalWoolCost);\n if (stake) barn
            .addManyToBarnAndPack(_msgSender(), tokenIds);\n }\n\n /** \n * the first 20% are paid in ETH\n * the next 20% are 20000 $WOOL\n * the next
            40% are 40000 $WOOL\n * the final 20% are 80000 $WOOL\n * @param tokenId the ID to check the cost of to mint\n * @return the cost of the
            given token ID\n */\n function mintCost(uint256 tokenId) public view returns (uint256) {\n if (tokenId \u003c= PAID_TOKENS) return 0;\n if
            (tokenId \u003c= MAX_TOKENS * 2 / 5) return 20000 ether;\n if (tokenId \u003c= MAX_TOKENS * 4 / 5) return 40000 ether;\n return 80000 ether
            ;\n }\n\n function transferFrom(\n address from,\n address to,\n uint256 tokenId\n ) public virtual override {\n // Hardcode the
            Barn\u0027s approval so that users don\u0027t have to waste gas approving\n if (_msgSender() != address(barn))\n require(_isApprovedOrOwner
            (_msgSender(), tokenId), \"ERC721: transfer caller is not owner nor approved\");\n _transfer(from, to, tokenId);\n }\n\n /** INTERNAL */\n\n
            /**\n * generates traits for a specific token, checking to make sure it\u0027s unique\n * @param tokenId the id of the token to generate traits
            for\n * @param seed a pseudorandom 256 bit number to derive traits from\n * @return t - a struct of traits for the given token ID\n */\n
            function generate(uint256 tokenId, uint256 seed) internal returns (SheepWolf memory t) {\n t = selectTraits(seed);\n if
            (existingCombinations[structToHash(t)] == 0) {\n tokenTraits[tokenId] = t;\n existingCombinations[structToHash(t)] = tokenId;\n
            return t;\n }\n return generate(tokenId, random(seed));\n }\n\n /**\n * uses A.J. Walker\u0027s Alias algorithm for O(1) rarity table
            lookup\n * ensuring O(1) instead of O(n) reduces mint cost by more than 50%\n * probability \u0026 alias tables are generated off-chain
            beforehand\n * @param seed portion of the 256 bit seed to remove trait correlation\n * @param traitType the trait type to select a trait for \n
             * @return the ID of the randomly selected trait\n */\n function selectTrait(uint16 seed, uint8 traitType) internal view returns (uint8) {\n
             uint8 trait = uint8(seed) % uint8(rarities[traitType].length);\n if (seed \u003e\u003e 8 \u003c rarities[traitType][trait]) return trait;\n
            return aliases[traitType][trait];\n }\n\n /**\n * the first 20% (ETH purchases) go to the minter\n * the remaining 80% have a 10% chance to
            be given to a random staked wolf\n * @param seed a random value to select a recipient from\n * @return the address of the recipient (either the
            minter or the Wolf thief\u0027s owner)\n */\n function selectRecipient(uint256 seed) internal view returns (address) {\n if (minted \u003c=
            PAID_TOKENS || ((seed \u003e\u003e 245) % 10) != 0) return _msgSender(); // top 10 bits haven\u0027t been used\n address thief = barn
            .randomWolfOwner(seed \u003e\u003e 144); // 144 bits reserved for trait selection\n if (thief == address(0x0)) return _msgSender();\n return
            thief;\n }\n\n /**\n * selects the species and all of its traits based on the seed value\n * @param seed a pseudorandom 256 bit number to
            derive traits from\n * @return t - a struct of randomly selected traits\n */\n function selectTraits(uint256 seed) internal view returns
            (SheepWolf memory t) { \n t.isSheep = (seed \u0026 0xFFFF) % 10 != 0;\n uint8 shift = t.isSheep ? 0 : 9;\n seed \u003e\u003e= 16;\n
            t.fur = selectTrait(uint16(seed \u0026 0xFFFF), 0 + shift);\n seed \u003e\u003e= 16;\n t.head = selectTrait(uint16(seed \u0026 0xFFFF), 1 +
            shift);\n seed \u003e\u003e= 16;\n t.ears = selectTrait(uint16(seed \u0026 0xFFFF), 2 + shift);\n seed \u003e\u003e= 16;\n t.eyes =
            selectTrait(uint16(seed \u0026 0xFFFF), 3 + shift);\n seed \u003e\u003e= 16;\n t.nose = selectTrait(uint16(seed \u0026 0xFFFF), 4 + shift);\n
             seed \u003e\u003e= 16;\n t.mouth = selectTrait(uint16(seed \u0026 0xFFFF), 5 + shift);\n seed \u003e\u003e= 16;\n t.neck = selectTrait
            (uint16(seed \u0026 0xFFFF), 6 + shift);\n seed \u003e\u003e= 16;\n t.feet = selectTrait(uint16(seed \u0026 0xFFFF), 7 + shift);\n seed
            \u003e\u003e= 16;\n t.alphaIndex = selectTrait(uint16(seed \u0026 0xFFFF), 8 + shift);\n }\n\n /**\n * converts a struct to a 256 bit hash
            to check for uniqueness\n * @param s the struct to pack into a hash\n * @return the 256 bit hash of the struct\n */\n function structToHash
            (SheepWolf memory s) internal pure returns (uint256) {\n return uint256(bytes32(\n abi.encodePacked(\n s.isSheep,\n s.fur,\n
             s.head,\n s.eyes,\n s.mouth,\n s.neck,\n s.ears,\n s.feet,\n s.alphaIndex\n )\n ));\n
            }\n\n /**\n * generates a pseudorandom number\n * @param seed a value ensure different outcomes for different sources in the same block\n *
            @return a pseudorandom value\n */\n function random(uint256 seed) internal view returns (uint256) {\n return uint256(keccak256(abi
            .encodePacked(\n tx.origin,\n blockhash(block.number - 1),\n block.timestamp,\n seed\n )));\n }\n\n /** READ */\n\n
            function getTokenTraits(uint256 tokenId) external view override returns (SheepWolf memory) {\n return tokenTraits[tokenId];\n }\n\n function
            getPaidTokens() external view override returns (uint256) {\n return PAID_TOKENS;\n }\n\n /** ADMIN */\n\n /**\n * called after deployment
            so that the contract can get random wolf thieves\n * @param _barn the address of the Barn\n */\n function setBarn(address _barn) external
            onlyOwner {\n barn = IBarn(_barn);\n }\n\n /**\n * allows owner to withdraw funds from minting\n */\n function withdraw() external
            onlyOwner {\n payable(owner()).transfer(address(this).balance);\n }\n\n /**\n * updates the number of tokens for sale\n */\n function
            setPaidTokens(uint256 _paidTokens) external onlyOwner {\n PAID_TOKENS = _paidTokens;\n }\n\n /**\n * enables owner to pause / unpause
            minting\n */\n function setPaused(bool _paused) external onlyOwner {\n if (_paused) _pause();\n else _unpause();\n }\n\n /** RENDER
            */\n\n function tokenURI(uint256 tokenId) public view override returns (string memory) {\n require(_exists(tokenId), \"ERC721Metadata: URI
            query for nonexistent token\");\n return traits.tokenURI(tokenId);\n }\n}"}}
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

        File 5 of 5: WETH9
        1
        2
        3
        4
        5
        6
        7
        8
        9
        10
        11
        12
        13
        14
        15
        16
        // Copyright (C) 2015, 2016, 2017 Dapphub
        // This program is free software: you can redistribute it and/or modify
        // it under the terms of the GNU General Public License as published by
        // the Free Software Foundation, either version 3 of the License, or
        // (at your option) any later version.
        // This program is distributed in the hope that it will be useful,
        // but WITHOUT ANY WARRANTY; without even the implied warranty of
        // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
        // GNU General Public License for more details.
        // You should have received a copy of the GNU General Public License
        // along with this program. If not, see <http://www.gnu.org/licenses/>.
        pragma solidity ^0.4.18;
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX