Example

Purper conversion

5

was8bit 2021-09-28 03:54 (Edited)

..... blending Timo's code with the Purper code to get Timo's perfect sprite to cell detection :)

V0.1
... using Purper colors
... combined both graphics together
... changed player graphic to Purper character (non animated)
... disabled Y-scrolling
V0.2
... slimed down Timo's scrolling code to match Purper needs
... worked out all bugs in simplified scroll code
V0.3
... removed up/down arrow movement
... added (A) button jump and gravity
V0.4
... added player animation
V0.5
... added header
V0.6
... added sky blocks
V0.62
... fixed jumping up into blocks
... added coin blocks (normal and secret)
... added collecting coins


G-9 2021-10-01 14:12

Noice update :)


was8bit 2021-10-01 16:34 (Edited)

Thanky :)

... for inspiration am using world 1-1 from the original NES super mario bros ... as you may already noticed it isnt going to be an exact copy.. i mean, these things still exist and can be played... i like to create different variations .... not 100% sure yet on the variation...

I still want to add upgrades for mar.. i mean, purper... and then enemies.... also win or lose for the world...

I wanted to contribute a game most people will enjoy :) ....


was8bit 2021-10-01 16:36 (Edited)

Btw, can u guess what purper is short for ;)


was8bit 2021-10-01 16:44 (Edited)

I would like to also add 3 more worlds... sky, water, and dungeon.... if you have noticed there are 4 blocks of grayed out things at the top if the screen... so my rough idea of a theme is that your kingdom has been usurped and you are trying to rescue your kingdom and reinsert yourself as the rightful ruler of the kingdom... and you must find all 4 pieces to accomplish this... as the worlds will be randomly created, there will be no guarantee you can win each world and find each thing every go... it may take a few tries to accomplish your task...


CreatorJo 2021-10-01 21:39

Is Purper short for Purple Person?


Wild William 2021-10-02 03:08

I’m still crying myself to sleep tryna figure out proper collision, not one pixel per frame Coll


was8bit 2021-10-02 04:28

@Diamond... yes, u got it :)


was8bit 2021-10-02 04:35 (Edited)

@ wildwiliam, i still fall back to Timo's code...

https://lowresnx.inutilis.com/topic.php?id=318

The core of it is this...

' TIMO'S CODE...
'X,Y: PLAYER POSITION IN PIXELS
'R IS SET TO TRUE IF NO COLLISION WITH MAP
SUB CHECKCOLL(XX,YY,R)
'CHECK ALL CORNERS
X=XX+SCRX
Y=YY
R=-1
CALL CHECKCELL(X\8,Y\8,R)
CALL CHECKCELL((X+7)\8,Y\8,R)
CALL CHECKCELL(X\8,(Y+7)\8,R)
CALL CHECKCELL((X+7)\8,(Y+7)\8,R)
END SUB
SUB CHECKCELL(X,Y,R)
C=CELL.C(X,Y)
IF C<>0 THEN
R=0
END IF
END SUB


And you use it with

CALL CHECKCOLL(POSX,POSY,R)

If R then (do the move)

With a +-1 added to x or y depending on which direction you are going

Its tricky because sprites use pixel coordinates based on the position of their upper left corner... while cells use cell coordinates (8x8 pixel sized blocks) ...



Wild William 2021-10-03 22:56 (Edited)

I tried doing that but the player stops a few pixels over the ground if they fall too quickly before falling again, and I don’t want to compromise the max speed, man I might look at a disassembly of mario or something soon


Log in to reply.