I fixed some glitches in the function, it works much better now.
Now if you want to load an image, just locate the image, right click it, then click on properties, Security, and cut and paste the Object name into the new input command.
Your images might not be loading because your just not spelling the file names correctly.
Rem Replace the input commands with this
image_list(max_items).img_filename = Better_Input(10,10,"Enter filename: ")
image_list(max_items).img_marker = Better_Input(10,34,"Enter reference name: ")
end
Rem Input Replacement Function
Function Better_Input(InputX as Integer,InputY as Integer,InputText$ as String)
YourText$ = ""
clear entry buffer
while get key state(13) > -1 `While the return key isn't being pressed
Rem Erase the text by drawing black text over the old text
ink rgb(0,0,0),0 `Erase Text
if Blink > 0 then text InputX,InputY,InputText$+YourText$+"|"
if Blink = 0 then text InputX,InputY,InputText$+YourText$
Rem Cut and paste Stuff
Control_Copy$ = get clipboard$()
if get key state(0xA2) < 0 or get key state(0xA3) < 0 `Left or right control keys
if get key state(0x56) < 0 then YourText$=YourText$+Control_Copy$ `Control V
while get key state(0x56) < 0
endwhile
endif
Rem Get the rest of the keys on the keyboard
if get key state(0xA2) > -1 and get key state(0xA3) > -1 and get key state(0x56) > -1
if entry$() <> "" then YourText$ = YourText$+entry$(1)
endif
clear entry buffer
Rem The backspace button
if get key state(0x08) < 0
if len(YourText$) > 0 `if there is something to delete
NewText$ = ""
for i = 1 to len(YourText$)-1
NewText$ = NewText$ + mid$(YourText$,i)
next i
YourText$ = NewText$
endif
Rem Wait and Timer variables
if WaitDelete <> -1 then WaitDelete = timer()
if WaitDelete = -1 then WaitDelete = timer()-450
Rem Wait until the user lets go of the backspace key or until 1/2 a second has passed
while get key state(0x08) < 0
if timer()-WaitDelete >= 500 `waits for 1/2 of a second
WaitDelete = -1
Exit
endif
endwhile
if WaitDelete <> -1 then WaitDelete = 0
endif
Rem Makes the blinking thing for the text
if Blink > 0 then dec Blink,1
inc WaitBlink,1
if WaitBlink = 50
Blink = 20
WaitBlink = 0
endif
Rem Draw the text
ink rgb(255,255,255),0
if Blink > 0 then text InputX,InputY,InputText$+YourText$+"|"
if Blink = 0 then text InputX,InputY,InputText$+YourText$
sync
endwhile
Rem Waits for the user to let go of the enter key
while get key state(13) < 0 : endwhile
Rem Redraw input text
ink 0,0 : text InputX,InputY,InputText$+YourText$+"|"
ink rgb(255,255,255),0 : text InputX,InputY,InputText$+YourText$
EndFunction YourText$
Don't tell anybody, but this is my first time ever actually using functions.
I like games, and stuff.