Change Contents of the Bubble
Welcome to CS1315. Click on the python to add comments.

Looking for the book? They have it at the Engineer's Bookstore at 748 Marietta St NW. Here is there website: http://www.engrbookstore.com/ - Monica

Hotspots: Slides and CodeTA CornerComments?AnnouncementsFAQStatic Webspace
View this PageEdit this PageUploads to this PageHistory of this PageHomeRecent ChangesSearchHelp Guide

Homework 3 Questions- Fall 2007

Post any questions here.

Sorry for the change everybody, but when you submit anything on T-square, make sure that you press the "Submit" button and not the "Save Draft" button as you have done in the past. The "Save Draft" button will keep your work, but will not ever submit it. However, once you have pressed "Submit", you can't change anything without e-mailing your TA the new files, so try not to submit until you are sure that you are done. If you e-mail the TAs after 11:45 PM, your submission will still be late, so make sure that you e-mail them in time if that is what you need to do. Once again, I'm sorry about this change. Thanks! Brittany Duncan

could anyone else get the link to the maze to work? I tried typing the address into my browser and couldn't access the page.
I have the same problem!
me too!
so yeah i have the same problem and it just says i am FORBIDDEN from accessing the site on my browser...
Is this is? http://zs.ffshrine.org/legend-of-zelda/maps/level4.gif
i found it if you go to the main site and then follow the media path to click on the links. try that

does it have to go "through" the maze like in a logical way or just move across the maze...? and are there some elements to this that we have not learned in class yet?
You should be able to do this with everything that we have done so far in class. My advice is to write a program initially that has a single sprite "glide" across the maze. Then revise your program, once this works, so that the sprite navigates the maze intelligently. Finally, you can have the program cycle through a bunch of sprites so that instead of gliding, it looks like it is walking, jumping, crawling or whatever. Colin Potts
Does the sprite need to be animated so that it is running, like the example of megaman running through mario world?
So what's the end of the maze? The top left room? And do we just have to avoid the black space in our path?
I'm just generally confused
The end of the maze is in the top right corner (the room with the greem dragon in it), and you have to avoid the black space as well as make your character move intelligently through the maze. Hope this helps; let me know if you have any questions. Toni Walden

Does it have to be chromakeyed, or can we use a separate image for an 8-bit alpha channel?
(I ask mostly out of curiosity and partially because I like making things more complicated than they have to be)
In principle: go for it. In practice: I'm not sure how this would work, since all pictures in JES are 24-bit RGB. Are you suggesting creating a monochrome sprite "mask" to encode the transparent pixels? Colin Potts

The instructions say that we don't need to obey where the walls are, but we do need to ensure that we move only up, down, left, or right. Are we required to obey where the water (blue) is?
Do we have to use the sprites provided or can we use our own, as long as they do not spill over into the other rooms?
Feel free to use your own sprites (as long as they are reasonably sized!). Toni Walden
Also, can we edit the picture to have our name in it, or do you want use to use JES to write our name on it?
JES. Thanks!Brittany Duncan

Can we write "def zeldaRun(bgpic, spriteFile)" or should the function not take in any inputs?
Since the instructions say to call it zeldaRun and does not specify parameters, I suggest having it NOT take in parameters because it will make it easier for TAs to grade, unless you hear otherwise from someone else.Jon Cohen

