Author Topic: Scramble - New game for Amstrad CPC  (Read 12487 times)

0 Members and 1 Guest are viewing this topic.

Offline Ast

  • 6128 Plus
  • ******
  • Posts: 1.077
  • Country: fr
    • Amstrad cpc Website of Ast/iMPACT
  • Liked: 957
  • Likes Given: 726
Re: Scramble - New game for Amstrad CPC
« Reply #25 on: 08:45, 07 March 19 »
What a good game... i really enjoy it !
_____________________

Ast/iMP4CT. "By the power of Grayskull, i've the power"


Amstrad Plus French Forum

All friends are welcomed !

Offline XeNoMoRPH

  • Supporter
  • 6128 Plus
  • *
  • Posts: 728
  • Country: es
  • " ... in space no one , can hear you scream ... "
  • Liked: 1536
  • Likes Given: 1211
Re: Scramble - New game for Amstrad CPC
« Reply #26 on: 12:27, 07 March 19 »
your amstrad news source in spanish language : https://auamstrad.es

Offline shaymanjohn

  • CPC464
  • **
  • Posts: 26
  • Country: gb
  • Liked: 67
  • Likes Given: 27
Re: Scramble - New game for Amstrad CPC
« Reply #27 on: 12:49, 07 March 19 »
Well done PuzCPC - this is fantastic! My favourite arcade game ever, and this version is beautiful!

Offline TotO

  • 6128 Plus
  • ******
  • Posts: 3.697
  • Country: fr
    • ?area=showdonations;u=4
  • Liked: 2818
  • Likes Given: 1695
Re: Scramble - New game for Amstrad CPC
« Reply #28 on: 12:57, 07 March 19 »
What I love on the Vectrex version, is the ambiant background sound... Not in arcade.


https://www.youtube.com/watch?v=JA5O18j0YlQ
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

Offline JayBlood

  • CPC464
  • **
  • Posts: 46
  • Country: fr
  • Liked: 36
  • Likes Given: 37
Re: Scramble - New game for Amstrad CPC
« Reply #29 on: 06:50, 08 March 19 »
You just learn ASM? :o :o ;D Congratulation for this awesome port of that game! Well done!
Jay

Offline mr_lou

  • 6128 Plus
  • ******
  • Posts: 3.067
  • Country: dk
    • index.php?action=treasury
    • 8-bit Memoirs - a Blu-ray diskmag-like eBook about the 8-bit era
  • Liked: 1229
  • Likes Given: 2470
Re: Scramble - New game for Amstrad CPC
« Reply #30 on: 08:03, 08 March 19 »
This look awesome! I wanted a Scramble game for the CPC ever since I was a kid. Looking forward to try this... when I can find some time.

Offline PuzCPC

  • CPC464
  • **
  • Posts: 48
  • Country: si
  • Liked: 149
  • Likes Given: 61
Re: Scramble - New game for Amstrad CPC
« Reply #31 on: 16:55, 08 March 19 »
What I love on the Vectrex version, is the ambiant background sound... Not in arcade.




I prefer CPC music from Targhan! :D
How much headache I suffered, that I could keep it as it is.
Namely, with sound I had problems with a slowdowns. >:(

PuzCPC

Offline Ygdrazil

  • Global Moderator
  • 464 Plus
  • *****
  • Posts: 486
  • Country: dk
  • Liked: 47
  • Likes Given: 248
Re: Scramble - New game for Amstrad CPC
« Reply #32 on: 23:57, 08 March 19 »
Hi PuzCPC
Congratulations on an extremely well done conversion of an all time retro classic!
I am really impressed how well you captured the essence  of the original scramble

You have shown true love to both Scramble and the CPC!

This was one of the first games I played in the arcades, and I always wanted a conversion for the CPC!
I like your "fake" scrolling... This way it should be quite easy to convert the game to both the Enterprise and the ZX spectrum.. so they to can experience your magic coding....
Thanks a lot!
/Ygdrazil

PS. Your first Z80 coding project... Impressive!

Offline Novabug

  • CPC6128
  • ****
  • Posts: 167
  • Country: gb
  • GX4000 and CPC Videomaker!
    • The Novabug-Blog
  • Liked: 169
  • Likes Given: 128
Re: Scramble - New game for Amstrad CPC
« Reply #33 on: 01:26, 09 March 19 »
Hi,
After about ten months of learning and coding it's finally here, my first game in ASM.

I would like to thank everyone who contributed here to CPCwiki source codes and tutorials.
Most of all, Thargan for his sfx, music and all the help that makes the game better than it would be otherwise!

Here are some instructions for Scramble on AMSTRAD CPC 64kb:

Menu                - ESC
Start the game  - FIRE1 for Joystick, A for Keyboard
Credits              - FIRE2 or S (They do not have any meaning except that you start a new game with one click.)

Joystick controls:

Move  - Joystick
Shoot - Joystick FIRE1
Bomb  - Joystick FIRE2 or SPACE

Keyboard controls:

Move   - Cursors keys
Shoot  - A
Bomb  - S
For redefine keys go to the Menu and also more lives can be found there.


And do not forget to show your best score to see who is the best Scramble player here. 8) 


