Guaranteed Malloc and Free?
Posted: Thu May 22, 2008 1:49 pm
If we wanted to absolutely guarantee that one function was executed before a game started to initialize something and also that another routine was called before exiting, where would we put calls to these two routines?
I wanted to load binary files of structures at game start into dynamically allocated buffers, then make certain those buffers are freed upon exiting.
Would view.CreateActor and view.DestroyActor be good places to call these routines?
I thought I heard about a main() and exit() function one time on the forums but I cannot find the thread.
I wanted to load binary files of structures at game start into dynamically allocated buffers, then make certain those buffers are freed upon exiting.
Would view.CreateActor and view.DestroyActor be good places to call these routines?
I thought I heard about a main() and exit() function one time on the forums but I cannot find the thread.