two of the rooms have black floors, does that mean we cannot go through those rooms?
No, you can go in those rooms. The "avoiding black space" part of the assignment refers to the black area outside of the maze to prevent people from taking a direct route to the final room ignorong the maze completely.Toni Walden
Right now, I have my sprite running with steps alternating every frame, and it looks like a blur. How would I have him running with several frames in between each step?
Use more images. If you have two images that you are alternating to make your sprite run, it will go through that sequence 15 times in one second (because the assignment says to use 30 frames per second). I am not sure if you are making your own sprites or using the ones in the .zip file provided, but if you look in that file there are several that have multiple images (8+) to represent running. The more images you have your motion broken into the smoother it will seem.Toni Walden
Alteratively, if you really only want to use two images and you wanted to use each one for – say – 0.50 sec in a 16fps movie, you could do find out whether frameNumber%16 is greater than or less than 8 and choose one of the two sprites accordingly. Since the sprite will be positioned differently on each of eight consecutive frames during the half second, it will look as though it is skating rather than running. Colin Potts
How do you use more than one image?
See example posted to the slide page and discussed briefly in class yesterday. Colin Potts
Does the sprite have to go into every single room on the map or just the ones that get it to the final destination?
How are we supposed to reach the room with the dragon without going through the black room with the coins?
Don't worry too much about "solving" the maze. The homework is designed to get you to practice with animation. If you make the sprites move intelligently around the rooms of the maze, changing direction a few times because of the doors that get in the way, we will give you the extra credit. Colin Potts
Is the background supposed to be one big picture, or can we cut it into several smaller rooms? I'm not really sure how to use a background shaped like the one we're using...would we just show pieces of it at a time?
You could just leave it as one big picture, and I believe that what is intended. However, if you would like to cut the maze into smaller images to where you do not "see" the next room until the sprite enters it, feel free. With things like this, it's not so much we tell you how you HAVE to implement the background, but give you a little freedom for creativity. If you would like more spefics, e-mail one of us and let us know exactly how you were thinking of setting up the homework, that way we can make sure you are still meeting the minimum requirements for the assignment. I hope this helps and feel free to contact me if you have any questions. Toni Walden
Anyone who has not already broken up the background, please don't. If you do, you will have to submit a number of extra files (and it is also a lot of extra work for you). Thanks! Brittany Duncan
I don't really understand how leaving it as one big picture would work...
I have tried to download movie maker several times now and it is just not working. I am using the windows one and it starts it, but it has never got passed "starting"...what could be the problem?
Is okay if we scale down the map a little bit, I can't even see the whole thing on my screen as it is.
Preferably not, because once again, you will have to submit an extra file. Thanks! Brittany Duncan
I am using writePictureTo to write out my frames. It takes in a picture(which JES defines as the picture you want to be written out to a file, but I don't understand what I'm supposed to define picture as. Is it the combined sprite/background?
For the extra credit using the doors, does the sprite have to disappear between the doors to get the credit?

For the person who can't get movie maker to work...make sure you add the .mov on the end of the file name
.
I sure hope our TA's are prepared to wait a while for our programs to make the frames because mine seems to take ages.
They know that it will take a while, it always does. Thanks! Brittany Duncan
My computer doesn't seem to like putting together more than 12 frames or so...uh oh
in order to be counted as using the doors, do the sprites have to pass under the wall while going through the door, or can they just go over the wall?
They can just go over. Thanks! Brittany Duncan
my program works fine and everything is going well, but it takes a long time to load and my function has reached 200+ lines...and going.... is this too much?
That's fine. Thanks! Brittany Duncan
do I need to rotate the sprite when it runs upwards? or can it still be animated to run across even though it moves up?
Either is fine. Thanks! Brittany Duncan
Is the assignment to move the background while the sprite is stationary, but animated? or to move the sprite while the background is stationary expect when changing rooms?
Move the background while animating the sprite. Thanks! Brittany Duncan
Do we need to make the background move when the sprite changes room if we cut the maze into smaller images? or can we just cut to another room?
You should scroll across the big maze image and not make smaller pictures. Thanks! Brittany Duncan
I think this has been answered, but where do i get the Zelda map.
Look near the top of this page. Colin Potts
can you give a step-by-step list of what a TA will do after s/he receives our homework?

My program takes over 5 minutes to run. I'm very impatient.
Are you asking for advice about your program or your personality? ;) Seriously, that's the problem with animation: it is computationally intensive, and JES is slow. If you are still working on parts of your program and testing them, you can comment out the expensive commands (e.g. some of the writePictureTo/writeFrame calls) while you fix problems elsewhere. If you have divided your program into several smaller functions, you may be able to run those functions separately to test/debug/refine them. That way you don't need to wait so long. If you're nearly done with the program and just fine-tuning, I'm afraid that you need to be patient and wait for it to do its thing. Colin Potts
Mine takes A LOT longer than over 5 minutes to run....is that a problem?! Ack!
Depends. You should check your indentation. Are you doing something inside a loop that should be done outside? (For example writing the sprite for every pixel in the sprite, rather than once.) Colin Potts
So when I try to play my srpite animation in MovieMaker,it doesn't do anything. It kind of blink a white screen and is done in like the shortest time ever. I put in the starting and ending frames, created the movie, did 30 fps, what am I doing wrong??
I don't know. It sounds as though you are making the movie with the wrong pictures. First, the background should not be white if you have created the frames correctly. (You HAVE bothered to look at some of them haven't you?) And if you are selecting, say, 60 frames at 30 fps, the movie should last for 2 seconds. You suggest that your movie is shorter than that. How many frames are there between the first and last frame? Colin Potts
so do we keep the sprite in the same spot(animated, of course), but move the background by using a smaller window of the whole maze that changes with each frame?

