Alice Start Part One Slides

32
  Alice  : Scene Setup and Starting Animation by Ruthie Tucker and Jenna Hayes Under the direction of  Professor Susan Rodger Duke University, July 2008 www.cs.duke.edu/csed/ alice/aliceInSchools

description

Programming

Transcript of Alice Start Part One Slides

  • AliceLearning to program: Part 1Learningtoprogram:Part1

    SceneSetupandStartingAnimationbyRuthieTuckerandJennaHayes

    UnderthedirectionofProfessorSusanRodgerDukeUniversity,July2008

    www.cs.duke.edu/csed/alice/aliceInSchools

  • OpenupAlice,andchooseabackgroundforyourAlice

    ld Y ld i

    AddanobjecttoyourAliceworld.Aliceisfullofdiff t ki d f bj t tworld.Yourworldis

    somethingyoucanputobjectsinandmakethemdo

    differentkindsofobjectstoaddtoyourworldtomakeitinteresting.ClickontheAddj

    things.Therearesixdifferentbackgroundoptions.Choose

    gObjectsbutton:

    grass.

    Clickontheanimalsfolder of objects:folderofobjects:

  • Findthehorseamongthetypesofobjectsandclickonit.Then click Add Instance to World This is how you add anThenclickAddInstancetoWorld.ThisishowyouaddanobjecttoyourAliceworld.

    Thehorseobjectwillappearinyourworld.

  • AddingaDummyCamerag y

    Thisistosavecurrentf lcamerapositionforlater

    Clickonmorecontrols Click on drop d mm at Clickondropdummyat

    camera.Justclickitonce!

    ClickthegreenDonearrowontherighthandsideofthescreentogobacktoth i AlithemainAlicewindow.

  • Adding a Dummy Camera (cont)AddingaDummyCamera(cont) AfolderofDummyObjects

    appears

    Clickonthe+byit Thecamerapositionsavedis

    D mm Dummy

    Clickonitandselectrename and rename it torename andrenameittooriginalposition

    Wewillusethislater

  • Save WorldSaveWorld

    SaveworldSa e o d

    Type in a name such as: horseWorld and thenTypeinanamesuchas:horseWorld,andthensave

    Alicewillremindyoutosaveyourworkevery15y y yminutes

    ItisalwaysagoodideatocreateafoldertoputallyourAliceworldsin.

  • Youmayseethatyourhorselookslikeitshalfwayunderground.Whenobjectsareadded,sometimestheyappearinstrangeplaces.Weneedtomovethehorsesohelookslikehesontheground.ClickontheaddObjectsbuttonagain.Wearegoingtousethesebuttonsthatappeartomovehimg g pparound:

  • Thisbuttonwillmoveyourh f th b k f thhorsefurtherbackfromthecameraorclosertothecamera,totheright,ortotheleft.Clickonyourhorseanddraghimaround.Trymovingyourhorseforwards and backwards If youforwardsandbackwards.Ifyoudontlikethewayyourhorselooksafteryoumovehim,clickth U d b tt i th t l fttheUndo buttoninthetopleftcornerofthescreen.

  • Thisbuttonmovesanobjectupand down when you click on itanddownwhenyouclickonitanddragit.Moveyourhorseupuntilheisstandingontheground.

  • Thisbuttonturnsobjectsleftandright.Usethistoturnyourhorseag ylittletotheleft.UseUndoifyoumakeamistake.

    Notice that your horse seems toNoticethatyourhorseseemstoturnaroundonepoint.Thisisyourhorsescenter.

  • EachobjectinAlicehast Thi i thacenter.Thisisthe

    pointonanAliceobjectthatdetermineswhereitisintheworld,andaroundwhichtheobject will rotate if centerobjectwillrotateifcommanded.Everyobjectscenterisdiff t

    center

    different.

    center

    center

  • Thisbuttonrotatesanobjectf d b k d d itforwardsorbackwardsarounditscenter.Tryrotatingyourhorse,andthenputitbackinitsoriginalpositionusingUndo.

    Thehorseisrotating.

  • Thisbuttontumblesanobjectinallkindsofcrazydirections.yTrythisbuttononyourhorse,andthenputitbacktoitsoriginal position using UndooriginalpositionusingUndo.

    The horse is tumbling!

  • Thisbuttonmakesanobjectbiggerll T i i horsmaller.Tryresizingyourhorse,

    soitisalittlebigger,andthenmovehimupoutoftheground.

    Giant horse!

  • CreatinganEventinAlice

    NowwearegoingtoshowyouhowtocreateaneventinAlice.

    An event is something that you tell Alice to do afterAneventissomethingthatyoutellAlicetodoaftersomethingelsehappens,suchaspressingakeyorclickingonsomething.

  • InthetoprighthandcornerofthescreenistheEventsEditor This is where you make events which are commandsEditor.Thisiswhereyoumakeevents,whicharecommandsthatyoutellAlicetodowhenacertainthinghappens,suchaswhenakeyispressed,oryouclickyourmouseony p , y ysomething.

  • Clickonthecreateneweventbutton.Ch th h

    Youreventeditorwillnowlooklikethis:

    Choosethewhenakeyistypedoption.Wearegoingtog gmakeitsothatwhenwepresstheN key,

    h illourhorsewillsayNEEEEEEEIGH! Clickonanykey ,thenchoose

    letters, then choose N. It willletters,thenchooseN.Itwillnowlooklikethis:

  • Nowclickonthehorseinthelistofobjects,andthenclickonthemethodstab.Findhorsesay,anddragituptotheeventseditorwhereitnowsaysNothing.

  • Whenyoudropthesaycommand,you Playyourworld,andwillneedtotypeinsomethingforthehorse to say like

    trypressingN.Wheneveryoupressit your horse shouldhorsetosay,like

    NEEEEEEEEIIIIGH!Youreventseditor

    it,yourhorseshouldneigh.

    willnowlooklikethis:

  • Nowwearegoingtousethehebuilderandshebuilderobjects in AliceobjectsinAlice. Thehe/builderandshe/builder

    areforcreatingyourownh i ldcharactersinaworld.

    YoucanfinditunderthepeoplefolderofyourLocalGallery

    LetsstartwiththeShe/builder

    Wh h Whenyouopentheshe/builderfolder,thisscreenwillappear

  • Getting startedGettingstarted

    You can change the leg,Youcanchangetheleg,upperbodyandheadshapeofyourperson,usingthearrows.

    Selectthehaircolor.Youcanchangetheshapeandcolorofyourhair using arrowshair,usingarrows.

  • Choosing the DetailsChoosingtheDetails

    Now,selectthetablabeled,skin/eyes.Youshouldhavethreeoptions:skincolor eyes and lips The skincolor,eyesandlips.Theskincoloriscontrolledbyadialonthetop.

    Theeyesandlipscanbeselectedbythearrows.

    All of the changes you make Allofthechangesyoumakewillappearonyourperson,totheleft.

  • Choosing the DetailsChoosingtheDetails

    Now,selectthetablabeled,skin/eyes.Youshouldhavethreeoptions:skincolor eyes and lips The skincolor,eyesandlips.Theskincoloriscontrolledbyadialonthetop.

    Theeyesandlipscanbeselectedbythearrows.

    All of the changes you make Allofthechangesyoumakewillappearonyourperson,totheleft.

  • Choosing the Details (continued)ChoosingtheDetails(continued)

    By selecting theByselectingtheclothingtab,youcanchooseshirts,pantsandshoesforyourperson.

    Finally,youcangiveyourpersonanameatthebottomoftheperson builderpersonbuilder.

  • Now its your turnNowitsyourturn

    Try creating anotherTrycreatinganothercharacter

    IfyouwanttousetheyHe/builder,itworksthesameway

  • Tryexperimentingwith the buttonswiththebuttonsthatmoveobjectstomoveyourpeoplearoundinyourworld.

  • Nowwellusequadviewtopositionourcharacters.ClicktheaddObjectsbuttontogetbacktotheobjectj g jmovingscreen. Lookoverontherightside

    ofyourscreen.

    Thereshouldbetwotypesof camera viewsofcameraviews

    Singleview(bottomleft)andQuadview(bottomright)

  • Quad ViewQuadView

    Quadviewisgoodforfixing Try to position yourQ g gthepositioningofyourcharactersintheworld

    Trytopositionyourcharacterssothattheyappearinallfourscreensofyourworld.

    Thishelpstomakesurethatyourcharactersarentupintheair,orfarapartapart.

  • QuadView(Continued)( ) Lookoverontheright,

    underquadview. Note the button that looksNotethebuttonthatlooks

    likeahand Thisallowsyoutomove

    around the camera in QuadaroundthecamerainQuadView

    TheMagnifyingglassallowsyoutozoominwhileinyquadview,tobetterpositionyourcharacters

    Youllneedtoclickanddraggonyourviewingwindowswhenusingbothofthesebuttons.

    Trythemoutnowtocenteryourcharactersineachview.

  • Animating your CharactersAnimatingyourCharacters

    Onceyouhaveyoury ycharactersinyourworldyoucanstarttoanimatethem Click on one of yourthem.Clickononeofyourcharactersintheobjectlist.ForusitisMatt.LookontheleftofyourscreenunderMattsdetails.Thereshouldbealistofmethods.Thisisthelistofactionsthatyourpersoncanalready doalreadydo.

  • StartingyourOwnMethod You can click and drag any of these methods into the main Youcanclickanddraganyofthesemethodsintothemain

    sectioncalledworld.my firstmethod.Trythiswithafewofthem.

    Nowclickplayinthetoplefthandcorner. Yourcharactershouldanimatehoweveryouhavecodedhim.

  • Moveoneofyourcharactersaroundinyourworldusingquadviewuntiltheyarestandingrightnexttothehorse,q y g gsomethinglikethis:

    Nicejob!NowwearereadytomoveontoPart2.