salut je viens de commencer le darkbasic et aujourdhui de faire un petit programme tt seul comme un grand
,jai decide de faire une balle qui va a garnde vitesse quand on appuie sur une touche mais quand elle bouge il faut pas qu´elle touche des cubes sinon c fini alors jai ecrit ce qui suit mais il y a une erreur qui me dit : " object already exist at line 10".voila mle code :
sync on
sync rate 30
load image " C:\WINDOWS\Bureau\game over.bmp",1
make matrix 1,2000,2000,50,50
make object sphere 1,100
position object 10,-100,0,-100
set object collision to spheres 1
ay#=object angle y(1)
for x= 1 to 100
make object cube x,100
position object x,rnd(200),0,rnd(2000)
set object collision to boxes x
next x
do
if upkey ( ) =1 then move object 1,200
if leftkey ( )=1 then ay#=wrapvalue ( ay#+5)
if rightkey ( )=1 then ay#=wrapvalue ( ay#-5)
if object collision(1,x)>0 then paste image 1,50,50
sync
loop
merci de me dire c quoi le probleme