Does JES have an easy way to draw text?
Yes. addText(). It is in the JES function help menu. You can only draw black text, though. Colin Potts
im still confused about the whole 'the sprite is stationary, but the background moves?" havent we been sort of moving the sprite( a rectangle) in class along a stationary background?
Should we submit each file individually on T-Square or as a zip file?
For addText
you can actually change the color of the text.
ex. addText(pic,x,y,text,blue)
will make blue text
Thank you for pointing this out. I had forgotten that this had been added to JES (although the online documentation has not been updated.) In fact ALL of the drawing functions take an optional final color argument. Colin Potts


Is there a way to make classes in JES? It says its not legal Jython when I try to define one but it looks like I'm doing it correctly from the sample code I found.

nevermind i figured out how to make a class

Great! For those of you who are wondering what on earth we are talking about (99% of you probably), we will deal with classes, a concept in object-oriented programming in a few weeks. Colin Potts

I am working on my code for this HW and have tried using some sample code to get a feel for how this works but whenever I run the sample codes (e.g. homer crawling) it won't write the files to my computer so I have no way of testing the movie because the files aren't there for me to select. Obviously I'm missing a big concept. Do I have to do something extra to make the frames write to my computer? Can someone help???
Is it (1) ignoring you and not writing the files; (2) Giving an error message, saying that the folder is write-protected; or (3) Creating empty files - i.e. 0kb in size? If (1), you are writing the files correctly, but you haven't set the media path, so you don't know where to look for them. If (2), you need to set the folder you are saving the files into not to be read-only and/or set the folder that JES is in not to be read-only (writePictureTo actually writes a temporary file in the JES folder before transferring it to where you want it to be, so both folders must be writable.) If (3), we're working on that one. Colin Potts
It's closest to (1): I did set the media path (or so I think) but when I go to that folder there aren't any files. It's not giving me an error message of any kind. Is there something that I need to type into the command area that I'm forgetting to do? I feel like the programs not running...
Are you calling the zeldaRun() function, then? And are you making sure that everything is nested properly within your for loops? Chris Phillips

My code takes about 11 to 12 minutes to run, I make almost 700 frames is this normal?
It could be, if you're moving the image one pixel at a time. You might try moving it faster. Or, to speed up the runtime (but not change the frame number), you could try writing the code so that it only shows one room of the map at a time. Chris Phillips

What?!
I spent all afternoon and night Thursday completing this program, which I did, and now I see that the sprite has to be stationary while the background scrolls? Are you saying I just wasted all those hours of my life because the original instructions didn't get across what you intended?!?
No. While it's ultimately up to Colin, it wouldn't be fair to, essentially, be punishing those who started early on it. I already emailed Brittany and Colin both when I first saw the ambiguity (before it was changed on the coweb), and got their okay to have the sprite moving, since it was ambiguous. I believe the wording was changed to try and remove the ambiguity, since it was causing concern for some people. So if you've already done it differently, before the directions were changed, don't worry about it. Chris Phillips

