Jump to content

Search the Community

Showing results for tags 'pointer'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Atari Systems
    • Atari 2600
    • Atari 5200
    • Atari 7800
    • Atari Lynx
    • Atari Jaguar
    • Dedicated Systems
    • Atari 8-Bit Computers
    • Atari ST/TT/Falcon Computers
  • Gaming General
    • Classic Gaming General
    • Classic Computing
    • Modern Gaming
    • Prototypes
    • Arcade and Pinball
    • Emulation
    • Hardware
    • Gaming Publications and Websites
    • International
  • Marketplace
  • Community
  • Game Programming
  • Site
  • Classic Gaming News
  • The Club of Clubs's Discussion
  • I Hate Sauron's Topics
  • 1088 XEL/XLD Owners and Builders's Topics
  • Atari BBS Gurus's Community Chat
  • Atari BBS Gurus's BBS Callers
  • Atari BBS Gurus's BBS SysOps
  • Atari BBS Gurus's Resources
  • Atari Lynx Programmer Club's CC65
  • Atari Lynx Programmer Club's ASM
  • Atari Lynx Programmer Club's Lynx Programming
  • Atari Lynx Programmer Club's Music/Sound
  • Atari Lynx Programmer Club's Graphics
  • The Official AtariAge Shitpost Club's Shitty meme repository
  • The Official AtariAge Shitpost Club's Read this before you enter too deep
  • Arcade Gaming's Discussion
  • Tesla's Vehicles
  • Tesla's Solar
  • Tesla's PowerWall
  • Tesla's General
  • Harmony/Melody's CDFJ
  • Harmony/Melody's DPC+
  • Harmony/Melody's BUS
  • Harmony/Melody's General
  • ZeroPage Homebrew's Discussion
  • Furry Club's Chat/RP
  • PSPMinis.com's General PSP Minis Discussion and Questions
  • PSPMinis.com's Reviews
  • Atari Lynx 30th Birthday's 30th Birthday Programming Competition Games
  • 3D Printing Club's Chat
  • Drivers' Club's Members' Vehicles
  • Drivers' Club's Drives & Events
  • Drivers' Club's Wrenching
  • Drivers' Club's Found in the Wild
  • Drivers' Club's General Discussion
  • Dirtarians's General Discussion
  • Dirtarians's Members' Rigs
  • Dirtarians's Trail Runs & Reports
  • Dirtarians's Wrenching
  • The Green Herb's Discussions
  • Robin Gravel's new blog's My blog
  • Atari Video Club's Harmony Games
  • Atari Video Club's The Atari Gamer
  • Atari Video Club's Video Game Summit
  • Atari Video Club's Discsuuions
  • Star Wars - The Original Trilogy's Star Wars Talk
  • DMGD Club's Incoming!
  • DASM's General


There are no results to display.

There are no results to display.


  • AtariAge Calendar
  • The Club of Clubs's Events
  • Atari BBS Gurus's Calendar
  • ZeroPage Homebrew's Schedule

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start










Custom Status



Currently Playing

Playing Next

Found 1 result

  1. I'm attempting to mix bB code and Assembly to do some more advanced things, such as having a single bank of colors/sprites that are assigned to players based on a variable. Note that this is using the DPC+ bB kernel. The issue here is in regards to pointers and how flexible they are in Assembly, because I don't know. For instance, I have a set of colors for a sprite: asm milCol .byte $D6 .byte $D6 .byte $D6 .byte $D6 .byte $D6 .byte $D6 .byte $D6 end I want to call this bank of color values and assign them to every player in a loop, in case I want to assign a specific color to individual players later. I noticed when looking at the game's assembly that colors are assigned like so: .L0241 ; player2color: lda #<(playerpointers+20) sta DF0LOW lda #(>(playerpointers+20)) & $0F sta DF0HI LDX #<playercolorL0241_2 STX DF0WRITE LDA #((>playercolorL0241_2) & $0f) | (((>playercolorL0241_2) / 2) & $70) STA DF0WRITE . ; .L0242 ; player3color: lda #<(playerpointers+22) sta DF0LOW lda #(>(playerpointers+22)) & $0F sta DF0HI LDX #<playercolorL0242_3 STX DF0WRITE LDA #((>playercolorL0242_3) & $0f) | (((>playercolorL0242_3) / 2) & $70) STA DF0WRITE . ; There's a pattern--players 1-9 are assigned their low and high points using the (playerpointers+x) phrase where x = 20 + (sprite# * 2) I'm attempting the following: for temp1 = 0 to 3 temp2 = 20 + temp1 + temp1 asm .enemycolor lda #<(playerpointers+temp2) sta DF0LOW lda #(>(playerpointers+temp2)) & $0F sta DF0HI LDX #<milCol STX DF0WRITE LDA #((>milCol) & $0f) | (((>milCol) / 2) & $70) STA DF0WRITE end next This should calculate where the high and low points for the player pointer will be and add it to playerpointers in order to point to the right location. It compiles, but doesn't work. Is there some special way I need to address the temp2 variable in order to allow it to be added to playerpointers? This also applies to sprites. I would like the sprite for any player to be chosen based on a certain variable (in my case it's enemy0, enemy1, enemy2, etc.) so, if enemy0 is 1, it will grab a certain sprite for that player and set it to a certain color, without the redundancy of repeating sprite and color tables for each possible combination for each player. There are two ways to do it. Either I could have a series of statements like the above .enemycolor for each possible color/sprite and then adjust the player's pointer based on a variable to point to the sprite/colors that are applicable, or (preferably) I need some way to change which data set is being loaded on the fly, such as the following mock-up: for temp1 = 0 to 3 temp2 = 20 + temp1 + temp1 data playerColors milCol, milCol, milCol, drkCol end temp3 = enemy0[temp1] temp4 = playerColors[temp3] asm .enemycolor lda #<(playerpointers+temp2) sta DF0LOW lda #(>(playerpointers+temp2)) & $0F sta DF0HI LDX #<temp4 STX DF0WRITE LDA #((>temp4) & $0f) | (((>temp4) / 2) & $70) STA DF0WRITE end next ... asm milCol .byte $D6 .byte $D6 .byte $D6 .byte $D6 .byte $D6 .byte $D6 .byte $D6 drkCol .byte $00 .byte $00 .byte $00 .byte $00 .byte $00 .byte $00 .byte $00 end So, two questions: 1. Is there any way to dynamically adjust the value being used for the player's pointer? 2. Is there any way to dynamically adjust which data set is being pointed to?
  • Create New...