T.R | Title | User | Personal Name | Date | Lines |
---|
2172.1 | | NZOV01::MCKENZIE | Nuke the Leprechaun! | Wed Feb 01 1989 21:19 | 7 |
| I found a way round the window problem
define an integer called SCR% and substitute into WINDOW statement.
then - for every new DPAINT Screen increment SCR% by 1
|
2172.2 | Help me,I am a beginner!!! | GUCCI::HERB | | Wed Feb 01 1989 21:56 | 11 |
| How do I make load acbm a routine???
What commands do I use to call up a Dpaint picture (I have already
turned them in ACBM format)??
Can someone give me a program that would just show a Dpaint file
called "ROCK" ? (I want to use it as a title page and background
for my amigabasic programs)
Matt
|
2172.3 | help...? | NZOV01::MCKENZIE | Nuke the Leprechaun! | Wed Feb 01 1989 23:04 | 39 |
| ok try this.....
(1) copy loadacbm to the disk with your program on it
(2) hop into basic and load the loadacmb program
(3) use your mouse to select the entire porgram for cutting
(4) select the EDIT option on the menu bar and select the CUT
sub-option.
(5) load your program
(6) Decide on a line number for the sub routine and move the pointer
to the appropriate place in the program
(7) select the EDIT option on the menu bar and select the PASTE
sub-option.
(8) you will need to copy the DOS.LIBRARY, GRAPHIC.LIBRARY and
EXEC.LIBRARY files to your program disk. These are found on
the EXTRAS disk.
(9) CUT the 1st DIM statement and DECLARE statments and PASTE these
at the top of the program.
(10) remove the INPUT ACMBname$ statement and all associated PRINT
statments.
(11) place the following lines at the top of yourt program (after
the DIM and DECLARE Statements)
ACBMname$ = "[dpaint file that has been converted to acbm]"
Gosub [line of sub-routine]
If your new to amiga basic - read BASIC manual section on
editing/debugging programs - specifically CUT/PASTE functions.
One last thing: there is a subroutine in LOADACBM called Mcleanup:
inside this routine is an END statement - you might like to use
an INKEY$ statement (A$=INKEY$ statement) followed by a RETURN
statement - this will allow you to use the LOADACBM as a sub-routine.
Try this - if you have any problems - let me know - I'll see what
I can do.
Phil
|
2172.4 | help me | GUCCI::HERB | | Thu Feb 02 1989 20:20 | 43 |
| What my program is suppose to do:
Shows acbm picture called "rock2" then goes on and draws circles
and other stuff.
That is what I wanted it to,but it did not do that.
here is what the whole program looks like after it was editted.
ACBMname$ = "df0:rock2"
GOSUB 105
REM - FUNCTIONS FROM DOS.LIBRARY
DECLARE FUNCTION XOPEN& LIBRARY
DECLARE FUNCTION XREAD& LIBRARY
DECLARE FUNCTION XWRITE& LIBRARY
REM - XCLOSE RETURNS NO VALUE
REM - FUNCTION FROM EXEC.LIBRARY
DECLARE FUNCTION ALLOCMEM&() LIBRARY
[ LOTS OF REM STATEMENTS ]
MAIN:
[ MORE STUFF ]
NEXT
RETURN <-- END OF LOAD ACBM PROGRAM
100 CLS <-- BEGINNING OF MY PROGRAM
102 SCREEN 1,640,400,5,3 <-- IS THIS NECESSERY??
105 WINDOW 1,"DEMO",(0,0)-(320,385),15,1 <-- I GET A "ILLEAGEL
FUNCTION CALL" WHEN IT GOSUBS TO THIS LINE
[ MORE OF MY PROGRAM ]
END
Do need to use a screen or window command??? Is this what the program
is suppose to look like????
Matt
|
2172.5 | my program | NZOV01::MCKENZIE | Nuke the Leprechaun! | Mon Feb 06 1989 15:02 | 63 |
| >> Do need to use a screen or window command??? Is this what the program
>> is suppose to look like????
You DO need both screen and window commands - without these the
screen resolution gets badly knackered and produces all kinds of
garbage that can only be cleared by cold-booting.
My program looks somthing like this...
10 cls
20 DECLARE FUNCTION XOPEN& LIBRARY
20 DECLARE FUNCTION XREAD& LIBRARY
40 DECLARE FUNCTION XWRITE& LIBRARY
50 DECLARE FUNCTION ALLOCMEM&() LIBRARY
60 ACBMname$ = "df0:Picture"
65 SCR% = 2
70 gosub 1000
80 IF A$ = "X" THEN END
90 ACBMname$ = "DF1:Piture2"
100 SCR% = 3
110 Gosub 1000
115 if a$ = "E" then end
120
.
. <--- rest of my program: note that I dont continue program
. <--- after line 1000 where acbm routine is. Also - you can
. <--- only display each window ONCE like in this program
. <--- if you wanted to re-display df0:picture you couldnt
. <--- just goto or gosub 60 - you would have to set scr% to
. <--- 4 and acmbname$ to df0:picture and gosub to 1000 again
950
990 END
1000 REM
MAIN:
.
.
.
Mcleanup:
if ACBMName$ = "" then RETURN
[Couple of error checks here]
A$ = INKEY$:IF A$ = "" then goto Mcleanup <--- my entry
Mcleanup2:
[WINDOW CLOSE 2] <--- GET RID OF THIS LINE
[SCREEN CLOSE 2] <--- GET RID OF THIS LINE
RETURN
.
. <------- Still more of the ACBM program
.
SCREEN SCR%,640,400,5,3 <--- notice scr% instead
WINDOW SCR%1,"DEMO",(0,0)-(320,385),15,1 <--- of fixed number
.
.
.
END OF ACBM ROUTINE
I could never get this to work without removing the window close
and screen close statements - this will mean that memory will be
used up quickly - unless someone else can find a way around it.
Phil
|
2172.6 | still need help... | NZOV01::MCKENZIE | Nuke the Leprechaun! | Tue Feb 07 1989 17:54 | 34 |
|
Hi - could still use some help on the following...
The problem is that if you get one program to load another
the second screen displayed has a menu bar LOADILBM-SAVEACBM appearing
at the top of the screen. If you move the mouse onto this bar and
press the right button, this bar goes away...cant figure this at
all...?
Has anyone ever come across this problem - how can it be fixed?
The last problem is that I have not been able to find a way to load/run
a 2nd program while preserving the DPAINT screen currently displayed.
Every time a new program is loaded, the screen is cleared then the
new DPAINT Screen appears. This is very annoying!
help!
Phil
Any help would be Greatly appreciated....
Phil
|
2172.7 | I want to hurt the person who made Amigabasic | GUCCI::HERB | | Tue Feb 07 1989 22:02 | 45 |
| I still have trouble on getting it to work. My latest problem is
it can not find dos.library.
I still have more questions concering the program you gave me.
10 cls
20-50 [declare statements]
60 acbmname$ = "df0:[name of picture]"
65 scr% = 2
70 gosub 1000
80 if a$ = "x" then end
90 acbmname$ = "df1:picture2" [I do not have 2 disk drives][is this
for the second picture]
100 scr% = 3
110 gosub 1000
115 if a$ = "e" then end
are lines 80,90,100,110 and 115 necessary if I only want one shown?
.
.
.
.
950
990 end
1000 rem
do I get rid of what was originally in Mcleanup??? There is not
any screen or window close statements in mcleanup2: do I change
anything in Mcleanup2:? Do I get rid of the window and screen close
in Mcleanup:? Is this the part of the program that brings you back
to your program? If so,can I delete everything after the end of
mcleanup2:?
screen scr%,640,400,5,3 Do I adjust the screen statement to the
resolution of then picture???
window scr%,"demo",(0,0)- (320,385),15,1
Should these 2 statements be right after the declare statements
at the begining of the program?
Maybe you can upload the program you made to display acbm pictures?
Matt
|
2172.8 | hang in there... | NZOV01::MCKENZIE | Nuke the Leprechaun! | Wed Feb 08 1989 16:14 | 22 |
| Um - cant upload at the moment as I have no access to modem etc
- however...
if you only want one picture displayed then leave the WINDOW CLOSE
and SCREEN CLOSE statements in mcleanup2: and either end your program
there or RETURN to your main prog.
as far as the DF1:picture2 bit is concernerd - thats just an example
of how you can request acbm files from a second drive - if you only
have one drive - then just use df0:...
your program is nearly working - I had the same dos.library not
found problem - there are three library files that you have to copy
off your extras disk onto your program disk. I'll get back to you
with the file names and location on the EXTRAS disk... I vaguely
remember cursing loudly because i couldnt find these library files
on the disk. (AMIGADOS badly needs a dir [...]file.tag type command)
Dont give up - your nearly there...
Phil
|
2172.9 | Should I get a new copy of extras?? | GUCCI::HERB | | Fri Feb 10 1989 21:25 | 12 |
| Where is the dos.library at? If it is on the extras disk I can't
find it.
Can the get statement load up pictures drawn in basic? Example:
I make a drawing program that can save a drawing and then use the
get statement to call up the picture.
I do remember a file with a extension of .lb on the extras disk
in some directory.
MaTt
|
2172.10 | ...found... | NZOV01::MCKENZIE | Nuke the Leprechaun! | Sun Feb 12 1989 14:36 | 9 |
| ok - got the file names: ,they are as follows
DOS.BMAP
GRAPHICS.BMAP
EXEC.BMAP
the LIBRARY commands use these files - locate these on your extras
disk and copy to your program disk.
|
2172.11 | | GUCCI::HERB | | Mon Feb 13 1989 18:42 | 18 |
| This is a part of my program. Is it right?
999 end
1000 rem
main:
dim [3 dim statement]
library "dos.library" <-- this is where the error occurs
library "exec.library"
library "graphics.library"
matt
{_
|
2172.12 | | NZOV01::MCKENZIE | Nuke the Leprechaun! | Mon Feb 13 1989 18:59 | 3 |
| move any DIM or DECLARE statements to the TOP of your program so
that they are only run once - you cant re-dimension arrays in basic.
otherwise - all ok
|
2172.13 | :-) to :-( | GUCCI::HERB | | Wed Feb 15 1989 06:53 | 11 |
| I finally got the picture on the screen in basic after I moved 3
dim statements to the top of the program and copied the bmaps outside
of the basicdemos directory. I still have a problem. After the
picture appears it just stays there. I want the program to get rid
of the picture after a couple seconds and move to the bottom of
the program (that is were the rest of my program is). The program
is still running after it shows the picture. Is the acbm program
running in circles?
Matt
|
2172.14 | so close... | NZOV01::MCKENZIE | Nuke the Leprechaun! | Wed Feb 15 1989 14:37 | 20 |
| if the abcm program (around the Mcleanup: tags) is an END statement
what I id is replace END with
A$=INKEY$: IF A$ = "" then goto [this line number]
RETURN
alternatively you gould RETURN after a time delay
FOR X = 1 to 5000:next X <------- waits about 1 1/2 seconds
then just after the GOSUB if your program that goes to MAIN: for
the load ACBM bit GOTO the next part of YOUR program.
Best Regards and good luck
Phil (you played ZK at all??)
|
2172.15 | Just what mother warned against :-) | WJG::GUINEAU | | Wed Feb 15 1989 16:12 | 14 |
|
re .-1
>
> FOR X = 1 to 5000:next X <------- waits about 1 1/2 seconds
>
ARGH! On a 68000 maybe, but not on future products (68030 will make mince
meat of that loop!)
Something like sleep(x) is better (Does AmigaDOS have this??)
John
|
2172.16 | Delay | TLE::RMEYERS | Randy Meyers | Wed Feb 15 1989 19:21 | 7 |
| Re: .15
>Something like sleep(x) is better (Does AmigaDOS have this??)
Their is a Delay function in the DOS.library that takes a single
integer argument: the number of 0.02 second intervals to wait (eg,
Delay(50) sleeps for a second).
|
2172.17 | What is ZK? | GUCCI::HERB | | Wed Feb 15 1989 21:31 | 14 |
| Now I am trying to have a second picture displayed. The error I
have now is at this part:
LIBRARY "graphics.library"
The error is "Too many files"
My second gosub is at the end of my program and I gosub to main:
just like the first time.
What did I do wrong now?
Matt
|
2172.18 | I think I will play a game of Falcon and go sleep | GUCCI::HERB | | Wed Feb 15 1989 22:01 | 14 |
| I just got around that problem by gosubing to a place right after
the library statement.
Now I have the "Illeagle function call" error on the WINDOW statement
. My WINDOW statement looks like this
SCREEN 2,scrwidth%,scrheight%,idepth%,kk
WINDOW 2,"loadacbm",,7,scr%
scr%=scr%+1
What did I do wrong this time?
Matt
|
2172.19 | | RDCV01::RANDREWS | I have a cunning plan | Wed Feb 15 1989 22:09 | 13 |
| >Now I have the "Illeagle function call" error on the WINDOW statement
First thing you gotta do is take your bird to the doctor! ;-)
> . My WINDOW statement looks like this
>
> SCREEN 2,scrwidth%,scrheight%,idepth%,kk
> WINDOW 2,"loadacbm",,7,scr%
What's the value of scr% when you get to this line? Try doing a
print scr% just before this line. I don't remember if you can use
a value of 0 for the screen. I think if you want the workbench
screen you use -1 or the screen number for a custom screen
|
2172.20 | | NZOV01::MCKENZIE | Nuke the Leprechaun! | Thu Feb 16 1989 15:03 | 11 |
| every new window/screen statement must have a unique number - thats
why I substituted SCR% in the WINDOW and SCREEN statements rather
than hard-coding a value
just increment scr% by 1 every time you want a new screen
ACBMNAME$ = "DF0:ROCK" <--- or whatever
SCR% = SCR% + 1
Gosub [whatever the line number or tag is that starts the LOADACBM]
Phil
|
2172.21 | I have 2 pictures in my program | GUCCI::HERB | | Thu Feb 16 1989 15:14 | 5 |
| How many pictures can I have in one program? Can I take the picture
out of memory after I use it?
Matt
|
2172.22 | more questions | GUCCI::HERB | | Thu Feb 16 1989 21:21 | 4 |
| Can I use the pictures as a background for my bobs & sprites?
Matt
|
2172.23 | | NZOV01::MCKENZIE | Nuke the Leprechaun! | Sun Feb 19 1989 14:58 | 9 |
| to be quite honest - I really dont know the answers to either .-1
or .-2
I do know that the window close and screen close statements dont
seem to work with more than one picture loaded so I really dont know
anyone else out there able to help????
Phil
|
2172.24 | Matt Herb (member of the Mutated Minds) | GUCCI::HERB | | Mon Feb 27 1989 22:26 | 5 |
| Yes!!!You can use shapes on a Deluxe Paint!!!!
Matt (who will show the world that you can make professional quality
with Amigabasic and a compiler)
|