for the second-sprite extra credit, does the second sprite have to move simultaneously with the first sprite or should it have its own movie?
As the directions don't say it should move simultaneously, I assume you can have it run right after. However, it shouldn't be -too- difficult to make it run simultaneously if you want it to. You'd need to have it run off of the same loops you've created for the first sprite, but you could handle the different movement by including if clauses. I'd recommend using if clauses, just 'cause it'd make it execute faster then (and be a shorter movie too), which makes TAs happy. But then, I'm biased. Chris Phillips

Ok, so it says the background is supposed to move, and that the sprite (in addition to being animated) needs to move up, down, left and/or right. How can we accomplish both without making it an extremely complicated function? If we just animate the sprite in the center of the screen and then move the back ground to where it appears the camera is centered and fixed on the sprite, is that ok? IE: The sprite never leaves the screen's center, but the background moves to accomodate his directions towards the doors and next rooms.
Yes. That is exactly what Brittany's revised directions seem to indicate, in fact. Chris Phillips

The directions for Homework 3 say we will lose 10 points if the background of our sprites are solid colors. All of the provided sprites have solid backgrounds, though. Does this mean that we have to find our own sprites without solid backgrounds? Thanks
You should use chromakey to make the backgrounds not solid. Thanks! Brittany Duncan
I keep getting the following error:
getPixel(picture,x,y): y (= 211) is less than 1 or bigger than the height (= 210)
The error was:
Inappropriate argument value (of correct type).
An error occurred attempting to pass an argument to a function.
I've tried to fix it numerous times, to try to make it so y isn't more than the height, but nothing seems to work... Oh, and its part of my chromakey function
Don't try to fix it. You will start making little changes here and there that seem plausible. But that is really just trial and error and you will probably only waste time. Work out instead exactly what your program is doing. Be thorough and stupid about this – as stupid as a computer. Don't try to second guess anything. Write down the values that your program is setting. Once you have done that, you will eventually see what is going on, why y can get to 211 instead of 210, and fixing the code will be automatic. Colin Potts
BTW, I'm not trying to be cute. I don't know what you're doing wrong. You might sit down with a TA on Monday or come to my office hours if you are still stuck. Colin Potts

ok all I have to do is uncomment a few things for my program to work but I'm estimating my program will take a good 11 minutes or so to run... should I just reduce the number of frames by making the character run faster (and thus making the video over in like 10 seconds) or is that fine?
Don't worry about the program taking a long time to run. The TAs are prepared for this. Just be sure that you have indented everything correctly so that you aren't doing something completely crazy like writing a file every time you get a pixel (which will take too long). Animation is time consuming. (See next question.) Colin Potts



scratch that, mine is going to take something like half an hour to run. But I have a slow computer. What should I do to cut down on time? I'm making the background scroll by centering the background on the sprite and then going through the frames in a for loop. Inside the frame for loop is a for loop for the X values of the picture, and inside that for loop is a for loop for the y values in the screen (I'm only drawing a picture the size of a room). So I'm not using a getPixels() of the entire background, I'm using getPixel(background, sprite location + x, sprite location + y) and copying that onto the canvas and writing that frame. Is this the way we're supposed to do it and I just have an excruciatingly slow computer? I haven't even copied the sprite into the frame yet, but it took a good 20 seconds to write 10 frames of a scolling background and I'm gonna have 800 something frames.
Two frames per second. That sounds about right. Remember the sunset demo that I gave in class would have taken about 20 minutes if I had run it to completion. This is the problem with animation: it's computationally intensive, and JES is slow. Colin Potts

When submitting our homework is it ok to have a zip folder containing the sprites or should we upload the sprite's frames individually?
Perfectly fine to zip them up. Chris Phillips


Does the sprite itself have to change direction? Like, if he is walking left but his animation makes it look like he is moonwalking, is that OK?
We're not asking you to change the sprite's direction. Chris Phillips

