Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, dr_panther, Quad), 935 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
[WED] Can't work with foldered scripts? #423191
05/25/13 12:45
05/25/13 12:45
Joined: Oct 2009
Posts: 90
WickWoody Offline OP
Junior Member
WickWoody  Offline OP
Junior Member

Joined: Oct 2009
Posts: 90
Hi,

I decided to tidying my work files. I foldered them seperately like "models", "audio", "script", "levels" etc. When I tried to select map's script as "main.c", then I got a error message which says "player.c" couldn't open. My directory is like;

Code:
- deved (main folder)
  - levels
  - audio
  - scripts
  - images
  - models
  * main.c
  * settings.c



WED can't open the files which I store them in a sub-folder like "scripts". I included them in main.c. I used the PRAGMA_PATH and include. But doesn't work.

What should I do?

Thanks in advance.

Re: [WED] Can't work with foldered scripts? [Re: WickWoody] #423232
05/25/13 21:19
05/25/13 21:19

M
Malice
Unregistered
Malice
Unregistered
M



Wed has issues - I just keep all my scripts in the main folder till I'm finished.

Last edited by Malice; 05/25/13 21:47.
Re: [WED] Can't work with foldered scripts? [Re: ] #423235
05/25/13 22:36
05/25/13 22:36
Joined: Apr 2005
Posts: 653
Germany
D
Det Offline
User
Det  Offline
User
D

Joined: Apr 2005
Posts: 653
Germany
The easy way is to do all Scprits Models and Pictures and Level files to do in your Game Folder . Then you include you Scrpts in your main Script like Enemy and so on . Start the main Script and it works. You can also use the Work Folder in Gamestudio with all your files .


Wissen ist macht.
Nichts wissen macht auch nichts.

A7.86
Re: [WED] Can't work with foldered scripts? [Re: Det] #423237
05/25/13 23:05
05/25/13 23:05
Joined: Oct 2009
Posts: 90
WickWoody Offline OP
Junior Member
WickWoody  Offline OP
Junior Member

Joined: Oct 2009
Posts: 90
I understand, thank you.

Re: [WED] Can't work with foldered scripts? [Re: WickWoody] #423261
05/27/13 08:09
05/27/13 08:09
Joined: Jul 2008
Posts: 2,107
Germany
rayp Offline

X
rayp  Offline

X

Joined: Jul 2008
Posts: 2,107
Germany
Use
Code:
pragma_path

fex. to add folders via script. So easy is this.
Quote:
A7.10 Looks for include and other files in the given path when they are not found in the current folder. This is similar to the PATH statement in a project file, with the exception that paths given by PRAGMA_PATH are also used for include files. Example:
#define PRAGMA_PATH "%EXE_DIR%\Map-Editor\Scripts";

Last edited by rayp; 05/27/13 08:14.

Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Re: [WED] Can't work with foldered scripts? [Re: WickWoody] #423356
05/28/13 13:47
05/28/13 13:47
Joined: Oct 2009
Posts: 90
WickWoody Offline OP
Junior Member
WickWoody  Offline OP
Junior Member

Joined: Oct 2009
Posts: 90
Originally Posted By: WickWoody

I used the PRAGMA_PATH and include.


I said that I'm already using it.

Re: [WED] Can't work with foldered scripts? [Re: WickWoody] #423389
05/29/13 04:51
05/29/13 04:51
Joined: Jul 2008
Posts: 2,107
Germany
rayp Offline

X
rayp  Offline

X

Joined: Jul 2008
Posts: 2,107
Germany
Sorry. But pragma_path works normally.


Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Re: [WED] Can't work with foldered scripts? [Re: WickWoody] #423391
05/29/13 07:48
05/29/13 07:48
Joined: Nov 2006
Posts: 59
Alberta, Canada
Dveyee Offline
Junior Member
Dveyee  Offline
Junior Member

Joined: Nov 2006
Posts: 59
Alberta, Canada
Maybe you setup the PRAGMA_PATH wrong. At the top of your main.c it should look something like this :
Code:
#define PRAGMA_PATH "models"
#define PRAGMA_PATH "audio"
#define PRAGMA_PATH "scripts"
#define PRAGMA_PATH "scripts\some_sub_directory"
#define PRAGMA_PATH "levels"


Then when you run your main.c, it should find all the scripts.


Accelerated Game Creation Tutorial - Learn how to use 3D Gamestudio's WED with these exciting video tutorials!

Visit our website at http://www.accgames.com.

Moderated by  HeelX, rvL_eXile 

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