Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Cant make it go up and down

Author
Message
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 5th Mar 2005 19:02
I cant make my objevts go up and down the editor keep saying it dont understand the "object position y 1,+0.5" i tryed to use the code "move player up" before but i had rotated my 3dobject then it didnt go that way i wanted so i changed to this but it didnt work, how do i do?




You never fail, only make mistakes.
Zokomoko
21
Years of Service
User Offline
Joined: 23rd Nov 2002
Location:
Posted: 5th Mar 2005 19:23
move object up objnum,value
move object down objnum,value
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 5th Mar 2005 19:37
yes i meant that in the text above but i wrote player instead of object, but when i do this it keeps go in wrong direction. is there some other way, or can i set a new up and down etc for the obect after i have rotated it in the game?

You never fail, only make mistakes.
Baggers
20
Years of Service
User Offline
Joined: 31st May 2004
Location: Yonder over dem dere hills
Posted: 5th Mar 2005 19:39
Slooper, the reason your code doesnt work is that you are using the wrong command, if you check the help files youll find that 'object position y' is for returning the Y value of an object not changing it...for changing it you have to use the position object, i have modified your code a little and this should get it working how you hoped.
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 5th Mar 2005 19:54
tnx baggers you saved my day.

You never fail, only make mistakes.
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 5th Mar 2005 20:12
it didnt work so i sen the whole game up here in na attachment, can someone help me with this a bit? i cant move the players in that way i want, its a pong game if someone wonder what it is

You never fail, only make mistakes.

Attachments

Login to view attachments
Baggers
20
Years of Service
User Offline
Joined: 31st May 2004
Location: Yonder over dem dere hills
Posted: 5th Mar 2005 21:19
Um you sent the .dbpro file but not the .dba file, so i have none of your code! please post the .dba file so i can help.
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 5th Mar 2005 23:13 Edited at: 5th Mar 2005 23:15
ok now the .dbp file is with the new attachment

You never fail, only make mistakes.

Attachments

Login to view attachments
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 6th Mar 2005 19:04
Baggers please help me, i really cant solve this myself

You never fail, only make mistakes.
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 6th Mar 2005 19:16
There were 2 errors.

if downkey()=1 then p1mvu=1

should have been

if downkey()=1 then p1mvd=1

and this ...

position object 1,x#,y#,z#
position object 1,x2#,y2#,z2#

should have been this

position object 1,x#,y#,z#
position object 2,x2#,y2#,z2#


Full new code is


And why is that return at the bottom of the code?

Baggers
20
Years of Service
User Offline
Joined: 31st May 2004
Location: Yonder over dem dere hills
Posted: 6th Mar 2005 19:18
Sorry man, id been busy...im on it now
Baggers
20
Years of Service
User Offline
Joined: 31st May 2004
Location: Yonder over dem dere hills
Posted: 6th Mar 2005 19:25 Edited at: 6th Mar 2005 19:30
Yep that it...damn LIT ! you got there before me.
As an act of defiance here is the full code aswell !

hehe enjoy !

Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 6th Mar 2005 20:41
dunno why i have the return in the bottom, maby becuse our teacher im c++ programming told us every time that we needed it but he´s not educated programmer either, the school can´t afford one

You never fail, only make mistakes.
Slooper
21
Years of Service
User Offline
Joined: 13th Feb 2003
Location: Sweden
Posted: 6th Mar 2005 20:41
tnx anyway both of you guys

You never fail, only make mistakes.

Login to post a reply

Server time is: 2024-11-13 19:55:15
Your offset time is: 2024-11-13 19:55:15