flat assembler
Message board for the users of flat assembler.

Index > DOS > Pong in MASM

Author
Thread Post new topic Reply to topic
Wojtek.wk



Joined: 01 Jan 2010
Posts: 2
Wojtek.wk
Hello Everyone! First of all, sorry for my bad English... I'd like to write some kind of Pong game in MASM, in 320x200, 256-color mode, but more simply one. It only has to implement moving one paddle with keys and ball's bouncing off the walls and paddle. It has to be like Pong with one paddle, and ball moving from one wall to second one. Does anyone has some examples of such a program, some pieces of advice, or anything what could help me? I'm looking for any kind of help. I'd really appreciate it.
Thanks in advance, regards and happy New Year!
Post 01 Jan 2010, 21:51
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4237
Location: 2018
edfed
hello, there, it is not related to MASM, but to fasm, it is a bit better (and different).

there an example of pong.

you need several functions to do what you say.

see this example. not commented, but it works.


Description: one bug, to correct it, the path of balls, paddles and walls should be intersected like a sort of 3D engine with collisions.
Download
Filename: PINGPONG.zip
Filesize: 16 KB
Downloaded: 195 Time(s)

Post 02 Jan 2010, 01:53
View user's profile Send private message Visit poster's website Reply with quote
Wojtek.wk



Joined: 01 Jan 2010
Posts: 2
Wojtek.wk
Thank you for that file. Unfortunately I have to write it in MASM. So maybe does anyone have any version of PONG written in MASM?
Post 02 Jan 2010, 13:09
View user's profile Send private message Reply with quote
Tyler



Joined: 19 Nov 2009
Posts: 1216
Location: NC, USA
Tyler
Why are you asking for MASM on the FASM message board? It shouldn't be too hard to translate, Fasm is based on Tasm's Masm Compatibility Mode http://flatassembler.net/docs.php?article=design. Not that I would know, my limited experience is with Fasm only.
Post 02 Jan 2010, 13:31
View user's profile Send private message Reply with quote
Coddy41



Joined: 18 Jan 2009
Posts: 384
Location: Ohio, USA
Coddy41
Wojtek.wk wrote:
Thank you for that file. Unfortunately I have to write it in MASM. So maybe does anyone have any version of PONG written in MASM?

Well you could take that PONG source up there, and convert it's syntax to MASM if
you really wanted MASM source. Or you could google "Pong demo in MASM" or you
could go to the MASM forum http://www.masm32.com/board/index.php

Good luck

_________________
Want hosting for free for your asm project? You can PM me. (*.fasm4u.net)
Post 02 Jan 2010, 13:37
View user's profile Send private message Visit poster's website Reply with quote
GhostXoPCorp



Joined: 13 Dec 2008
Posts: 199
Location: 01F0:0100
GhostXoPCorp
nasm is probably the easiest to translate to fasm. converting shouldnt be a big problem if u knw ur fasm Wink otherwise its another reason to learn alittle more
Post 03 Jan 2010, 02:47
View user's profile Send private message Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1901
DOS386
> Unfortunately I have to write it in MASM.

Who said this ??? Confused

> Fasm is based on Tasm's Masm Compatibility Mode

NO. It's inspired by TASM's IDEAL Mode and NASM.

See: http://flatassembler.net/docs.php?article=design Wink
Post 07 Jan 2010, 13:33
View user's profile Send private message Reply with quote
Tyler



Joined: 19 Nov 2009
Posts: 1216
Location: NC, USA
Tyler
@DOS386: As you can see, I have yet to read more than the first paragraph of that, probably should have read it all before I went making myself look stupid. Smile
DOS386 wrote:

Who said this ???

Probably his/her professor.
Post 07 Jan 2010, 20:30
View user's profile Send private message Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1901
DOS386
Quote:
Tyler wrote:
Who said this ???
Probably his/her professor.


Let's tell the professor that FASM exists Smile
Post 08 Jan 2010, 08:34
View user's profile Send private message Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4633
Location: Argentina
LocoDelAssembly
And lets also tell that here we are not homework solvers Smile
Post 08 Jan 2010, 16:33
View user's profile Send private message Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1901
DOS386
LocoDelAssembly wrote:
And lets also tell that here we are not homework solvers


Problem typical to PASCAL forums Wink
Post 09 Jan 2010, 02:00
View user's profile Send private message Reply with quote
Tyler



Joined: 19 Nov 2009
Posts: 1216
Location: NC, USA
Tyler
DOS386 wrote:

LocoDelAssembly wrote:

And lets also tell that here we are not homework solvers

Problem typical to PASCAL forums

C++ is worse, the board I use(is down or I would post link) has a whole FAQ for homework. And a sample post of how to ask people to do it for you.
Post 09 Jan 2010, 04:08
View user's profile Send private message Reply with quote
Coddy41



Joined: 18 Jan 2009
Posts: 384
Location: Ohio, USA
Coddy41
High level languages, oh how they and there boards spoil people Confused
Post 09 Jan 2010, 13:50
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.