Hi,
I just finished making my level editor so that my game is now so much easier to make! However, I've run into some difficulties.
All code from the level maker is stored as a file in the same directory. When I put all the code into a function makelevel() and run that from my game it works fine - however when making it so you have to input the name of the file to include, the editor wouldn accept it - presumably because it could not find the makelevel() function. The code is below. Anyone know how I can solve this, or any other ways to include external code?
Thanks
`Ask for which level to load
set cursor 10,500
input "LEVEL TO LOAD: ",levelload$
levelload$ = levelload$ + ".lvl"
`Load Level
if file exist(levelload$)=1
#include levelload$
makelevel() `PROBLEM IS HERE - DB CANNOT FIND THIS BECAUSE, OBVIOUSLY, IT ISNT LOCATED YET!
else
print "LEVEL NOT FOUND!"
suspend for key
end
endif