Sorry for bothering,i have individuated the error.
Usually i use function in this manner:make all calculation of position and AFTER the calculation i display the object....but in this manner if no enemy are onscreen no object is created because the display bullet function is AFTER the condition check...so if the condition is positive...no bullet displayed -_-
I have simply put the drawimage as one of the first command and voila,all go well now!
Usually i use function in this manner:make all calculation of position and AFTER the calculation i display the object....but in this manner if no enemy are onscreen no object is created because the display bullet function is AFTER the condition check...so if the condition is positive...no bullet displayed -_-
I have simply put the drawimage as one of the first command and voila,all go well now!