Gamestudio Links
Zorro Links
Newest Posts
Executing Trades on Next Bar Open
by vicknick. 06/13/24 08:51
Zorro Beta 2.61: PyTorch
by jcl. 06/10/24 14:42
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (Ayumi), 1,170 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19059 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Creating a relative path #298400
11/14/09 18:19
11/14/09 18:19
Joined: Aug 2009
Posts: 19
D
Dominator Offline OP
Newbie
Dominator  Offline OP
Newbie
D

Joined: Aug 2009
Posts: 19
In the game I am making I have my script in a folder. I want to make a relative path that goes down one level to a background folder.

With the help in the manual I cant figure out how to make the path.

Re: Creating a relative path [Re: Dominator] #298423
11/14/09 22:01
11/14/09 22:01
Joined: Aug 2007
Posts: 1,922
Schweiz
Widi Offline
Serious User
Widi  Offline
Serious User

Joined: Aug 2007
Posts: 1,922
Schweiz
#define PRAGMA_PATH "Sound";

Re: Creating a relative path [Re: Widi] #298445
11/15/09 03:27
11/15/09 03:27
Joined: Nov 2009
Posts: 34
S
Sepiantum Offline
Newbie
Sepiantum  Offline
Newbie
S

Joined: Nov 2009
Posts: 34
you could do something like this:

FILE* fp = file_open("folder\\another folder\\file.txt");

Or something along the lines of that. Just use the escape sequence \\ for a \ to define your path.

Re: Creating a relative path [Re: Sepiantum] #298545
11/15/09 22:26
11/15/09 22:26
Joined: Aug 2009
Posts: 19
D
Dominator Offline OP
Newbie
Dominator  Offline OP
Newbie
D

Joined: Aug 2009
Posts: 19
I want the whole folder to be there not just a single file.
I also tried the first way and it still couldn't find the image.

To clarify I want to create a path to go down one folder level from my main script.

Re: Creating a relative path [Re: Dominator] #298686
11/16/09 22:30
11/16/09 22:30
Joined: Apr 2006
Posts: 737
Ottawa, Canada
O
Ottawa Offline
User
Ottawa  Offline
User
O

Joined: Apr 2006
Posts: 737
Ottawa, Canada
Hi!

You could try

#define PRAGMA_PATH "..\\Models";


Hope this helps!
Ottawa laugh

Ver 7.86.2 Pro and Lite-C
Re: Creating a relative path [Re: Ottawa] #298952
11/19/09 16:54
11/19/09 16:54
Joined: Aug 2009
Posts: 19
D
Dominator Offline OP
Newbie
Dominator  Offline OP
Newbie
D

Joined: Aug 2009
Posts: 19
Yes, it worked to create it like that.

thank you for the help.


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1