Search found 1445 matches

by CunningFellow
Thu Jan 30, 2014 3:19 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

That sure sounds good. I have a couple things to understand first. I am really not sure how to make sure that certain tiles end up with certain tile numbers. I use gconvert and right now, I just put the map together and the tiles were numbered as they appeared. I technically don't have a specific t...
by CunningFellow
Thu Jan 30, 2014 3:06 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

This is the version using only bit shifts and no MUL that is 17 cycles long Hmmm, 3 cycles is 3 cycles eh!? All right, I'll need decipher it first, because if I can't maintain it down the road, it's gonna be less useful. :? do the comments showing the bit manipulations not make sense? Both routines...
by CunningFellow
Thu Jan 30, 2014 12:54 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

One thing I can think of. If you arranged the traversable tiles and the non-traversable tiles in the tile_array so that all 4 are contiguous and on a 2^n boundary then you can use the (n-7) top bits with a XOR/AND for the IsSolid() That would make IsSoild() 4 clock cycles rather than 50 ish. Also sa...
by CunningFellow
Tue Jan 28, 2014 6:42 am
Forum: Games & Demos
Topic: Tempest is possible
Replies: 704
Views: 329389

Re: Tempest is possible

I have wasted a lot of time with QT recently, so please tell if you want help with gui. I recently made a firmware updater in qt, that uploads firmware to atmega328 processor via a ethernet bootloader i have hacked together ;P Lunatic, I am going through Qt reading material at the moment. DO you re...
by CunningFellow
Tue Jan 28, 2014 3:54 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

This is the original Set Tile from videoMode3core.s which was 20 clocks ;*********************************** ; SET TILE 8bit mode ; C-callable ; r24=X pos (8 bit) ; r22=Y pos (8 bit) ; r20=Tile No (8 bit) ;************************************ .section .text.SetTile SetTile: #if SCROLLING == 1 ;index...
by CunningFellow
Tue Jan 28, 2014 12:05 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

OH - and as I have said before - could save one more clock and make the scrolling logic easier if people are willing to fix VRAM at a boundary. That might break some peoples games though as you loose 100 to 150 bytes of RAM Well you don't really loose them. You loose continuity and have to juggle se...
by CunningFellow
Mon Jan 27, 2014 11:57 pm
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

Don't know why I didn't see the obvious lsl/swap earlier - we now have a >10% improvement. Must be getting old and slow. Here is a 12 clock version of the core logic in SetTile: Saves 2 clocks over the one in videoMode3core.s Actually saves 3 clocks if you add in the fact that R0 gets left as ZERO ;...
by CunningFellow
Mon Jan 27, 2014 7:11 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

Uze, It only saves one clock. but one clock is one clock :) BTW it also is self protecting from people passing in Y values >32. ; r22 r24 XH XL T ; y7y6y5y4y3y2y1y0 x7x6x5x4x3x2x1x0 - - - - - - - - - - - - - - - - lsl r24 ; y7y6y5y4y3y2y1y0 x6x5x4x3x2x1x0 0 lsl r24 ; y7y6y5y4y3y2y1y0 x5x4x3x2x1x0 0 ...
by CunningFellow
Mon Jan 27, 2014 1:04 am
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

OK. I am out of my depth here I think. That doesn't make sense to me. Maybe enabling scrolling changes the VRAM layout. As I said earlier I have only ever used mode-6 (which I modified the way VRAM works to be faster) and made my own totally custom mode. I have never used any of the tile modes apart...
by CunningFellow
Sun Jan 26, 2014 11:48 pm
Forum: Programming & Software
Topic: Collision and Vram
Replies: 28
Views: 15423

Re: Collision and Vram

OK - I just tried the code you posted by cutting and pasting it in the "arkanoid" which uses mode 3 It produced the expected results for me. So something else is funny happening at your end. Have you started to scroll the screen or something else like that? The ((Y>>3)*H_size+(X>>3)) logic...