Posted: 18th Jun 2007 21:34
i've got all my skybox set up & ready 2 go, but DBPro has decided its not going to let it go without problems

this is the code im using in a function

+ Code Snippet
Function setsky(Skynum#)
  Load Image "worldsky_mapskyn_" +skynum#+ ".bmp",1
  Load Image "worldsky_mapskye_" +skynum#+ ".bmp",2
  Load Image "worldsky_mapskys_" +skynum#+ ".bmp",3
  Load Image "worldsky_mapskyn_" +skynum#+ ".bmp",4
  Load Image "worldsky_mapskyu_" +skynum#+ ".bmp",5
  texture limb ObjNum,1,1
  texture limb ObjNum,1,2
  texture limb ObjNum,1,3
  texture limb ObjNum,1,4
  texture limb ObjNum,1,5
endfunction


and this is the Stop-box i get

"Types '$$5' and 'FS@setsky@skynum#' are incompatible at line 171

anyone have any clues
Posted: 18th Jun 2007 21:50
or ffs, now its totally fallen over on me, 94% of this code does not work

+ Code Snippet
Function MakeLimbCube(ObjNum,Size#)
  Offset#=Size#/2.0: MeshNum=2000: PlainNum=2000
  Make Object Cube ObjNum,Size#
  Make Object Plain PlainNum,Size#,Size#
  Make Mesh From Object MeshNum,PlainNum
  ADD LIMB ObjNum, 1, 2000: Offset Limb ObjNum,1,0,0,0.0-Offset#: Rem Cube Side 1 (Front)
  ADD LIMB ObjNum, 2, 2000: Rotate Limb ObjNum,2,0,90,0:  Offset Limb ObjNum,2,0.0-Offset#,0,0: Rem Cube Side 2 (Left)
  ADD LIMB ObjNum, 3, 2000: Rotate Limb ObjNum,3,0,180,0: Offset Limb ObjNum,3,0,0,Offset#:     Rem Cube Side 3 (Back)
  ADD LIMB ObjNum, 4, 2000: Rotate Limb ObjNum,4,0,270,0: Offset Limb ObjNum,4,Offset#,0,0:     Rem Cube Side 4 (Right)
  ADD LIMB ObjNum, 5, 2000: Rotate Limb ObjNum,5,90,0,0:  Offset Limb ObjNum,5,0,Offset#,0:     Rem Cube Side 6 (Top)
`  ADD LIMB ObjNum, 6, 2000: Rotate Limb ObjNum,5,270,0,0: Offset Limb ObjNum,5,0,0.0-Offset#,0: Rem Cube Side 5 (Bottom)
  Set Object Cull ObjNum,0
  Delete Mesh MeshNum
  Delete Object PlainNum
  Hide Limb ObjNum,0
EndFunction

Function setsky(Skynum#)
if file exist("world\sky_map\skyn_" skynum# ".bmp")
    Load Image "world\sky_map\skyn_" skynum# ".bmp",1
    Load Image "world\sky_map\skye_" skynum# ".bmp",2
    Load Image "world\sky_map\skys_" skynum# ".bmp",3
    Load Image "world\sky_map\skyn_" skynum# ".bmp",4
    Load Image "world\sky_map\skyu_" skynum# ".bmp",5
else
    Load Image "world\sky_map\skyn_1.bmp",1
    Load Image "world\sky_map\skye_1.bmp",2
    Load Image "world\sky_map\skys_1.bmp",3
    Load Image "world\sky_map\skyn_1.bmp",4
    Load Image "world\sky_map\skyu_1.bmp",5
endif
  texture limb 2,1,1
  texture limb 2,1,2
  texture limb 2,1,3
  texture limb 2,1,4
  texture limb 2,1,5
endfunction


what is SHOULD do is texture each side of a cube, but as u can guess, it dosn't work, it only textures one side with the "top" texture.

if someone could fix it will be gr8 (if possable?)
Posted: 18th Jun 2007 22:09
You're using floats for a number, it's a bad idea, you should use integers.
But the real problem is that you put a value inside a string, it's not possible.
Load Image "worldsky_mapskyn_" +skynum#+ ".bmp",1

It should be
Load Image "worldsky_mapskyn_" +str$(skynum)+ ".bmp",1