X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=course%2Fsemester2%2Fpprog%2Fassignment0%2Fnbody.c;h=d23b134a2f1da41275e0b009eaf7db3774185af1;hb=c37245b967333688ad4c2bd842e7ab5ff4d0b8ec;hp=76c90675cc787e272328b716a377a3f163a426a5;hpb=d4f132d40be6b93d54edca1e9af4051ec6c2d0b8;p=matches%2Fhonours.git diff --git a/course/semester2/pprog/assignment0/nbody.c b/course/semester2/pprog/assignment0/nbody.c index 76c90675..d23b134a 100644 --- a/course/semester2/pprog/assignment0/nbody.c +++ b/course/semester2/pprog/assignment0/nbody.c @@ -351,10 +351,12 @@ void System_Step(System * system) } + /* Reflections if ((system->bodies+a)->x[0] + system->x[0] < 0 || (system->bodies+a)->x[0] + system->x[0] > 640) (system->bodies+a)->v[0] = -(system->bodies+a)->v[0]; if ((system->bodies+a)->x[1] + system->x[1] < 0 || (system->bodies+a)->x[1] + system->x[1] > 480) (system->bodies+a)->v[1] = -(system->bodies+a)->v[1]; + */ } @@ -476,25 +478,6 @@ void System_Draw(System * system) } } -/** - * @function Process_Events - * @purpose Handle any SDL events recieved. - */ -void Process_Events() -{ - SDL_Event event; - while (SDL_PollEvent(&event)) - { - switch(event.type) - { - case SDL_QUIT: - exit(EXIT_SUCCESS); - break; - } - } - //SDL_Delay(1); -} - #endif //_GRAPHICS_H //EOF