Added CPR for GX4000!

PuzCPC


Great stuff. Will cover this in a future video. Brill.




Offline jjaranda13

  • Dev
  • CPC464
  • *****
  • Posts: 34
  • Country: es
    • 8BP (8 bits de poder)
  • Liked: 102
  • Likes Given: 11
Re: Scramble - New game for Amstrad CPC
« Reply #34 on: 20:19, 09 March 19 »
hi PuzCPC


Congratulations! it is really good game. I love it


Thanks a lot for this game. Good programming technic, good sound, good everything






Offline Scarlettkitten

  • CPC664
  • ***
  • Posts: 62
  • Country: gb
  • Liked: 50
  • Likes Given: 211
Re: Scramble - New game for Amstrad CPC
« Reply #35 on: 21:09, 09 March 19 »
This is fantastic, well done  8)
Sophie Rose:- My musical works https://soundcloud.com/sophierosemusix

Offline jjaranda13

  • Dev
  • CPC464
  • *****
  • Posts: 34
  • Country: es
    • 8BP (8 bits de poder)
  • Liked: 102
  • Likes Given: 11
Re: Scramble - New game for Amstrad CPC
« Reply #36 on: 21:55, 09 March 19 »
hi PuzCPC


could you explain in detail your scroll mechanism? it is really good




Offline Ast

  • 6128 Plus
  • ******
  • Posts: 1.077
  • Country: fr
    • Amstrad cpc Website of Ast/iMPACT
  • Liked: 957
  • Likes Given: 726
Re: Scramble - New game for Amstrad CPC
« Reply #37 on: 22:13, 09 March 19 »
_____________________

Ast/iMP4CT. "By the power of Grayskull, i've the power"


Amstrad Plus French Forum

All friends are welcomed !

Offline Arnaud

  • Supporter
  • 6128 Plus
  • *
  • Posts: 599
  • Country: fr
  • Liked: 482
  • Likes Given: 1037
Re: Scramble - New game for Amstrad CPC
« Reply #38 on: 22:22, 09 March 19 »
hi PuzCPC


could you explain in detail your scroll mechanism? it is really good

Yes i think so, i haven't understand how it works and i am really interested.

Offline pelrun

  • Supporter
  • 6128 Plus
  • *
  • Posts: 617
  • Country: au
    • index.php?action=treasury
  • Liked: 312
  • Likes Given: 189
Re: Scramble - New game for Amstrad CPC
« Reply #39 on: 04:42, 10 March 19 »
They're overdrawing the terrain and enemy sprites every frame, right to left left to right. Each sprite has black pixels on the left right side to erase any artifacts from the previous frame, and the ground fill is just old pixels from previous frames.
« Last Edit: 06:13, 10 March 19 by pelrun »

Offline PuzCPC

  • CPC464
  • **
  • Posts: 48
  • Country: si
  • Liked: 149
  • Likes Given: 61
Re: Scramble - New game for Amstrad CPC
« Reply #40 on: 05:30, 10 March 19 »
They're overdrawing the terrain and enemy sprites every frame, right to left. Each sprite has black pixels on the left side to erase any artifacts from the previous frame, and the ground fill is just old pixels from previous frames.



Hi,

