Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

2D All the way! / For Dark Basic Pro I dont Understand the animation proccess.

Author
Message
The Lone Programmer
21
Years of Service
User Offline
Joined: 29th Jan 2003
Location: California, USA
Posted: 29th Sep 2003 07:35
I am using the dbp alienwear demo. I want to try to animate my sprite. This is the code i am suppose to use.


Well this is what I put in the spots.. I only really understood the sprite number part and image number part.


Well the only thing it says wont work is cant find filename. Can someone explain to me what I did wrong and what everything means.... Also if anything else needs to be added to pro in the animation process. My image is 100*100.

Thanks
Nicolas

Future Company Name = Blazing Fire
Current Website Name = Blazing Fire
Future Number is Eleventy
Van B
Moderator
21
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 29th Sep 2003 12:57
create animated sprite 1,"Novice_Small.bmp",100,100,1




Van-B

My cats breath smells of cat food.
CloseToPerfect
21
Years of Service
User Offline
Joined: 20th Dec 2002
Location: United States
Posted: 30th Sep 2003 02:00
create animated sprite sprite number,"filename",number of cuts across,number of cuts down,image number

if your animation slide has 4 images across and 4 images down for a total of 16 images in the slide, you would put

create animated sprite 1,"Novice_Small.bmp",4,4,1
The Lone Programmer
21
Years of Service
User Offline
Joined: 29th Jan 2003
Location: California, USA
Posted: 30th Sep 2003 02:46
My code isnt working.... It says image already exists.... this is my whole code.



whats wrong with it.... anyone want to give me some pointers?

Thanks
Nicolas

Future Company Name = Blazing Fire
Current Website Name = Blazing Fire
Future Number is Eleventy
CloseToPerfect
21
Years of Service
User Offline
Joined: 20th Dec 2002
Location: United States
Posted: 30th Sep 2003 07:19
try this. I think I explained all well enough, but ask question if you need.
CTP

rem create the sprite outside of the loop otherwise it will try to duplicate it.

create animated sprite 1,"Novice_Small.bmp",4,4,1

use play sprite to set the timing and frames to use, again outside the main loop, but you can call it over to change the timming and frames

rem all 16 frames change every 100 millisec

play sprite 1,0,15,100

do

rem in the loop use sprite to show the sprite, use the image number from the create command

sprite 1,100,100,1

loop
Dsarchy
20
Years of Service
User Offline
Joined: 4th Oct 2003
Location: UK- Kent
Posted: 21st Oct 2003 22:10
your loading the image over and over again as it is in the loop. Try leaving it out of the loop then it should work.



please dont bite my head off if i get it wrong im am just trying to help. Whether that code works or not i dont know but the comment on the image being loaded over and over agin is true.

vivi

?

Login to post a reply

Server time is: 2024-04-27 21:22:05
Your offset time is: 2024-04-27 21:22:05