English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 19 November 2012, 19:48   #1
alphagemini
Registered User
 
Join Date: Nov 2011
Location: Folkestone, Kent
Posts: 119
Hi Soft Basic help wanted

I wish to use a line of code containing a chain of conditions such as the following:-

If ..... and ...... or ..... and etc. The line can be very long but AmigaBasic
won't continue onto the next line. How can I overcome this?

thanks in advance

Alphagemini
alphagemini is offline  
Old 19 November 2012, 23:57   #2
Lonewolf10
AMOS Extensions Developer
 
Lonewolf10's Avatar
 
Join Date: Jun 2007
Location: near Cambridge, UK
Age: 44
Posts: 1,924
I am not familiar with Hi Soft Basic, but you could split the conditions into multiple If statements.

Code:
If <CONDITION1> ....
If <CONDITION2> ....

Sometimes it is unavoidable that you need several If statements. For example controlling a character you could have 4 If statements each for moving him/her left, right, up and down.

Last edited by Lonewolf10; 20 November 2012 at 00:03.
Lonewolf10 is offline  
Old 20 November 2012, 09:30   #3
alphagemini
Registered User
 
Join Date: Nov 2011
Location: Folkestone, Kent
Posts: 119
Thanks for the help. It doesn't seem to like multiple if statements contained within an
outer shell of other conditions. I am dividing the overall if...end if into two sections to
overcome the problem, but it looks clumsy and takes more running time I think.

Alphagemini
alphagemini is offline  
Old 20 November 2012, 10:32   #4
Yesideez
(2b)||!(2b)
 
Yesideez's Avatar
 
Join Date: Mar 2007
Location: Cranbrook, Devon, UK
Age: 50
Posts: 241
Can you post the problematic code?
Yesideez is offline  
Old 11 January 2013, 11:39   #5
alphagemini
Registered User
 
Join Date: Nov 2011
Location: Folkestone, Kent
Posts: 119
thanks for your help, I've found a work around
alphagemini is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Basic help wanted alphagemini Coders. General 6 07 March 2013 22:35
Manuals for GFA Basic and Hi-Soft Basic 2 ricky500 request.Apps 20 12 February 2013 21:06
Hi Soft Basic help wanted alphagemini Coders. Scripting 10 13 September 2012 12:43
Alarm program in Hi Soft basic alphagemini Coders. General 6 05 August 2012 18:00
Basic Vector Code wanted redblade Coders. General 16 24 December 2005 05:41

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 04:48.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.08389 seconds with 13 queries