Jump to content
Sign in to follow this  
madaxe

Need help with GodLib library

Recommended Posts

Hi guys, greetings to everyone;

I am doing some tests in Pure C and GODLib and I need some help in sprite creation:

 

lpSprite = Sprite_Create(&gpPicture->Pixels[ 0 ],
             &gpPicture->Pixels[ 0 ],
             16,
             16,
             4,
             0 );

What is the exact formula to use Pixels[0]? I have tried (x+y*320)/4 but sometimes it doesn't work. Maybe x must to be a multiple of 16?
The size of the sprites must be always 16x16 (or multiple of 16) or is it possible to have other sizes like 1x8 or 24x16?

Thanks in advance,
José Mário Machado a.k.a. MadAxe.
 

Edited by madaxe

Share this post


Link to post
Share on other sites

I wish I could help...

 

I can recommend some good ST books, however.

 

There's Simon Fields' 

Compute!'s Atari ST machine language programming guide

 

it has a chapter about sprite creation.

 

It's my favorite ASM book for the ST; very comprehensive.

recommended

 

take care

Share this post


Link to post
Share on other sites

Hi @Wally1;

Thanks for your tip. I took a look into that book and it's very cool and it has great stuff :)

I have made a little and simple shoot'm'up for Amiga, PC Windows and ZX Spectrum (http://sardonic.planetaclix.pt) and now I'm trying to convert it to Atari using Pure PC and GODLib library. GODLib is very good but it's very vast and sometimes can be very dificult to understand.

By the way, the formula is correct but the width of the sprites must be always a multiple of 16. The height can be what we want.

Cheers,
José Mário Machado a.k.a MadAxe

Edited by madaxe

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...