Gamestudio Links
Zorro Links
Newest Posts
lookback setting performance issue
by 7th_zorro. 04/16/24 03:08
folder management functions
by 7th_zorro. 04/15/24 10:10
zorro 64bit command line support
by 7th_zorro. 04/15/24 09:36
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:48
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:46
LPDIRECT3DCUBETEXTUR
E9

by Ayumi. 04/12/24 11:00
Sam Foster Sound | Experienced Game Composer for Hire
by titanicpiano14. 04/11/24 14:56
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (Volkovstudio, 7th_zorro, Aku_Aku), 336 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
11honza11, ccorrea, sakolin, rajesh7827, juergen_wue
19045 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
History & HistoryFolder #484520
11/06/21 22:57
11/06/21 22:57
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline OP
Serious User
DdlV  Offline OP
Serious User
D

Joined: Jun 2013
Posts: 1,609
Hi @jcl,

If the History variable is not set, the manual says it defaults to the History subfolder.

This appears to be incorrect if HistoryFolder is set in Zorro[Fix].ini. In that case, History defaults to that HistoryFolder, as expected.

This appears to be the only case that HistoryFolder affects History. If the History variable is set, HistoryFolder appears to be ignored.

If History includes a relative path, it is relative to the Zorro folder. This allows specifying a subfolder of History via, f.i., "History\\subfolder\\*.t6".

I would like to be able to use History to specify subfolders of HistoryFolder, in this same way. Is there a way to do that?

If not, can History be enhanced to default to HistoryFolder if specified, so that one could then do, f.i., "subfolder\\*.t6" to point History to HistoryFolder\subfolder\*.t6?

Thanks.

Re: History & HistoryFolder [Re: DdlV] #486209
06/23/22 23:23
06/23/22 23:23
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline OP
Serious User
DdlV  Offline OP
Serious User
D

Joined: Jun 2013
Posts: 1,609
Hi @jcl,

I think in any case History should be initialized to the value of HistoryFolder.

In addition, can History's value be included in the Performance Report as a record of what History was used?

Thanks.

Re: History & HistoryFolder [Re: DdlV] #486213
06/24/22 10:00
06/24/22 10:00
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
That makes sense. I've put it on the todo list and we'll implement it in a future version.

Update: I have been informed that it is already so. History uses the HistoryFolder unless you enter some other folder. For a subfolder of a different history folder, you must enter the full path.

Re: History & HistoryFolder [Re: DdlV] #486215
06/24/22 23:42
06/24/22 23:42
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline OP
Serious User
DdlV  Offline OP
Serious User
D

Joined: Jun 2013
Posts: 1,609
Hi @jcl,

I just ran a few tests on 2.48:

- Fresh install. Select New Script. At the end of the template that comes up, add "printf("\nHistory=%s", History);". Save. Click Test. Zorro crashes (window just disappears). Log file is 0 bytes.

- Restart Zorro. Add "History="whatever";" before the printf. Save. Click Test. "History=whatever" prints.

- Copy Zorro.ini to ZorroFix.ini. In ZorroFix.ini change HistoryFolder to "somewhere". Restart Zorro. Click Test. Zorro complains there's no history for EUR/USD in somewhere, then prints "History=somewhere".

- Comment out the "History="whatever":" statement. Save. Click Test. Zorro complains there's no history for EUR/USD in somewhere, then prints "History=".

Seems not quite right...

Thanks.

Re: History & HistoryFolder [Re: DdlV] #486217
06/25/22 18:53
06/25/22 18:53
Joined: Apr 2008
Posts: 585
Austria
Petra Offline
Support
Petra  Offline
Support

Joined: Apr 2008
Posts: 585
Austria
What seems not quite right? The crash?

When you print something without setting it before, it is an empty pointer. It will of course crash.

Re: History & HistoryFolder [Re: DdlV] #486223
06/27/22 05:48
06/27/22 05:48
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline OP
Serious User
DdlV  Offline OP
Serious User
D

Joined: Jun 2013
Posts: 1,609
Thanks @Petra. Based on @jcl's comment above, History should be initialized to HistoryFolder's value, therefore should not be an empty pointer, therefore should not crash! It appears that History is in fact not being initialized...

Re: History & HistoryFolder [Re: DdlV] #486224
06/27/22 08:05
06/27/22 08:05
Joined: Apr 2008
Posts: 585
Austria
Petra Offline
Support
Petra  Offline
Support

Joined: Apr 2008
Posts: 585
Austria
History is a string to be set by the user. It has no content when you dont set it. And when you set it it defaults to the historyfolder unless you explicitly set a different folder.

https://zorro-project.com/manual/en/script.htm

Re: History & HistoryFolder [Re: DdlV] #486227
06/27/22 15:07
06/27/22 15:07
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline OP
Serious User
DdlV  Offline OP
Serious User
D

Joined: Jun 2013
Posts: 1,609
Thanks @Petra. Actually, the linked page is labelled "Predefined Strings" and says History has a default value when not set by the user. This simply appears not to be the case. At least not completely. It appears to take a non-default HistoryFolder value, but appears to be uninitialized when HistoryFolder is its default "History". I believe it should be initialized in all cases, no?

Re: History & HistoryFolder [Re: DdlV] #486231
06/30/22 01:32
06/30/22 01:32
Joined: Jun 2013
Posts: 1,609
D
DdlV Offline OP
Serious User
DdlV  Offline OP
Serious User
D

Joined: Jun 2013
Posts: 1,609
Hi @jcl. Not sure if you continued following this thread. Thanks for @Petra's help! But it still appears there's a problem/bug in the initialization of History.

Re: History & HistoryFolder [Re: DdlV] #486232
06/30/22 07:18
06/30/22 07:18
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
What problem do you have still?

Page 1 of 2 1 2

Moderated by  Petra 

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