Can Blitz read .wld Files?
Blitz3D Forums/Blitz3D Beginners Area/Can Blitz read .wld Files?
| ||
I made a dungeon using Maplet, and I want to put some meshes into it using World Assembler off this site. I did this and could either save it as an editor file or a world(.wld) file. Can Blitz read either of these? and if it can, how do I load them? |
| ||
No. |
| ||
Here are some file formats Blitz can read (probably not all of them): .x .3ds .b3d .md2 .bsp .bmp .png .jpg .raw .wav .ogg .mp3 .mid .mod .s3m .xm .it .rmi .mp2 .wma .asf .gif .avi .mpeg (or is it .mpg?) |
| ||
Then why can you download World Assembler off this site when you can't even make a world in a file that blitz can read? |
| ||
I don't know anything about World Assembler but you are probably supposed to write your own importing code to load the file. Check the documentation with World Assembler. |
| ||
Use the 'world loader.bb' include file that came with world assembler. |
| ||
Oh, I was wondering what that was. Thanks. For some reason, blitz won't read the b3d files I made with Maplet. Also, Maplet crashes when I try to export in .x. Maybe I should re download it and install it? Also, is there anything I have to do to load the worlds besides include the one .bb file? |
| ||
I redownloaded Maplet and it still does the same thing. Why would it do that? I also found out that World Assembler can read the b3d files that blitz can't. It also says that World Assembler can export in b3d format, but I don't see that anywhere, This is exactly what I wrote: crypt\entity = LoadMesh("Crypt1demo.b3d") but blitz says it doesn't exist. It's in the same folder and World Assembler can read it. What's going on? |
| ||
See right after that loading statement, do debuglog(crypt\entity) and see what the debuglog spits out. If it spits out zero, the file probably isn't there. Double, triple check the file .b3d is in with the code your running. |
| ||
I put that right after the loading statement, but It didn't do anything it went right to: PositionEntity crypt\entity,crypt\x,crypt\y,crypt\z and said File does not exist. The File is DEFINATELY in there. Also, You know how I said that Maplet crashed when I tried to make a .x file? It only does that on the map that I made, but not on the ones maplet came with. Why? |
| ||
I just tried making a new maplet map and it made a .x file. Why does it work now? This is so weird. |
| ||
Yep, It works to make one now. But I spent so much time making that last map and now it doesn't work! |
| ||
It seems like my Blitz can't read b3d at all, because I tried several different meshes that I didn't even make, and it still doesn't work! |
| ||
post the code you are trying. |
| ||
I sorta did up there, but I'll do it again: player\entity = LoadMesh("player.b3d") Is there any other part I should post? |
| ||
Update B3D. I had that problem. Some older versions of b3d can't load .b3d files. Ironic, 'eh? |
| ||
Update B3D. I had that problem. Some older versions of b3d can't load .b3d files. Ironic, 'eh? Versions 1.66 and upwards support .b3d. Blitz was unable to support .b3d before because... the .b3d format didn't exist. |
| ||
Oh, thanks. Where do I get an update? (I'll probably find it before you reply) |
| ||
http://blitzbasic.com/Community/posts.php?topic=44434 |
| ||
It just says internal error |
| ||
Found it! |
| ||
About the .wld files: So all I do is include the world loader.bb and then it works? |
| ||
No, use the function in the Worldloader.bb for loading .wld files. |
| ||
You mean LoadWorld? And also, When the world is loaded, can I control each mesh that I put in that world? |
| ||
You will probably need to use the FindChild() command to extract them :o) |
| ||
okay, I'll try it. |
| ||
So far, this is what I did, but it doesn't work. I made the .wld, included the World Loader.bb file, but what I did was replaced my Crypt.x file which was just the map itself, and replaced it with Crypt.wld, but it says entity does not exist. crypt\entity = LoadWorld("Crypt.wld") Are .wld's treated differentlty than meshes? |
| ||
Look at the "Example Game.bb" And you will see the command 'LoadWorld("In-door Map.wld")' That is what you use |
| ||
Okay. |