Collisions

Discuss whatever you want here--both QB and non-QB related. Anything from the DEF INT command to the meaning of life!

Moderators: Pete, Mods

Post Reply
User avatar
{Nathan}
Veteran
Posts: 1169
Joined: Thu Aug 19, 2004 6:08 pm
Location: The wetlands of central Ohio, USA
Contact:

Collisions

Post by {Nathan} »

For my text game, I need to do collision, but I do not use a "true" map. Is there some way to do a point command in text mode? I was thinking about "talking" directly to &HB000, but is there an easyer way?

I know, I cannot spell; at all! :roll:
Image
Nixon

follow the mouse?

Post by Nixon »

Are you talking about clicking somewhere on the screen while the chr 2 moving to that position? if so just use a mouse thing and set where the postion of the mouse was when clicked and make the chr move there and wait fr the next click. I've done it before and it is really easy.
User avatar
{Nathan}
Veteran
Posts: 1169
Joined: Thu Aug 19, 2004 6:08 pm
Location: The wetlands of central Ohio, USA
Contact:

Post by {Nathan} »

No, i have my "map" set up with lots of things. The problem is, I can't use the Map array to do collisions (because i don't use one) so i need to do a "point" command in text mode. I was thinking about talking with the text buffer, but I cannnot find a formula that can allow me to do this. here is the code:

DEF SEG = &HB000

POKE 0, 1 'Poke smiley face to 1, 1
poke 1, 1 'Make smiley face blue
poke 2, 2 'make another kind of smiley face
poke 2, 2 'make this one green

and ect.

I use WIDTH 50 (columns) and 80 (rows)
Image
Nodtveidt
Veteran
Posts: 826
Joined: Sun Jul 25, 2004 4:24 am
Location: Quebradillas, PR
Contact:

Post by Nodtveidt »

You can use SCREEN as a function to return character codes at specific locations. Look it up in QB's help.
Z!re
Veteran
Posts: 887
Joined: Wed Aug 04, 2004 11:15 am

Post by Z!re »

c = SCREEN(row, collumn [, return ASCII value or was it color.. hmm])

Example:
color = SCREEN(10, 50)
char = SCREEN(10, 50, 1)


Look it up though
I have left this dump.
Post Reply