Welcome Guest [Log In] [Register]
We hope you enjoy your visit.


You're currently viewing the Ultimate 3D Community as a guest. This means that you can only read posts, but can not create posts or topics by yourself. To be able to post you need to register. Then you can participate in the community active and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.

Join our community!

If you are already a member please log in to your account to access all of our features:

Username:   Password:
Add Reply
Texture...
Topic Started: Oct 22 2008, 12:18 PM (403 Views)
d3m0n
Newbie
[ * ]
Trouble loading a texture in U3d. Using the code on both the tutorial and that of the manual and I get the error returned:

"Unable to open the file for reading"
"Failed to load the texture N:\I-Media\My Games\Test 1\gfx\Wall.JPEG. File input is not valid."

The script I'mn using is

LoadTexture("N:\I-Media\My Games\Test 1\gfx\Wall.JPEG",1);

Do i need to have this in a code section or in a script and can any tell me where i've gone wrong.
Offline Profile Quote Post Goto Top
 
Despellanion
Member Avatar
Forum God
[ *  *  *  *  *  * ]
d3m0n
Oct 22 2008, 12:18 PM
Trouble loading a texture in U3d. Using the code on both the tutorial and that of the manual and I get the error returned:

"Unable to open the file for reading"
"Failed to load the texture N:\I-Media\My Games\Test 1\gfx\Wall.JPEG. File input is not valid."

The script I'mn using is

LoadTexture("N:\I-Media\My Games\Test 1\gfx\Wall.JPEG",1);

Do i need to have this in a code section or in a script and can any tell me where i've gone wrong.
You have specified too much unnecessary information about the path. This would be enough:
Code:
 

LoadTexture("gfx/Wall.JPEG",1);

You only have to specify the path from your_game_folder/, because U3D will only be looking for resources in the sub-folders of the folder where the game files and the DLL is located. Default location for textures is "gfx". You can change this in the options script of U3D.
Edited by Despellanion, Oct 22 2008, 04:59 PM.
Offline Profile Quote Post Goto Top
 
d3m0n
Newbie
[ * ]
Thank you for suggestions

Unfortunatly the same error is still appearing.

"Unable to open file for reading"
"Unable to load texture "gfx/Wall.JPEG". File input is not valid."

I'm not sure why the file input is not valid
Offline Profile Quote Post Goto Top
 
Despellanion
Member Avatar
Forum God
[ *  *  *  *  *  * ]
make sure the texture actually exists in the gfx-folder ;) And I don't think you need capital letters in "jpeg", not that it should matter though.
Offline Profile Quote Post Goto Top
 
d3m0n
Newbie
[ * ]
Yes. The gfx file does exist... at least I double checked it did :D

Still returns that error. So not quite sure why its not accepting it. Is it possible to send me a file with a simple room and the texture loaded in it so I can double check my work against it.

Cheers.
Offline Profile Quote Post Goto Top
 
Despellanion
Member Avatar
Forum God
[ *  *  *  *  *  * ]
Maybe there's something wrong with your texture file? Try saving it as another format, e.g *.png.
Offline Profile Quote Post Goto Top
 
d3m0n
Newbie
[ * ]
Thanks.

The error messages no longer appear, it just doesn't load the texture.

so no idea why.
Offline Profile Quote Post Goto Top
 
Bazza
Member Avatar
Forum God
[ *  *  *  *  *  * ]
were in the game are u loading the texture?
My instinct is to hide in this barrel, like the wily fish.
Offline Profile Quote Post Goto Top
 
Reikyrr
Forum God
[ *  *  *  *  *  * ]
It would be an awesome blooper if he just typed the wrong extension and it was jpg instead of jpeg.
~Inspirational quote~
Offline Profile Quote Post Goto Top
 
« Previous Topic · Questions about Ultimate 3D · Next Topic »
Add Reply