This is an old revision of the document!
Systems Programming Course Notes wiki
Some people have reported problems logging into the wiki. There seems to be two sources of problems experienced:
If you are confident you are using the correct username and password, and are using a version of Internet Explorer, it is suggested that you use a different browser, such as Firefox, Safari, or Chrome.
If the “Secure Login” doesn't seem to be working for you, the behavior seems to occur when user passwords contain symbols like quote marks and asterisks. In which case, you can either:
For those unfamiliar, here is a page on wiki editing syntax that can be used here.
This is a space for members of the Systems Programming class to create a source of information reflective and assisting to the course.
Aside from assignments that may have you specifically perform operations here, you should contribute when you encounter any of the following:
If you ever are curious on the information on how everything is working with using SDL functions you can explore them! The file path is /usr/include/SDL. Remember you can also see man pages on these ex: man SDL_BlitSurface
Make sure when you blit an image onto a surface that both the image and surface have compatible formats such as 32-bit as this wastes useful processing power switching the formats around if they are not the same. Also, once you are done with the image, be sure to release the allocated memory that you worked with during the application.
If you'd like to play a sound through SDL, it's best to use the extension library SDL_mixer. There are two basic types of sound in the SDL_mixer: Mix_Music for songs and music, and Mix_Chunk for sound effects such as footsteps or voice lines. As for actually playing said audio, you should use the function “Mix_OpenAudio” to first initialize the mixer's functions. This function has 4 arguments. The frequency, format, number of channels, and sample size of the clip being played. Now that SDL_mixer is initialized, You can use “Mix_LoadMUS” and “Mix_LoadWAV” to music and sound effects respectfully. After the audio has run its course, don't forget to free the music man!
-The SDL_GetMouseState(int *x int *y) function allows the user to receive any information on both the buttons being pressed and the location of the mouse with the SDL_BUTTON() macros and the x and y integers respectfully.
-The SDL_GetKeyState(int *numkeys) points the numkeys pointer at an array indexed with SDLK_* symbols. Each pointer in the array corresponds with a button on the keyboard. If the value is 1, the key is pressed and the opposite for if the value is 0. It is important to note that the returned pointer should not be freed by the caller as it is a pointer to an internal SDL array.
You are a square that constantly speeds to the right. With only the ability to jump, you must maneuver around the obstacles that may cause you harm.
In the kingdom of Polygonia, The twin nobles Prince Radii and Princess Diameter have been kidnapped by the Notorious Troll Nunia. Nunia you may ask? Nunia business. As the only shape able to jump, you must go on a great voyage to stop Nunia from enacting his terrible plans, rescue Radii and Diameter from a inevitable death, and save Polygonia from plunging into darkness.
Things that need to be figured out for thee impossible game
+ Side/vertical scrolling metroid-vania style game; post apocalypse themed
+ Physics based moon/planet/asteroid lander
+ Single screen mouse-click shooter, in the vein of early browser-based flash shooters
Will post finalized idea here, working stuff out on paper