English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Language > Coders. AMOS

 
 
Thread Tools
Old 08 June 2016, 21:40   #21
volvo_0ne
Registered User
 
Join Date: Mar 2015
Location: Sheffield UK
Posts: 360
Code:
Screen Open 0,320,200,32,Lowres
Flash Off : Curs Off : Cls 0
Double Buffer 

AM$="A: Let R0=J1; If R0=1 Jump C; If R0=2 Jump D; "
AM$=AM$+"If R0=4 Jump E; If R0=8 Jump F; Pause; Jump A; "
AM$=AM$+"C: Let Y=Y-1; Pause; Jump A; " : Rem UP 
AM$=AM$+"D: Let Y=Y+1; Pause; Jump A; " : Rem DOWN 
AM$=AM$+"E: Let X=X-1; Pause; Jump A; " : Rem LEFT 
AM$=AM$+"F: Let X=X+1; Pause; Jump A; " : Rem RIGHT

Bob 1,160,100,1 : Rem Place the bob near centre of screen


Channel 1 To Bob 1
Amal 1,AM$
Amal On 1
Wait Key
Try this for an AMAL Joystick test routine, It's very basic (well AMAL actually)
but it can easily be expanded on.

It also works in DIRECT mode

You must have at least 1 BOB in the bob bank (pref 32x32 Pixels but not important.)

Hope this gives you some ideas.

V1

PS: The CASE of the lettering in the strings is VERY IMPORTANT.....
volvo_0ne is offline  
Old 08 June 2016, 22:06   #22
idrougge
Registered User
 
Join Date: Sep 2007
Location: Stockholm
Posts: 4,332
Quote:
Originally Posted by Retro1234 View Post
I also dont think Amos is much slower than other options once compiled
Underlined it for you.
idrougge is offline  
Old 09 June 2016, 11:16   #23
Brick Nash
Prototron
 
Brick Nash's Avatar
 
Join Date: Mar 2015
Location: Glasgow, Scotland
Posts: 411
Quote:
Originally Posted by volvo_0ne View Post
Code:
Screen Open 0,320,200,32,Lowres
Flash Off : Curs Off : Cls 0
Double Buffer 

AM$="A: Let R0=J1; If R0=1 Jump C; If R0=2 Jump D; "
AM$=AM$+"If R0=4 Jump E; If R0=8 Jump F; Pause; Jump A; "
AM$=AM$+"C: Let Y=Y-1; Pause; Jump A; " : Rem UP 
AM$=AM$+"D: Let Y=Y+1; Pause; Jump A; " : Rem DOWN 
AM$=AM$+"E: Let X=X-1; Pause; Jump A; " : Rem LEFT 
AM$=AM$+"F: Let X=X+1; Pause; Jump A; " : Rem RIGHT

Bob 1,160,100,1 : Rem Place the bob near centre of screen


Channel 1 To Bob 1
Amal 1,AM$
Amal On 1
Wait Key
Try this for an AMAL Joystick test routine, It's very basic (well AMAL actually)
but it can easily be expanded on.

It also works in DIRECT mode

You must have at least 1 BOB in the bob bank (pref 32x32 Pixels but not important.)

Hope this gives you some ideas.

V1

PS: The CASE of the lettering in the strings is VERY IMPORTANT.....
Excellent thanks I'll give it a try, it's just what I've been looking for. My joystick routine is a bit clunky right now as shifting from a horizontal or vertical to a diagonal doesn't work that well so I was planning on re-writing it anyway.

Oh and for anyone else who may read this in the future I solved my bob sync problem.

Turns out it was just a case of writing - Bob 2,X Bob(1),Y Bob(1),8 and that made Bob 2 appear at Bob 1's co-ordinates nicely!
Brick Nash is offline  
Old 09 June 2016, 11:41   #24
idrougge
Registered User
 
Join Date: Sep 2007
Location: Stockholm
Posts: 4,332
Now I see where the communication didn't work between me and Brick Nash. I didn't know AMAL had its own X and Y variables.
idrougge is offline  
Old 09 June 2016, 12:05   #25
Brick Nash
Prototron
 
Brick Nash's Avatar
 
Join Date: Mar 2015
Location: Glasgow, Scotland
Posts: 411
Quote:
Originally Posted by idrougge View Post
Now I see where the communication didn't work between me and Brick Nash. I didn't know AMAL had its own X and Y variables.
It's a bit of a pain in the arse that Amal and Amos don't talk to each other that way. I had some real smooth movement going on in all directions using the Amos X & Y but having to switch to STOS Move X/Y (which I assume it shares with Amal X/Y) to get it to work with the animations presents even more problems in that stuff needs to be turned on and off. (I'm assuming!)

Either way I appreciate all the help!

Last edited by Brick Nash; 09 June 2016 at 12:31.
Brick Nash is offline  
Old 09 June 2016, 20:55   #26
volvo_0ne
Registered User
 
Join Date: Mar 2015
Location: Sheffield UK
Posts: 360
Quote:
Originally Posted by Brick Nash View Post
Excellent thanks I'll give it a try, it's just what I've been looking for. My joystick routine is a bit clunky right now as shifting from a horizontal or vertical to a diagonal doesn't work that well so I was planning on re-writing it anyway.

Oh and for anyone else who may read this in the future I solved my bob sync problem.

Turns out it was just a case of writing - Bob 2,X Bob(1),Y Bob(1),8 and that made Bob 2 appear at Bob 1's co-ordinates nicely!
To add diagonals it's simply a matter of adding another four or five lines to the AMAL string.

I'll leave you to sort that one out if needed

If you need any help msg me

V1
volvo_0ne 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
animation software moijk support.Apps 3 25 March 2013 17:36
Is it possible to get this demo/animation? TTD request.Demos 2 22 October 2011 19:04
Boing Animation Fingerlickin_B request.Demos 8 27 February 2009 14:45
How to make iBrowse load images to Fast RAM? Fingerlickin_B support.Apps 2 23 February 2009 06:11
Name of animation? Drake1009 Retrogaming General Discussion 7 10 December 2001 13:00

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 19:40.

Top

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