Yes, something like that.
They're overdrawing the terrain and enemy sprites every second frame, left to right.


I think the picture tells more than a thousand words. :)


PuzCPC

Offline Arnaud

  • Supporter
  • 6128 Plus
  • *
  • Posts: 599
  • Country: fr
  • Liked: 482
  • Likes Given: 1037
Re: Scramble - New game for Amstrad CPC
« Reply #41 on: 08:58, 10 March 19 »
Thanks for explanations,
OK in this way you don't have to clear the trail of the scrolling sprites.

The drawback is that the scrolling sprites have to be duplicated, with and whithout offset.

Is the original game works like that ?

Offline Kris

  • 6128 Plus
  • ******
  • Posts: 555
  • Country: fr
  • Team Impact
  • Liked: 220
  • Likes Given: 834
Re: Scramble - New game for Amstrad CPC
« Reply #42 on: 09:59, 10 March 19 »
Very nice port and addictive game: congrats !!

Offline TomEtJerry

  • CPC6128
  • ****
  • Posts: 182
  • Country: fr
  • Liked: 119
  • Likes Given: 0
Re: Scramble - New game for Amstrad CPC
« Reply #43 on: 10:41, 10 March 19 »
Really nice game, it looks like a perfect port of the game (coded from scratch or did you had looked at the arcade code ?); For a Z80 "beginner", that's impressive !

I have just one (little) complain, intro screen would need some polish from a pixel graphist. I think CPC can be better :-).

Offline PuzCPC

  • CPC464
  • **
  • Posts: 48
  • Country: si
  • Liked: 149
  • Likes Given: 61
Re: Scramble - New game for Amstrad CPC
« Reply #44 on: 13:13, 10 March 19 »
Thanks for explanations,
OK in this way you don't have to clear the trail of the scrolling sprites.

The drawback is that the scrolling sprites have to be duplicated, with and whithout offset.

Is the original game works like that ?


Exactly! And at the same time it draws the ground inside.
Yes, sprites take a lot of space. And must be a compiled sprites.
Otherwise, it's not fast enough. :)
I do not know how the original works, I did not have the original source code.


Really nice game, it looks like a perfect port of the game (coded from scratch or did you had looked at the arcade code ?); For a Z80 "beginner", that's impressive !

I have just one (little) complain, intro screen would need some polish from a pixel graphist. I think CPC can be better :-).
I coded from scratch.
Intro screen is not my work. I made it even worse. :D


PuzCPC

Offline ervin

  • Supporter
  • 6128 Plus
  • *
  • Posts: 1.330
  • Country: au
    • index.php?action=treasury
  • Liked: 988
  • Likes Given: 1159
Re: Scramble - New game for Amstrad CPC
« Reply #45 on: 14:12, 10 March 19 »
Exactly! And at the same time it draws the ground inside.
Yes, sprites take a lot of space. And must be a compiled sprites.
Otherwise, it's not fast enough. :)
I do not know how the original works, I did not have the original source code.

I coded from scratch.
Intro screen is not my work. I made it even worse. :D

PuzCPC

Hmmm, interesting.
I'd love to have a look at your compiled sprite code.
I'm doing some work with compiled sprites at the moment, and I'd like to see some other examples.

Would it be ok to have a look at your sprite code?


My (cancelled) entry for the CPCRetroDev 2017 Competition http://www.cpcwiki.eu/forum/programming/my-cpcretrodev-2017-entry/
FAST line drawing in CPCtelera http://www.cpcwiki.eu/forum/programming/drawing-lines-with-cpctelera-sdcc/
RUNCPC My entry for the CPCRetroDev 2015 Competition http://www.cpc-power.com/index.php?page=detail&num=12494

Offline TotO

  • 6128 Plus
  • ******
  • Posts: 3.697
  • Country: fr
    • ?area=showdonations;u=4
  • Liked: 2818
  • Likes Given: 1695
Re: Scramble - New game for Amstrad CPC
« Reply #46 on: 14:42, 10 March 19 »
I think the picture tells more than a thousand words. :)
It looks a bit like Pac-Man emulator sprites and R-Type scrolling. ;)
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

Offline VincentGR

  • 6128 Plus
  • ******
  • Posts: 1.231
  • Country: gr
    • Parts from the past.
  • Liked: 707
  • Likes Given: 1797
