Author Topic: Smoothscrolling tilemapper  (Read 35580 times)

0 Members and 2 Guests are viewing this topic.

Offline Ti-DkS

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 143
  • Rating: +21/-1
  • In retro, we trust !
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #60 on: November 09, 2010, 11:07:11 am »
I'm working on one I wanted to achieve, precisely :) It's why I asked ztrumpet about his 16x16 smoothscrolling tilemapper ;D

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Smoothscrolling tilemapper
« Reply #61 on: November 09, 2010, 12:23:38 pm »
Ooh I see in your signature. Sounds interesting. I hope you can manage to finish it. I made a Metroid game before that is called Metroid II: Evolution/Metroid II: The Last Chozo Expansion Set, but it used xLIB so it was pretty slow on a regular 83+ and controls were wonky (although when using Doors CS7 or Celtic III it was slightly faster). When you have some progress done, are you planning to post updates in a new topic about it? :)

Offline Ti-DkS

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 143
  • Rating: +21/-1
  • In retro, we trust !
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #62 on: November 09, 2010, 04:35:06 pm »
Metroid II is a very good game and very impressive regarding Ti-basic power and it's why I wanted to create another one (but more Fusion-like) with Axe because I think power of Axe sufficient to make this game. I tried to do it with xLib but after coding shooting system I was forced to stop because it was too slow :(
Then I wanted an ASM compiler and I found Axe ;D

For the topic it is a good idea and I will foresee that :)
« Last Edit: November 09, 2010, 04:50:18 pm by Ti-DkS »

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Smoothscrolling tilemapper
« Reply #63 on: November 09, 2010, 11:36:02 pm »
Yeah with BASIC it's hard to keep things fast. Also data is pretty large. If bosses aren't hard-coded, I am sure it could remain pretty small. I think Metroid II was about 15 KB if we exclude map data and xLIB APP.

Offline AngelFish

  • Is this my custom title?
  • Administrator
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3242
  • Rating: +270/-27
  • I'm a Fishbot
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #64 on: November 10, 2010, 12:56:29 am »
Yeah with BASIC it's hard to keep things fast. Also data is pretty large.

Especially if you're manipulating a large amount of data. The full screen tilemapper in Battlefield takes a whole five seconds to run (optimized from 9 seconds). You really have to be conscious of how much of the screen you're trying to draw at once.
∂²Ψ    -(2m(V(x)-E)Ψ
---  = -------------
∂x²        ℏ²Ψ

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Smoothscrolling tilemapper
« Reply #65 on: November 10, 2010, 03:00:45 am »
Yeah that too. But by large data I meant for example if you use matrices or lists, each tile takes 9 bytes when stored in matrix files and in the program they take 2-3 bytes. With 300 12x8 maps that grows pretty fast compared to Axe's 1 bytes per tile (or 0.5 if you use 16 tiles per map). You can use strings, but if you use 2 byte tokens like lowercase letters in your maps, those takes more space in the string, plus pasting large strings containing 2 byte tokens with 2nd+RCL can cause RAM clear in the PRGM menu if you're low on memory due to an OS glitch. There are also pics, but then you're limited to 2 tiles, unless you use some form of dynamic tilemapping pixel-testing every side of the tile, which is slow.

Offline Ti-DkS

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 143
  • Rating: +21/-1
  • In retro, we trust !
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #66 on: November 10, 2010, 03:22:35 pm »
Yeah... Does anyone think it is possible to bring some optimizations to increase the speed of ztrumpet's 16x16 tilemapper, however without using "vertical" and "horizontal" commands ? (redrawing tiles each step)

Offline squidgetx

  • Food.
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1881
  • Rating: +503/-17
  • rawr.
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #67 on: November 10, 2010, 03:34:04 pm »
What do you mean by 'redrawing tiles each step'?

as far as I know, vertical/horizontal method of tilemapping is the best one since then you can get away with only drawing the tiles at the edge every frame rather then having to redraw the whole screen.

Offline Ti-DkS

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 143
  • Rating: +21/-1
  • In retro, we trust !
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #68 on: November 10, 2010, 04:18:09 pm »
yes I know... But I want to preserve the back-buffer too :)

Offline AngelFish

  • Is this my custom title?
  • Administrator
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3242
  • Rating: +270/-27
  • I'm a Fishbot
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #69 on: November 10, 2010, 04:31:18 pm »
You can draw directly to the screen in Axe.
∂²Ψ    -(2m(V(x)-E)Ψ
---  = -------------
∂x²        ℏ²Ψ

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #70 on: November 10, 2010, 04:38:31 pm »
Does anyone think it is possible to bring some optimizations to increase the speed of ztrumpet's 16x16 tilemapper?
I'm sure it's easily possible, just I don't want to wade my way through the code right now. :P

Maybe Runer would like to optimize it. ;D

Offline Builderboy

  • Physics Guru
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5673
  • Rating: +613/-9
  • Would you kindly?
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #71 on: November 10, 2010, 04:48:38 pm »
I actually managed to get a tilemapper working at 22 FPS with total redraw, and while thats 3 times slower than Raylins its pretty darn good for complete redraw ^^ But its a bit weird right now because it is jerky because of the different speeds.  I'll see if i can smooth it out.

Offline MRide

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 711
  • Rating: +14/-0
  • You can't see this.
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #72 on: November 10, 2010, 04:56:57 pm »
Wow, I didn't realize how much progress had been made on this.  Someone should give a final version to Sir for his Axe guide. (Which you should finish, btw, Sir O0)

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Smoothscrolling tilemapper
« Reply #73 on: November 11, 2010, 12:08:05 am »
I think he was planning to rewrite a new guide at one point that was up to date and more complete, but I don't know what happened to it.

Offline Ti-DkS

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 143
  • Rating: +21/-1
  • In retro, we trust !
    • View Profile
Re: Smoothscrolling tilemapper
« Reply #74 on: November 11, 2010, 09:17:41 am »
I think a powerful tilemapper what redraws the whole screen can be interesting to develop multi-level grayscale 2d sidescrolling plateformers because it uses only the main buffer and the other can be used to draw backgrounds using "horizontal" and "vertical" commands. Isn't it right ? :)
A guide will be interesting also  ;D
« Last Edit: November 11, 2010, 09:24:54 am by Ti-DkS »