I need help (obviously). When i test a small portion of my code to write a series of frames, Prof. Potts suggested that i get the Sprite to glide, then worry about animating it... and i get the sprite to glide, but the sprite that is from the previous frames does not go away. I realize that in the "pong" demo that we made a new canvas every time we made a frame, but I'm not sure how to go about that for the maze frames. Please Help?
Kathryn Stokes
Depends on how you approached the problem, but generally speaking, set the statement that makes the maze.png file into a picture into the for loop. So, if you currently have, say, canvas = makePicture(getMediaPath("maze.png")), and it's outside the for loop that is generating your sprite's movement, place it inside the for loop instead. It'll mean every iteration of the for loop, the background will be reassembled from that picture, and no longer contain the sprite. Chris Phillips

when i play my movie, my name i added with jes is blurry. Is this a problem?
No problem. The blurring is a side effect of the compression that takes place when JES saves a JPG image and MovieMaker compresses the frames of a movie. Colin Potts

must the background scroll? or can we move the sprite itself? i have already created a setup where the movie goes room by room (the movie is 256x176).

when the TAs run the program to remake the video, they will set a media path, right?
My entire animation takes about 2000 frames and an hour to run... Is this okay?
Absolutely! You write a program in your first CS course that takes an hour to run... How could we say that's not okay?! (Actually, we have a secret way to test your program that won't take that long, so don't worry.) Colin Potts

Is it ok if the sprite's movements are not logical, like when it goes up, it is facing right or left?
You don't need to rotate it. If it always faces left/right when going up/down it will look like many 1970s-80s video game animations anyway and you'll get full credit. Of course you can rotate your sprite if you like. It's not as difficult as you might think, especially if your sprite is square. Colin Potts
i just turned in my assignment on t-square but less than one second after i realized that i didn't add the map to my attachments. how can i be able to add it on to my assignment.
You would have to e-mail it to your TA. If you did not make any changes to the background, don't worry about it. Thanks! Brittany Duncan
Is it ok if I make each frame equal to the entire map, rather than cutting small pieces of the map for each frame?
That seems to meet the critera, so that is fine. Thanks! Brittany Duncan
How do I do the MovieMaker part of the assignment?
Is it ok, if I keep the same background map throughout, just changing the sprite's position on it??
If you are meeting the critera that we posted then yes, but you need to run through the maze. Thanks! Brittany Duncan
This sounds like a really stupid question, but when I'm setting the background color for my sprite in the chromakey function, I tell the function to take in the "green" color and make it transparent (for the Yakko_walk sprite–its that really bright green color) but its not working. I tried upping the threshold to 30 instead of 10 but it isn't working. What am I doing wrong?