Re: Scramble - New game for Amstrad CPC
« Reply #47 on: 14:44, 10 March 19 »
It looks a bit like Pac-Man emulator sprites and R-Type scrolling. ;)


and jetpac 😀

Offline PuzCPC

  • CPC464
  • **
  • Posts: 48
  • Country: si
  • Liked: 149
  • Likes Given: 61
Re: Scramble - New game for Amstrad CPC
« Reply #48 on: 15:13, 10 March 19 »

Hmmm, interesting.
I'd love to have a look at your compiled sprite code.
I'm doing some work with compiled sprites at the moment, and I'd like to see some other examples.

Would it be ok to have a look at your sprite code?





Of course! :)


Code: [Select]
.SPRITE
LD A,17
LD BC,&C850
LOOP:
LD (HL), BYTE_01
INC L
LD (HL), BYTE_02
SET 3,H
LD (HL), BYTE_03
DEC L
LD (HL), BYTE_04
SET 4,H
...
RES 3,H
...
SET 5,H
...
RES 4,H
...
SET 3,H
...
SET 4,H
...
ADD HL,BC
DEC A
OR A
JR NZ,LOOP
RET
.SPRITE_01
LD (HL), BYTE_01
INC L
LD (HL), BYTE_02
SET 3,H
LD (HL), BYTE_03
DEC L
LD (HL), BYTE_04
SET 4,H
...
RES 3,H
...
SET 5,H
...
SET 3,H
...
RES 4,H
...
RES 3,H

RES 5,H
LD A,L
ADD &50
LD L,A
JR NC,SKIP
INC H
SKIP:
LD (HL), BYTE_17
INC L
LD (HL), BYTE_18
SET 3,H
LD (HL), BYTE_19
DEC L
LD (HL), BYTE_20




Offline ervin

  • Supporter
  • 6128 Plus
  • *
  • Posts: 1.330
  • Country: au
    • index.php?action=treasury
  • Liked: 988
  • Likes Given: 1159
Re: Scramble - New game for Amstrad CPC
« Reply #49 on: 15:27, 10 March 19 »

Of course! :)

Code: [Select]
.SPRITE
LD A,17
LD BC,&C850
LOOP:
LD (HL), BYTE_01
INC L
LD (HL), BYTE_02
SET 3,H
LD (HL), BYTE_03
DEC L
LD (HL), BYTE_04
SET 4,H
...
RES 3,H
...
SET 5,H
...
RES 4,H
...
SET 3,H
...
SET 4,H
...
ADD HL,BC
DEC A
OR A
JR NZ,LOOP
RET
.SPRITE_01
LD (HL), BYTE_01
INC L
LD (HL), BYTE_02
SET 3,H
LD (HL), BYTE_03
DEC L
LD (HL), BYTE_04
SET 4,H
...
RES 3,H
...
SET 5,H
...
SET 3,H
...
RES 4,H
...
RES 3,H

RES 5,H
LD A,L
ADD &50
LD L,A
JR NC,SKIP
INC H
SKIP:
LD (HL), BYTE_17
INC L
LD (HL), BYTE_18
SET 3,H
LD (HL), BYTE_19
DEC L
LD (HL), BYTE_20


Very interesting!

I'm wondering if it can be optimised a little bit.
 8)

Code: [Select]
ADD HL,BC
DEC A
OR A
JR NZ,LOOP
RET

Is the OR A needed?

Actually, I notice that you're using ADD HL,BC.
Is DE free in your sprite loop?
If it is, you can use ADD HL,DE instead.
That will then allow you to replace the looping code I've quoted just above with DJNZ, if you use B as the loop counter instead of A.
« Last Edit: 15:32, 10 March 19 by ervin »
My (cancelled) entry for the CPCRetroDev 2017 Competition http://www.cpcwiki.eu/forum/programming/my-cpcretrodev-2017-entry/
FAST line drawing in CPCtelera http://www.cpcwiki.eu/forum/programming/drawing-lines-with-cpctelera-sdcc/
RUNCPC My entry for the CPCRetroDev 2015 Competition http://www.cpc-power.com/index.php?page=detail&num=12494