hello again everyone

so as i said , i'm trying to build a MP game , but first i will need to build a level or a map editor for it, i want instead of using other 3d builders to build one of my own. that later if game succeds a 3rd user party can build a map.
now i know its a bad idea for a noob like me , but i'll go for it .
for now this is what i have done already , two days of work.
if you put the mouse over the build button it will create a new box which you need to place on the Grid.
i'm having a trouble , to get it the way i want, as for , i want the box to appear behind the Buildbutton , but it seems that the mouse cordinates are messed up for some how , so the newly created box appers in the other side of the screen. don't know why thats happening.
after i'll reach that point , the box will be able to be resaized and streached and whatever.. then textured.
so why does the Box dosen't appers behind the Mouse?
as in this code:
dbMakeObjectCube(NewBox,10);
dbPositionObject(NewBox,dbMouseX(),dbMouseY(),-5);
thats in a new VOID in the loop.
at the end after you hit Enter you can create a new box.
for now , you can play with the camera using arrows, and if you hit Space it will return to deafult position and angles.
ty for your time.