Posted February 18, 2014 I've gone over and over the code again and again and can't figure out why it's printing my function as 0 when it's compiled. Could someone please show me what I can do to fix this? ;Evan Owen ;Functions Example ;Window Resizing---- Graphics 1024, 720, 32 ;Varriables---- FirstColor$ = "" SecondColor$ = "" PieceOfClothing1$ = "" PieceOfClothing2$ = "" SentenceOut$ = "" Global UserName$ = "" Global UserNumber1 = 0 Global UserNumber2 = 0 ;User Generated Sentence Function---- Function UserSentence(FirstColorInput$, SecondColorInput$, PieceOfClothing1Input$, PieceOfClothing2Input$) Sentence$ = UserName$ + " Showed Up At The Door Wearing " + UserNumber1 + " " + FirstColorInput$ + " " + PieceOfClothing1Input$ + "s And " + UserNumber2 + " " + SecondColorInput$ + " " + PieceOfClothing2Input$ + "s " Return Sentence$ End Function ;User I/O---- Print("--Name Two Colors--") FirstColor$ = Input("First Color: ") SecondColor$ = Input("Second Color: ") Print("") Print("--Name Two Induvidual Pieces Of Clothing--") PieceOfClothing1$ = Input("First Piece Of Clothing: ") PieceOfClothing2$ = Input("Second Piece Of Clothing: ") Print("") Print("--Enter Any First Name--") UserName$ = Input("Name: ") Print("") Print("--Enter Two Numbers--") UserNumber1 = Input("First Number: ") Print("") UserNumber2 = Input("Second Number: ") Print("") ;User Generated Sentence---- SentenceOut$ = UserSentence(FirstColor$, SecondColor$, PieceOfClothing1$, PieceOfClothing2$) Print(SentenceOut$) WaitKey Link to comment Share on other sites More sharing options... Link to post Share on other sites More sharing options...
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now