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.

DarkBASIC Professional Discussion / Tutorial code fixed. (I think) but now loading BSP troubles

Author
Message
Matto
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location:
Posted: 20th Sep 2002 05:05
I had been running through the Tutorial for the FPS, well the only set are connected to this, I found these errors in it so far, and was going to test my fixes which are as follows:


Firstly here's a line you won't get past.

if wrapvalue(camera angle x(0))>40 and wrapvalue(camera angle x(0))180 then xrotate camera 0,40

and here's the error message I get when I do run the exe or build it if I leave it as it is.

#100007: variable Name is not valid at line 51 (the line you see above).

Now the problem is a missing "40 and wrapvalue(camera angle x(0))180 and wrapvalue(camera angle x(0))
1ghz Cel,512 sdram 133,Gf2 MX 400 64,SBL 5.1,Win98
Best Upcoming MMOG - http://WWW.Atriarch.com
Project: Card Game with No Name
Matto
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location:
Posted: 20th Sep 2002 05:17
ok thats not funny... I had a very indepth post and it posted a few lines.. anyone know how to get more on the posts please? before I cry preferably

1ghz Cel,512 sdram 133,Gf2 MX 400 64,SBL 5.1,Win98
Best Upcoming MMOG - http://WWW.Atriarch.com
Project: Card Game with No Name
Matto
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location:
Posted: 20th Sep 2002 16:05
I had been running through the Tutorial for the FPS, well the only set are connected to this, I found these errors in it so far, and was going to test my fixes which are as follows:


Firstly here's a line you won't get past.

if wrapvalue(camera angle x(0))>40 and wrapvalue(camera angle x(0))180 then xrotate camera 0,40

and here's the error message I get when I do run the exe or build it if I leave it as it is.

#100007: variable Name is not valid at line 51 (the line you see above).

Now the problem is a missing "<" sign infront of the CAMERA ANGLE X(0)"<"180 and the line should, if I am correct, read as follows.

if wrapvalue(camera angle x(0))>40 and wrapvalue(camera angle x(0))<180 then xrotate camera 0,40

ok thats the first problem dealt with, heres the next, and infact the next line is the same, add the "<" (without the quote marks ) infront of the CAMERA ANGLE X(0)"<"280

And this line should now read:

if wrapvalue(camera angle x(0))>180 and wrapvalue(camera angle x(0))<280 then xrotate camera 0,280


OK now thats sorted we have more mistakes...

This line from Tut8A (the logic tuts)

if abs(viewa#-obja#)10.0 and abs(dy#)5.0 and dist#30.0

is also missing signs before the 10.0 and the 5.0 and after the dist#

I am guessing here at a <10.0, <5.0 and Dist#<=30.0

as it's a little trial and error sorting this out.

Now if that wasn't enough for you, try the next line too:

This Line in Tut8B (Again in logic, go figure...)

if dist#2.0

Should read

if dist#<2.0

Note the extra "<" infront of 2.0


OK thats it, now the bugs have been found and eliminated, OR at least so I thought...



Now I go to test my findings before letting you all know why the darn thing won't work incase anyone else was having problems with the code, so I build an exe that worked fine, then run the exe and all seems fine until a sudden stop and a message saying it can't load the BSP file for the world;

So I take a gander at the index and find Load BSP help to see if it is something I have missed, here it says as follows:

LOAD BSP
This command will load a BSP world into the 3D scene. The BSP
world automatically draws to the current camera and cannot be
rotated or repositioned. Culling, texturing and collision are all
handled automatically and through the related world commands. The
first parameter allows you to specify a packed file containing the
BSP world files, normally a PAK or PK3 file. If the BSP world is not
being loaded from a packed file, this parameter should be an empty
string. The second parameter is the BSP filename of the world you
wish to load. This file can either be contained within the specified
packed file, or exist as a standalone BSP file. If loading the BSP file
as a standalone file, ensure the current directory contains any files
used by the BSP world.

SYNTAX
LOAD BSP PK3 Filename, BSP Filename


Right, so I see a need to check the file is there in the file the code points to, when I do I find it where it should be except there is a difference, the code says this:

rem TUT4A
rem Load BSP world and sky model
load bsp "world\ikzdm1.pk3","ikzdm1.bsp"

But there is no sighting of any kind of "ikzdm1.pk3" in the folder but a "ikzdm1.bsp"is present, Hmm I think I need to leave an empty string in the quotes previos to ,"ikzdm1.bsp", and I tried this:

load bsp "","ikzdm1.bsp"

With no Joy, so I am thinking hmm an empty string.. so I tried this instead:

load bsp "world$","ikzdm1.bsp"

Being world$ is empty as I have added nothing to that string variable I hoped it may work. Well no it didn't as it is a variable I suppose and not an empty string, so what is an empty string??? I must be missing something here. Is it just "" = empty string, if so it isn't working, and besides even if it did, there is evidence already it may not work because the help file states..

"If loading the BSP file as a standalone file, ensure the current directory contains any files used by the BSP world".

well there is nothing apart from the "ikzdm1.bsp" in this folder so either it has no other information needed, or it has been forgotten to be added to the folder, and the users are without it? or I need to add something in there that I have not twigged about and must add it before something will happen.

OK thats it, now the bugs have been found and eliminated, quite honestly as it should have been shipped!! I will let you play and have fun with your first shooter that works.. hopefully.

1ghz Cel,512 sdram 133,Gf2 MX 400 64,SBL 5.1,Win98
Best Upcoming MMOG - http://WWW.Atriarch.com
Project: Card Game with No Name
Matto
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location:
Posted: 20th Sep 2002 16:11
Umm why isn't there an edit this is getting messy..

CUT "OK thats it, now the bugs have been found and eliminated, quite honestly as it should have been shipped!! I will let you play and have fun with your first shooter that works.. hopefully." END of CUT

WHY CUT? becasue I can't get past the BSP and presum most others to have the same problem, I still can't load the BSP file, is there anyone able to help sort this out please?

Many thanks

1ghz Cel,512 sdram 133,Gf2 MX 400 64,SBL 5.1,Win98
Best Upcoming MMOG - http://WWW.Atriarch.com
Project: Card Game with No Name
MrTAToad
21
Years of Service
User Offline
Joined: 26th Aug 2002
Location: United Kingdom
Posted: 20th Sep 2002 16:13
I think I mentioned the 180 problem a few days ago. I'm surprised that no-one check the tutorials first...

Yes, I really am THAT good...
Matto
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location:
Posted: 20th Sep 2002 18:43
I have since managed to get the BSP to load by adding in the full address of the BSP file but then it will not load any objects, so I am putting all info in the same folder as the exe to see if it will run then I tried this on an object and it worked as long as it was in the same file, I also did not realize there is a FpsGame.DBA in the tutorial folder.. and there was me pasting it together, still it is as usless so far as my work pasting it together is, so only time will sort this out. I am going to get it working, ARG...

1ghz Cel,512 sdram 133,Gf2 MX 400 64,SBL 5.1,Win98
Best Upcoming MMOG - http://WWW.Atriarch.com
Project: Card Game with No Name

Login to post a reply

Server time is: 2024-04-20 07:53:24
Your offset time is: 2024-04-20 07:53:24