I have a productopenandvisualstudiocodewithanemptyHTMLpagethatlinksourstylesheetfoldercontainingallthedifferentassetswillpayforthisprojectarecursedresponseimagesandaudioandthen, lastly, inemptystyleshootsCSSPagethatwecanuseinordertostylearedifferentelements.
Sotogetstarted, let's createthtammoforthetextthatisgoingtobeatthetopfor a pagehere.
Thefirstthingthatwewanttodoisyouwanttoincludein H one, whichisgoingtoinclude a titleofourpagemixedmixturematch.
We'rejustgonnagiveit a classofpagetitlesothatwecanselectitinourCSSlater, andwe'llputinherethetextmixor a match.
Next.
Wewanttoinclude a containerforactualgame, sowe'llgethimhere.
Creative.
Giveit a classofgaincontainer, andthiswillcontainallofourgameinformation, suchasourtimeandourmemberofflips, aswellasallthecardsforourgame.
Giveit a classofgameinfo, andinherewe'llputouractualtimeaswellasinsideofthisbandwithan I d oftimeremaining, we'llfliptheactualtimevalueof 100 witchesarestartingtime.
Thereasonthatwe'rewrappingthisinsideof a spanhereissothatlaterimportantaxesvideo.
Copythissourcepasteddownandthesamethingfor a secondfile, whichis a walktofile, thatwehavesupportforbothtypesoffiles, dependingonwhichbrowsersupportswhichtype.
Wecouldjustcopiedthatdownheresincewehave a lunacydotoffand I wanttoseethatoffto, asyoucanseeinsideofthispondsFullerhereandnowwehavebothofthosephonesimportantinourpage, andwecanstartusingthem.
Thelastthingthat I wanttodobeforewegetstartedstyling.
It's changedoursitetousetheboxsizingofBorderBox, whichwillmakesizingourelementsbasedon a certainwithmucheasiertodonext, wecantackletheactualbackgroundcolorthatyouseehereonoursite.
Asyoucansee, it's notquite a solidcolor, anditactuallychangescolors, whichdarkontheoutsideandlighterontheinsideofthescreen.
Wegot 16 differentcardsinsideofourcontainerandinsideofourstylesthatCSStemporarilyLester's create a stylefor a cardwherewegivethebackgroundcolorofblack.
We'regoingtogiveit a fighthereof 175 pixelsand a Witteof 125 pixels.
Now, ifwesavethatlookback, youseethatwejusthave a blockoftextrightnow, whichisfinebecausethere's nospacingaroundourelementsandordertocreate a gridlikefewherewewanttodoiswewanttoselectourgamecontainerthatwecreatedearlierthatwrapsallthesedifferentelements.
We'regoingtogiveit a classofcardback, andthisisgoingtobewherewestyletheactualelementsforthebacksideofourcard, whichyouseeherewillalsogiveit a classofcardface.
First, wewant a positionitabsolutelyinsideofourscreen.
Sothatwaywecanpositionitisoutofthecard.
Wewanttogiveit a specificwith 47 pixels, heightof 47 pixelstoPhilip, theavailablespacethatwewantthesecombostotakeup.
Andifyousaythatyoualreadyseethatthey'renowoverlayingovereachotherinthecenterofourscreen, wecannowuseourdifferentselectorsherefor a coupleoftopleftinordertostylehowwewantourtopleftKabulittolook.
Thiswillallowustomake a smoothlookinganimationthatoccursover a periodoftimewewantedoverthetransportpropertywhowanttolast 100 milliseconds, andwe'lluseeasingout, asaredifferentlineartechniqueforhowouranimationshouldlook.
Ifyouhavebeenconfusedaboutthisthree D rotations, checkout a video I madeonhowtocreate a three D buttonthatflipsonhoverbecausetheconceptsaregoingtobeverysimilartowhatwe'regoingtobedoingthisvideotomakethecardflippedinordertotestthisflipping.
Sowehavetobatdot p and G's here, andthenwecanchangethisyeartobebonesand I willhavetobonesinsideofthesetwocardsanddothisallthewayuntilwehaveallofourdifferentcardsstyle.
Therewego.
I justfinishedfilingallthosethatwehave, thedifferentelementsinsideofit.
Sonowreally, theonlythingthatwehavelefttodotoimplementforthesecardsisasyoucanseeoverhere, if I get a matchhererealquick, youseethattheactualcardwillanimatein a littledancinganimation.
Andthenwhatwewanttodoisyouwanttoadd a smallbitoftexttosaythatwewanttobeabletostartthegamesowe'llsayspaninsideofhere, Giveit a classoverlaytextsmallinsideofthere.
What's a clicktorestartnowifyousaythat, youseethatwehavethisgameoverandthecliptorestart, butwedon't wantittobequitestyledlikethis.