SRL Archive - Delphi/FPC Help and Tutorials

Snake :)


weequ

2009-09-24 00:36:57

Attachment contains the game and the sourse code. The sourse really sucks but hopefully I will improve it :cool:
Everything is coded with WriteLn etc…

Please comment and help me improve it ;)

Edit: Aww just got 99 points…So close to 100 :(

Edit: Forgot to post controls: w=up, s=down, a=left, d= right

footballjds

2009-09-24 18:43:25

cool. graphics need help but nice :)

got to 69. im not good with my left hand, use the arrow keys!!

weequ

2009-09-24 21:50:27

From: footballjds
cool. graphics need help but nice :)

got to 69. im not good with my left hand, use the arrow keys!!
I dont know yet how to code it for arrow keys :(

senrath

2009-09-24 22:50:21

Try this to use arrow keys:

'H': if not (Suunta = 2) then Suunta := 1;
'P': if not (Suunta = 1) then Suunta := 2;
'K': if not (Suunta = 4) then Suunta := 3;
'M': if not (Suunta = 3) then Suunta := 4;

Also, what version of Delphi did you use?

weequ

2009-09-25 17:42:12

I have dev-pascal 1.9.2 and freepascal 2… . I use dev-pascal becouse I dont like freepascal at all :D

Edit: I would like to see all commands i can use from somewhere but i cant find where..