| |
ITT Discuss SDL, Techniques, Etc
OniLink10 |
|

C++ Programmer, Unofficial Physicist, and Unofficial Chemist
![Super Happy Heart Badge [*]](https://archive.mfgg.net/html/badges/shappyheart.gif) ![Secret Santa Badge [*]](https://archive.mfgg.net/html/badges/present.gif)

Group: Members
Posts: 3920
Member No.: 4907
Joined: 19-February 08
Status: (0d)
![[--]](style_images/mfgg2_skin/warn_nosuspend.gif)

|
ITT we shall discuss Techniques for good SDL Games. This INCLUDES PyGame. I'll go first.
1: For different Rooms, have only 1 Global SDL_Surface*, and change it to load a new Screen every time you change Rooms. Then do Room Setup, including Creating Objects, which should be stored in Classes, then do a Loop that runs while you're still in the room.
2: Make sure each Room's Code is stored in seperate Functions.
3: Have a Global Room variable that tells which room you are currently in.
4: Be sure to have a Room Switcher Function that switches between rooms, and run it in a while(true) loop. To exit, use exit(0).
5: Store all Objects in Classes.
6: For Emulated GM Collision Events, use SDL_collide and Vectors.
This post has been edited by OniLink10 on Dec 7 2008, 02:45 PM
--------------------
| QUOTE (Xgoff @ Sep 10 2009 @ 06:11 PM) | did you try hello's engine
make sure to not ****ing change anything before using it! |
|
|
|
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:
Track this topic
Receive email notification when a reply has been made to this topic and you are not active on the board.
Subscribe to this forum
Receive email notification when a new topic is posted in this forum and you are not active on the board.
Download / Print this Topic
Download this topic in different formats or view a printer friendly version.
[ Script Execution time: 0.0543 ] [ 15 queries used ] [ GZIP Enabled ] [ Server Load: 1.50 ]
| |