I've got it working now, using info I learned from the original posts I was going off of and those wonderful tutorials you gave me. Some of each of them didn't work or looked to rigid but I fiddled enough that it works perfectly now, and smooth as possible. Take a look:
REM move and rotate right
if rightkey()=1
speedr#=speedr#+.003
else
speedr#=speedr#-.003
endif
REM move and rotate left
if leftkey()=1
speedl#=speedl#+.003
else
speedl#=speedl#-.003
endif
REM jumping
if spacekey()=1 and jumped=0
jumped=1
a#=0.3
endif
if jumped=1
jumpy#=object position y(1)+a#
a#=a#-0.01
endif
REM limit speed
if speedr#=>0.3 then speedr#=0.3
if speedl#=>0.3 then speedl#=0.3
if speedr#=<0.0
speedr#=0.0
endif
if speedl#=<0.0
speedl#=0.0
endif
position object 1,object position x(1)+speedr#-speedl#,jumpy#,0
Here's all the code if you wanted to test it or anything:
sync on:sync rate 50
make object sphere 1, 2
position object 1, 0, 0, 50
make object collision box 1, -1.2, -1.2, -1.2, 1.2, 1.2, 1.2, 0
make object box 2, 4, 1, 4
position object 2, 6, 0, 0
make object collision box 2, -2, -0.5, -2, 2, 0.5, 2, 0
make object box 3, 50, 0.5, 10
position object 3, 0, -1.2, 0
REM All the pretty variables
global speedr#
global speedl#
global posx#
global posy#
global posz#
global jumpy#
global jumped
global a#=0.3
REM static collision plane
objx#=object position x(3)
objy#=object position y(3)
objz#=object position z(3)
objsx#=object size x(3)/2.0
objsy#=object size y(3)/2.0
objsz#=object size z(3)/2.0
Make static collision box objx#-objsx#,objy#-objsy#,objz#-objsz#,objx#+objsx#,objy#+objsy#,objz#+objsz#
do
REM make camera follow character
position camera posx#, 0,-20
col()
keyctrl()
sync
loop
REM Controls
function keyctrl()
REM move right
if rightkey()=1
speedr#=speedr#+.003
else
speedr#=speedr#-.003
endif
REM move left
if leftkey()=1
speedl#=speedl#+.003
else
speedl#=speedl#-.003
endif
REM jumping
if spacekey()=1 and jumped=0
jumped=1
a#=0.3
endif
if jumped=1
jumpy#=object position y(1)+a#
a#=a#-0.01
endif
REM limit speed
if speedr#=>0.3 then speedr#=0.3
if speedl#=>0.3 then speedl#=0.3
if speedr#=<0.0
speedr#=0.0
endif
if speedl#=<0.0
speedl#=0.0
endif
position object 1,object position x(1)+speedr#-speedl#,jumpy#,0
endfunction
REM Sliding collision
function col()
oldposx#=object position x(1)
oldposy#=object position y(1)
oldposz#=object position z(1)
posx#=object position x(1)
posz#=object position z(1)
posy#=object position y(1)
position object 1,posx#,posy#,posz#
if object collision(1,2)>0
dec posx#,get object collision x()
dec posy#,get object collision y()
dec posz#,get object collision z()
endif
REM static collision detection
s#=object size y(1)/2.0
if get static collision hit(oldposx#-s#,oldposy#-s#,oldposz#-s#,oldposx#+s#,oldposy#+s#,oldposz#+s#,posx#-s#,posy#-s#,posz#-s#,posx#+s#,posy#+s#,posz#+s#)=1
dec posx#,get static collision x()
dec posy#,get static collision y()
dec posz#,get static collision z()
jumped=0
endif
if get static collision y()<=0.0
jumpy#=0.1
endif
position object 1,posx#,posy#,posz#
endfunction
Much thanks!
Neeeeeeeewom!