Login
Back to forumSee the full topicGo to last reply

Posted By

MMS
on 2011-09-06
19:09:34
 Re: Great Giana Sisters

BTW I finished in BASIC the primitive sprite simulation: it works, no color clashes or recoloring. Follows the "big guys" advices: save the part of the screen (not playing any more with with XOR), and when I move, copy back the original bitmap then i copy the sprite to the next place.

Drawbacks:
-Bloody slow and blinking. On emulation 400% speed it is OK, but still blinking
-Only Color 0 and color 3 can be used for the "sprite", means only 1 colored sprite, no shadow or border.
-Translating it into kind of machine code and memory operation, it is exactly what experienced programmers suggested.
-I plan to check the same with POKEs how the speeds are comparable then, and Autrospeed TBC then
-Any comment how to improve it further is appreciated.

10 SCNCLR
20 COLOR1,1:COLOR0,2:COLOR3,3,4:COLOR2,8,5
30 PX=30: PY=32
40 GRAPHIC3,1
50 SSHAPE S$,30,32,40,42
60 DRAW3,30,32 TO 36,32 TO 34,34 TO 40,40 TO 38,42 TO 32,36
70 DRAW3,32,36 TO 30,38 TO 30,32
80 SSHAPE E$,30,32,40,42
90 GOSUB 500: REM DRAW TEST PATTERN
150 REM LETISZTAZAS
160 GSHAPE S$,30,32,0
170 GSHAPE E$,PX,PY,0
180 DO UNTIL I$="E"
190 GET I$
200 XO=PX: YO=PY
210 IF I$="Ý" AND PX>5 THEN PX=PX-5
220 IF I$="Ń" AND PY>5 THEN PY=PY-5
230 IF I$="ť" AND PX<155 THEN PX=PX+5
240 IF I$="‘" AND PY<195 THEN PY=PY+5
250 IF I$<>"" THEN GOSUB 280
260 LOOP
270 GRAPHIC0:END
280 REM SPRITE POSITIONING
290 GSHAPES$,XO,YO,0
300 SSHAPES$,PX,PY,PX+10,PY+10
310 GSHAPEE$,PX,PY,2
320 RETURN
500 REM TEST PATTERN
510 CIRCLE 3,100,100,35,70
520 CIRCLE 1,100,100,20,20
530 CIRCLE 2,110,110,20,50,35
540 DRAW 1,110,110 TO 125,125 TO 90,90
550 DRAW 1,120,125 TO 115,111 TO 80,75
560 RETURN

READY.



Back to top


Copyright © Plus/4 World Team, 2001-2024