Try using the openPictureTool() function to get the exact (r, g, b) of the green
I saw earlier on the page someone asked about starting early and having a moving sprite as opposed to a moving background... that's what i have because i started last monday, but i haven't submitted it yet. Am i still okay to have a moving sprite or do i need to try and write new code?
That is fine. Thanks! Brittany Duncan
Will it meet the HW requirements if I keep the same portion of the background for some frames before switching to another portion?
Yes (as long as your sprite is moving). Thanks! Brittany Duncan
how do i know how many fps my animation runs at? if my animation is like 300 frames, does that mean it will automatically run at 30 fps and last 10 seconds? what if i have a number of frames not divisible by 30?
MovieMaker lets you choose the frame rate, so you get to decide how long the movie will run for. Fractions of a second are okay. E.g. 200 frames at 30 fps lasts for 6.67 seconds. Colin Potts
Do we have to use MovieMaker to convert the frames to .mov format? Quicktime makes a much smaller output file.
You can use anything that makes a movie file. We teach you about MovieMaker, because it works on all platforms and is free. Colin Potts
I'm just not understanding how we're supposed to move the background.
You're not really "moving" the background, although that's how it will look. You are really panning a viewport across the background, by copying only a part of the background onto the canvas for your frame – a different part for each frame as you pan across the background. A partial copy of a background like this is often called a viewport, because it is like moving a window over a bigger background. As a practice exercise, think about how you would copy the top 200x200 pixels onto the first frame's canvas (easy) and then how you would copy another 200x200 pixels that are, say 5 to the right and five down, onto the second frame, and then 200x200 that are 10 over and 10 down onto the third frame, and so on. Do this enough times and it will look like the background is moving up and to the left from frame to frame or that a stationary sprite is moving down and to the left across the background. Obviously, you need to do this in a loop that specifies how the top-left x,y location of the viewport changes from frame to frame. Colin Potts
i've been working on this background animation for hours and i haven't made any progress and i don't really know what i'm doing wrong either, is there going to be a chance for me to get some help before the deadline?
you could go to someone's office hours tomorrow, though that may be inconvient I guess
The office hours schedule has been posted for two months. Several people, including me, are free to help you tomorrow. Colin Potts
It keeps telling me that the input for getHeight(canvas) is not a picture even though the line right before says canvas=makePicture(bgFile)....?????
Bizarre!!!! Colin Potts (Email me your code and the text of the error message, and I'll have a look.)
i can't understand how we don't take in any imputs! how will the function know to replace the pixels of the viewer with the MAP pixels if we can't call it as imput?
You can use getMediaPath and name the file. For example, the spriteMovie() function in the Homer crawling across bottom of canvas example has no inputs. Many of the examples of picture manipulations from the first part of the course don't take inputs. Colin Potts
I'm still confused about how the moving background works. I know there is the sample code, but I think I'm not understanding how to use it.
How many frames are we supposed to be making? Or is this a trial-and-error thing?
so if we're showing one room at a time, it might be hard to get the extra credit (alternate routes)...could one sprite just follow behind another? or should one disappear off to another room then meet up later towards the end?
You could run one sprite through the maze, then run the other sprite through a different route. Thanks! Brittany Duncan
My homework assignment in the compressed archive (zeldaRun.mov, hw3.py, individual frames, map picture, individual sprite images) is over 200 MBs! Is this reasonable?
I cannot attach my zeldaRun.mov using T-square. It says I have reached a file size limit. The movie clip is 160 MB. I have uploaded the hw3.py file and the map and sprites, but I cannot upload the movie. What should I do? Should I try to email it to my TA?
If you did not change the map, please don't worry about uploading it. If all of your files cannot be uploaded, please e-mail the entire assignment to your TA. Thanks! Brittany Duncan

I've narrowed the problem down to my chromakey function, but I can't figure out how to fix it so it works. The program seems to work without the chromakey although the sprite isn't copied onto the frame...
Have you seen a TA? Thanks! Brittany Duncan
Try copying the sprite as is onto the frame - i.e. without chromakey. It won't look right with the green or magenta background, but it is a start and you will get partial credit for it. Once you have the sprite moving around correctly, you can worry about using chromakey to make its background field transparent. One Thing At A Time. Colin Potts
I'm going to try although I have a ridiculous schedule today.

My sprite gets to a certain point (practically in the middle of the bottom portion of the map) and then keeps disappearing. Any suggestions on how to fix that?
your x or y position of the sprite might not be within the parameters of the background picture
You don't say this, but I suspect that the sprite disappears at the point where it is supposed to change direction for the first time. If so, check what is going on in the second loop (probably when the sprite starts to move up the screen?) I'm not sure that the x,y locations are invalid. This might be true if you were drawing a geometrical shape, as in pong, but when you are copying a sprite and addressing pixels by their x,y coordinates, if you tried to paint outside the canvas you would get an error message. (1) If the canvas is very large, are you sure that the sprite is disappearing and not being positioned incorrectly on a part of the canvas that you have to scroll to when you open it? (2) Are you sure chromakey is working correctly in the second segment? If you give it the wrong input picture or set the wrong threshold, you may be getting a "ghost" sprite that you can't see at all. Colin Potts
i am really bad at the positioning of the sprite. can anyone give an example of the lines of code that make the picture go left to right and right to left and up?
Check out the pong code. It makes the box bounce around the screen. I would also ask that no one post their sprite code to the Coweb. Go see a TA if you need that much help. Thanks! Brittany Duncan
Just curious, how big of a file should the movie be? Mine is 162mb, and I have heard others that had that big of a movie, but it seems kind of ridiculous for a 15 sec movie to be that big.
Wow. That does sound high. I just created a movie while helping a student test their program. For 80 frames with the complete 1024x1408 background, it was 26MB. So yours is about 6-7 times as big, which is feasible if you have 400+ frames. If your file is this large, you may have a problem uploading it. If you encounter problems, upload your code and email your TA. Colin Potts
hey whats going on with my code. im not able to see my program- i am using a different computer from the one i intitally created the program on, but what should i do now that im using a different computers (sorry if this is a elementary question):

>>> zeldaRun()
Note: There is no file at /Users/Jack/Bart_and_Homer_01.gif
makePicture(filename): There is no file at /Users/Jack/Bart_and_Homer_01.gif
The error was:
Inappropriate argument value (of correct type).
An error occurred attempting to pass an argument to a function.
Please check line 3 of /Users/Jack/Desktop/jes.py
What you mean to say (I think) is that your program cannot access your picture files. The error message clearly indicates that it is looking for the sprites on the second computer's desktop and they are not there. Either the sprites aren't on that computer at all or they are but are in a folder that you need to set as your mediapath. Colin Potts
Every time I try to run my code it takes a very long time. Also when I play the movie a window comes up saying "Buffer overrun detected! Program: C:\Program Files\QuickTime\QuickTimePlayer.exe
A buffer overrun has corrupted the program's internal state. The program cannot safely continue execution and must be terminated" I've uninstalled and reinstalled quicktime, but it stops playing the movie. It's pretty frustrating b/c I keep having issues like this.
It's normal for animation programs to take a long time to run. You have to live with this. I don't know what the issue is with the movie, but it may be a machine limitation that you're not responsible for. My questions (actually, make these your questions, rather than getting frustrated) are: (1) How many frames is the program writing, and is this the number you are expecting? If not, maybe there is something weird about the final picture that is generated that is causing Quicktime to crash. This shouldn't happen, but maybe - just maybe it is. (2) By looking at a few of the thumnails of the JPGs, does it look as though the animation WOULD be correct if you could generate and run the complete movie? If so, don't worry too much about a QuickTime/Windows/Mac bug. (3) Does MovieMaker indicate any problems? It barfs out a lot of messages in the terminal window that we usually ignore. Check that it isn't throwing an error. Maybe it starts to write the .mov file but then stops for some reason, leaving the movie in a corrupt state. Again, this shouldn't happen, but I suppose it could. (4) "Buffer overrun" is a clear indication that QuickTime is running out of memory. How large is the movie file? How large are each of the frames? Does it crash immediately? When you start to run the movie? Half way through? Colin Potts

i dont a a laptop and i need help- will the ta's in the cs lab be able to help me?
That depends how clearly you can describe your problem. The more information you have, the better. In descending order of preference, (1) bring your code on a laptop (OK you can't do this), (2) Copy your code onto a USB drive and bring that, (3) Print your code and bring it on paper (preferably with any error messages that refer to line numbers), (4) Have it all in your head and don't forget anything (A last-ditch desperate measure almost guaranteed to fail, but better than staying away!) Colin Potts


how do we put or names in the upper corner of the frame- im having a hard time finding this is JES
Use addText() Remember to set y at 10 or more so that you can see the text. Colin Potts

im trying to run this as a movie, but am having a hard time - how do i make my files become a movie, and how do i watch it?
Did you go to ANY classes on movies? Look at the slides/code page for a link to MovieMaker. Colin Potts

I do have a laptop..somebody else wrote that question underneath me. I can try to stop by with my laptop or send you my code by e-mail.I am not sure what the problem is that's all the buffer overrun tells me.
But answer those questions first to your own satisfaction. YOU have all the information to answer them. We can then work out if you need to do anything. Colin Potts
I'm referring to the questions that I put under your posting. You may not have seen these, since I answered questions out of order. Colin Potts

okay.. so my movie is REALLY big.. i mean, my code works.. i put together my movie.. but now it's a huge file and i don't know how to turn it in.. i've already tried submitting it on t square.. and i've already tried emailing it to my TA .. but neither worked.. should i just submit all that i can and do something else with the movie?!
Submit your code, and we will work something out. Colin Potts


Well I've actually got the whole movie to play before, but then all of a sudden this error message pops up after my sprite starts turning upwards and the movie won't play. If it saves the mov file as corrupted how will I send it on tsquare b/c it might not play even though my code is right. It is supposed to write 470 frames which is does, but it takes like 15min. I have Windows, but I wanted to make sure nothing was wrong with my computer. Thank you
Try to make the movie again, if that doesn't work, e-mail a TA. The length of time that it takes question has been answered multiple times. Thanks! Brittany Duncan
I don't think there's anything wrong with that
I've done the homework for moving my sprite across the screen through the maze and now I'm confused about the assignment because everyone's saying the background is supposed to move. I started the homework last week.
Everyone is not saying anything of the kind. Either solution is satisfactory. Colin Potts
i can't get MovieMaker to work. I have a mac
how do we get the background do scroll up and down?
Ii'm using the code given to create a viewfinder, but no matter what variables I have changed, there is no way for me start the viewfinder at any other point than (1,1). Is there someting huge that I'm missing, because once I find this out, I am close to finishing the project as a whole.
You mean scrolly? It doesn't leave its viewport always at 1,1, so ask yourself how does it move its viewport? Colin Potts
scrolly makes it go diagonal, right? But we don't want diagonal.
That's right. It's just an example that may help you. It isn't the solution to your homework. Colin Potts
I am submitting my hw3.py file, my final complete .mov file, the sprites I used and the background, all in a zipped folder. Is that fine? Do I also have to submit the individual frames needed to generate the movie, or is it enough that they come when the TA runs JES?
Please do not include the frames. The .zip folder is fine. Thanks! Brittany Duncan
im having a hard time, making this into a movie. could someone please help and run me thought thr steps of making this into a movie. thanks!
Colin answered this question earlier by referring the student to the Moviemaker explaination on the Code and Slides page. Thanks! Brittany Duncan
are we required to include the background when we submit our homework?
Only if you have modified it in some way. Thanks! Brittany Duncan
okay so im using a mac, which i usually dont do, and i downloaded moviemaker (which opened up to look just like imovie), i called my movie zeldaRun- then i imported the frames. . . is that right?
I'm trying to load my files and movie and program to t-square, but even when they are all in a zipped folder, t-square says that "The upload size limit of 400 has been exceeded" Should I just upload as much as I can and e-mail the rest to my TA or is there something different that I should be doing?
Thanks
Already answered above Colin Potts
if we put everything in a folder togther, do you have to name it something specific? or can we just use our name or somethign random like Zelda or Sprites?
movie maker isnt running properly on my mac, what should i do?

I'm getting concerned because it has been 30 minutes and my program has only written two frames. Is there anything I can look for to speed it up? I'm fairly certain it is because of the scrolling background, which I don't think I have written correctly.
It sounds like you are doing too much work inside your frame loop(s). Look at your indentation carefully. Colin Potts

My movie maker won't work on my Mac. How am I supposed to submit it?
If you were more explicit in your description of the problem instead of just saying "it won't work" and had not left it until the deadline, somebody could have helped you. You should at least submit your code. Colin Potts

I cant get movie maker to work either, im on windows, but once i have extracted the file, and go to click on the icon... a black screen pops up for 1 second and then closes??
Is it possible to submit the code, background, and sprite to tsquare and then burn the movie file to a CD and turn it in to you (Professor Potts), or our T.A.'s on Thursday? And also, my movie seems really choppy and jerky, even though my code is right. Does Movie Maker have some performace issues in that area?

My program works find except for the fact that at frame 220 (towards the end), it writes frames 221-225 over frames 001-005. ????? :S
Any suggestions on how to fix that?
I really need a TA to help with my code. I'm not sure what to do after I upload all my files. I loaded everything and put zeldaRun() in the command center and everything went fine nothing wrong happened. But When I went to go look for those frames I can't find them anywhere. Did I skip a step or do something horribly wrong?

I really need a TA to help with my code. I'm not sure what to do after I upload all my files. I loaded everything and put zeldaRun() in the command center and everything went fine nothing wrong happened. But When I went to go look for those frames I can't find them anywhere. Did I skip a step or do something horribly wrong?

Nevermind the question before I fixed it




Link to this Page