this what i have so far. i want to add a bunch of lines outlining the text. i also want to add player stats and i want them to lvl up. i guess im requesting alot, but i have to start somewhere. this code has someething wrong, and i want to know what it is. i think that the function may be dbpro based and i use dbclassic.
Do
if Button(275,205,"New Game")=1 then Goto New_Game
if Button(275,235,"Load Game")=1 then goto load_game
if button(300,265,"exit")=1 then end
loop
New_Game:
cls
Text 240,220,"..........loading................";
wait 2000
cls
print "NPC:Hello and welcome to cobland."
wait key
cls
do
if button(275,235,"go to town")=1 then goto go_to_town
if button(275,265,"quit game")=1 then end
loop
wait key
function Button(x1,y1,WORDS$)
Pressed=0
x2=Text Width(WORDS$)
y2=Text Height(WORDS$)
if mousex()>x1 and mousex()<x1+x2
if mousey()>y1-y2 and mousey()<y1+y2
Pressed=1
endif
endif
if pressed=1 then ink rgb(0,0,255),0 else ink rgb(255,0,0),0
if pressed=1
Pressed=Mouseclick()
else
pressed = 0
endif
text x1,y1,WORDS$
endfunction pressed
load_game:
cls
text 240,220,"................loading.............."
wait 3000
go_to_town:
cls
text 275,195,"NPC:Welcome to the town of cobland."
wait 5000
cls
do
if button(275,205,"head to shop")=1 then goto Shop
if button(275,235,"inn")=1 then goto Inn
if button(275,265,"quit game")=1 then end
loop
cls
wait key
Shop:
cls
Print "NPC: welcome to the shop"
wait key
Inn:
cls
print "NPC:welcome to the inn."
wait key
im new and dont know anything about programming. all i want to do is program games.