12-04-2023, 07:04 PM
You could try this. It basically switches the slashes based on OS.
Just tack the function at the bottom somewhere. And add the osFix function where files are being interacted with.
I haven't thoroughly tested this but, it worked on my system.
Code: (Select All)
FUNCTION osFix$ (in AS STRING)
DIM AS LONG iter
DIM AS STRING char, fixed
fixed = in
FOR iter = 1 TO LEN(in)
char = MID$(in, iter, 1)
IF INSTR(, _OS$, "[WINDOWS]") THEN
IF char = "/" THEN
MID$(fixed, iter) = "\"
END IF
ELSE
IF INSTR(, _OS$, "[LINUX]") OR INSTR(, _OS$, "[MACOSX]") THEN
IF char = "\" THEN
MID$(fixed, iter) = "/"
END IF
END IF
END IF
NEXT
osFix = fixed
END FUNCTIONJust tack the function at the bottom somewhere. And add the osFix function where files are being interacted with.
Code: (Select All)
uni_bord = _LOADIMAGE(osFix$("need\menu\bord\uni_bord.jpg"), 32)I haven't thoroughly tested this but, it worked on my system.
2D physics engine https://github.com/mechatronic3000/fzxNGN
QB Pool https://github.com/mechatronic3000/QBPool
QB Pool https://github.com/mechatronic3000/QBPool

