Ultimate Amiga

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Issue with bob flickering and sprite crashing and abk merging  (Read 3164 times)

0 Members and 1 Guest are viewing this topic.

xboxisfinished

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 205
  • Generic Amiga User
    • gamemakermagazine.com
Issue with bob flickering and sprite crashing and abk merging
« on: December 20, 2015, 03:17:21 PM »

In my game you need to form a certain pattern to pass the level. When I press A it plots a bob on the screen as I move up,left,down or right and I press A again I plot another bob there...the more bobs I plot the more flicker and the faster and more severe flicking happens. In the while loop statement I have bob update: wait vbl

but when I try to put double buffer right after screen on the program the screen refresh rate and performance drops from say 25 fps to instant 5 fps and everything goes under crawl. If I put double buffer inside a loop it instantly says already screen double buffering error. If I remove the double buffer concept the bobs flickers.

Of course the reason the bob flickers is because I go ahead and do this:

Bob n, x,y, image

But if I do paste bob x,y, image instead I can have a thousand of them and no flickers happen. However, I sprout another problem. Say I have five paste blobs 1,2,3,4, and 5 starting from left to right. if I want to move on top of bob three pasted and press del to delete it...i cannot. I have to override it with another bob..but I don't want to override it with another bob..I want to remove it from screen. I cannot use Bob Off n to do that..because it relies on real bob not pasted bob to be removed. If I paste a bob that is 0,0,0,0 all black then it is transparent and till not show on top of the pasted bob. So I am stuck in a loop. Any help would be great.

When I replaced the command bob n,x,y,image with sprite n,x hard(x), y hard(y), image to plot it on screen it plots the first sprite (not correct colors), second it does not plot it, third it plots it, forth it does not plot and then crashes the Amiga.

Finally, I have one final request. I want to use another abk sprites/bobs for image font..how do I load two .abk file or do I need to put everything in one single .abk file? How do I use more than one abk file without causing a problem?
Logged

SamuraiCrow

  • compile-time wierdo
  • Forum Mod
  • A1200
  • *****
  • Karma: 5
  • Offline Offline
  • Gender: Male
  • Posts: 946
  • Compile-time wierdo
Re: Issue with bob flickering and sprite crashing and abk merging
« Reply #1 on: December 21, 2015, 03:32:33 PM »

Have you looked into the AutoBack and Screen Swap commands?
Logged

idrougge

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 12
  • Generic Amiga User
Re: Issue with bob flickering and sprite crashing and abk merging
« Reply #2 on: January 29, 2016, 01:39:58 PM »

Why don't you paste whatever background tile the bob was supposed to be obscuring? You can keep an array of background tiles for that.
Logged

SamuraiCrow

  • compile-time wierdo
  • Forum Mod
  • A1200
  • *****
  • Karma: 5
  • Offline Offline
  • Gender: Male
  • Posts: 946
  • Compile-time wierdo
Re: Issue with bob flickering and sprite crashing and abk merging
« Reply #3 on: January 29, 2016, 07:20:28 PM »

Bank Swap will help with the switch between banks.
Logged
Pages: [1]   Go Up
 

TinyPortal 2.2.2 © 2005-2022