forums

TNT Basic Forums > Programming Q&A
use of text mode
< Last Thread     Next Thread >
Author
Thread        Post A Reply

08-31-2003 19:45

Posted by:
Leorik The Creator

Location:
Montréal,Québec(canada)

Find more posts by Leorik The Creator

i have a problem there it is :

in example :
repeat

until x = 0 or y=0

if x = 0 then print "your dead
if y= 0 then print " you win


but when the two equal zero ive write

if x = 0 and y = o then print " blabla

but when x=0 y=0 its print :
-your dead
-you win
-blabla
im looking for a command that erase the two other command when x = 0 and y =0

thats hard to understand i know

leorik

09-01-2003 07:52

Posted by:
eekaydee

Location:
CA, USA

Click Here to Email eekaydee   Find more posts by eekaydee

I don't think there is a way to erase things you print.
Instead, why don't you try using a single if statement:

if x=0 and y=0
print "Blahblah!"
else if x=0
print "You're dead!"
else if y=0
print "You win!"
end if

09-01-2003 14:18

Posted by:
someone

Location:
Quebec ( Canada )

Click Here to Email someone   Find more posts by someone

this looks like what you had done, you just needed a little more :

if x=0 and y=0 then print " You're all dead" ' What was the messages?
if x=0 and y<>0 then print " X is dead"
if x<>0 and y=0 then print " Y is dead"

All times are GMT        Post A Reply

Forum Jump:
< Last Thread     Next Thread >

< Contact Us - TNT Basic >

Powered by: vBulletin Lite Version 1.0.1 Lite
Copyright © Jelsoft Enterprises Limited 2000.