Computer Science Canada MOUSE CURSORS, help ? |
Author: | TheHobbit [ Thu Jan 15, 2009 10:51 pm ] |
Post subject: | MOUSE CURSORS, help ? |
hey guys i am trying to get an image where my mouse happens to be for a game. im thinking cross hairs, since its a simple shoot 'em up. i've already tried drawing a simple X by taking the mousepos and using it as t he X's origin points. the problem there is that its too laggy, the time taken to redraw gives the actual mouse enough time to move some place else any suggestions ? |
Author: | S_Grimm [ Fri Jan 16, 2009 8:40 am ] |
Post subject: | RE:MOUSE CURSORS, help ? |
Are you double or triple buffering? Whats your FPS? Is there a delay in the program? are you Bottlenecking by having your code perform too many processes at one time? |
Author: | TheHobbit [ Fri Jan 16, 2009 8:37 pm ] | ||
Post subject: | Re: MOUSE CURSORS, help ? | ||
mmkay , after all your suggestions, i tried to narrow down to what was causing the lag a few things a) delay at the end of the paint method, its set to a 1000 now, because the 'characters' need that time to respawn b) since the background is an image, the drawn cursor doesn't even show up unless i don't draw the background. since nothing can be done about the delay, i tried to make a separate paint method for the crossHair and run it in the graphids method , but that didnt really work,i dont even know if you can have 2 paint methods ( but it should be able to since i've used a double buffer before and thats a paint method ). maybe it has to do the way im putting it ?
im guessing the way i set up that method is wrong or something ? any ideas of how to work around that ? p.s i also have a buffer problem if any one has a solution : adding a double buffer disables my mouse functions ,WHY ? |