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.

AppGameKit Classic Chat / [SOLVED] .x files wont load

Author
Message
DC Sound System
8
Years of Service
User Offline
Joined: 14th Feb 2016
Location:
Posted: 4th Jan 2020 04:07
Hello,

I'm having a problem with loading .x files into AGK. I can load the internal cube and sphere shapes. But anything external that I try just doesn't load. No error, everything compiles, just air where the object should be. I tried using the search function in AppGameKit and it says it can't find the file. The file is in the same directory as the game file. Any thoughts?

The author of this post has marked a post as an answer.

Go to answer

fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 4th Jan 2020 07:02
Not much info about what OS
but Linux and Android are both case sensitive and will cause that error if the name isn't case matched
ie object.X is different than object.x or Object.X etc
MerryChristmas Everyone
fubarpk on Itch...………...https://fubarpk.itch.io/
fubarpk on googleplay..https://play.google.com/store/apps/developer?id=fubarpk
Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 4th Jan 2020 09:31
This post has been marked by the post author as the answer.
Quote: "The file is in the same directory as the game file."

If you mean that literally, then that's your problem. AppGameKit will be looking for the file in a 'media' folder inside the game folder.
DC Sound System
8
Years of Service
User Offline
Joined: 14th Feb 2016
Location:
Posted: 4th Jan 2020 16:22 Edited at: 4th Jan 2020 17:32
So I did have it in the actual same directory. Last time I used a TGC product it was DBC so I'm still kind of used to that... But I moved my file to a "media/Models" folder and it still can't find it.

The OS is windows 7 professional service pack 1. I'm pretty sure it isn't a case issue though. When I try to load in a ".obj" object I get this message "Error: Could not find file cube.obj in main.agc at line 20". It looks like things have progressed a lot since DBC, do you need to import it into your project or something now?
DC Sound System
8
Years of Service
User Offline
Joined: 14th Feb 2016
Location:
Posted: 4th Jan 2020 17:45 Edited at: 4th Jan 2020 17:49
Whoo! Fixed it! It was a problem with the new directory thing. So the default path for 3D models is in a "media" folder. Does that go for 2D images too? How about if I want to read a ".txt" file? Does that need to be in a special directory by default?
Loktofeit
AGK Developer
15
Years of Service
User Offline
Joined: 21st Jan 2009
Location: Sarasota, FL
Posted: 4th Jan 2020 20:50 Edited at: 5th Jan 2020 23:08
"So the default path for 3D models is in a "media" folder. Does that go for 2D images too? How about if I want to read a ".txt" file?"

Default path for everything your program reads is the media folder.
DC Sound System
8
Years of Service
User Offline
Joined: 14th Feb 2016
Location:
Posted: 4th Jan 2020 22:31
Cool. Thanks for the info.

Login to post a reply

Server time is: 2024-04-16 10:47:02
Your offset time is: 2024-04-16 10:47:02