Page 1 of 2

Re: Creating Macros - Step by step

Posted: Tue 21.05.2019, 17:45
by ema
Hi,

lot of troubles with macros because they aren't saved, so I create and recreate always the same 7 starting macros...:(
What can be wrong?

Saving macros

Posted: Wed 22.05.2019, 17:38
by ema
Please People of MAngband,

I can't save my macros, they work just in the current session but, after quitting, most of them desappear, so I create and re-create the same macros every session...
Someone can help me?
Thx a lot!

Re: Creating Macros - Step by step

Posted: Thu 23.05.2019, 07:03
by Flambard
Assuming everything works as expected, you're supposed to save your macros into a file. (%, 2)

Then, you are supposed to load this file on each session. (%, 1)

The following files are auto-loaded: user-<SYS>.prf, <PClass>.prf, <PRace>prf, <Playername>.prf and also any file included[1] from user.prf.

So, if you're on SDL, and playing a Human Mage, named Rincewind, the files user-sdl.prf, mage.prf, human.prf and Rincewind.prf will be auto-loaded.

([1]: If you examine user.prf, you will see that the prf files can also include each other via the '%:filename.prf' command).

If that doesn't help, you should verify

a) that the file was saved as you expected - do you see your saved file in user dir?
b) that you can load the file manually - using %,1

I should be able to provide more guidance once you've verified both a) and b).

Re: Creating Macros - Step by step

Posted: Thu 23.05.2019, 16:22
by ema
Thx for Your help, Flambard!

Till now to learn what's an SDL...in IT I'm a Sardinian goat, unfortunately.

In my library I just find this:
[attachment=0]Lib Sinclair.png[/attachment]

Re: Creating Macros - Step by step

Posted: Thu 23.05.2019, 18:46
by ema
Other problem:
I inscribed F1 so: \ef1*t; now (other session), pressing F1, the macro is: \eq3.

Re: Creating Macros - Step by step

Posted: Fri 24.05.2019, 14:19
by ema
restarting from the beginning, just to be goat-proof, in case of arrow assigned to Fn1, I type:
3
\ef1*t
Enter
5
Fn1 (here the mirror says to me "Created a new normal macro")
enter (but doesn't work)
2
Enter
Esc (and here the mirror doesn't say anything, so I think macro is not saved)

Re: Creating Macros - Step by step

Posted: Fri 24.05.2019, 17:31
by Flambard
SDL is the "Multi-window" client and it expects the macros to be in 'user-sdl.prf'.

Apparently, you're using normal Windows clients, so the macros should be in 'user-win.prf'.

The file seem to exist on your screenshot, could you try opening it in with something like Wordpad and verify the contents?

Can you then verify that the file DOES NOT load automatically (e.g. % Macro Menu, 7 Macro Browser, the macros from the file do not exist)?

Can you also test what happens if you press (1 Load File) and enter 'user-win.prf' manually?

Re: Creating Macros - Step by step

Posted: Fri 24.05.2019, 19:52
by ema
Here in "user-win.prf" the last two macros re-created today:
# Macro '49'

A:\ef1*t
P:\[F1]


# Macro '50'

A:\er3
P:\[F3]
(yesterday I re-created 9 macros...anf!)
and here the content if I browse with "7":
[attachment=0]Browse lib Sinclair key 7.png[/attachment]

Then tried to load "user-win.prf" manually but in F1 now I find macro \er3
(I had to Delete macro-key "-" to type "user-win")

Re: Creating Macros - Step by step

Posted: Sat 25.05.2019, 18:52
by ema
If I write manually macros in user-win.prf?

Re: Creating Macros - Step by step

Posted: Sun 26.05.2019, 15:22
by ema
Well, I try to switch to Tomenet, sadly, because here is my first, only love.
Ever sadly, I verified here nobody is playing.

Re: Creating Macros - Step by step

Posted: Mon 27.05.2019, 07:54
by Flambard
I'll try to re-trace your steps and see if I find anything.

Could be something fundamentally broken (on the windows build?)

Sorry for not getting to you earlier, and yeah, we aren't a densely populated server :(

UPDATE: Yup, those are bugs, plain and simple, will be fixed in the next version.

Re: Saving macros

Posted: Thu 30.05.2019, 14:02
by Flambard
Turned out what you experienced was a deadly combination of two bugs (#1288 and #1289) and not the expected behavior :(

Thanks a lot for bringing attention to this.

This has been fixed in 1.5.2 client.

(Moving to bug reports forum)

Re: Saving macros

Posted: Thu 30.05.2019, 19:53
by ema
Wow! Thx a lot Flambard!!!
I can just write now because I was in hospitalization for a few days...
Just the last question: have I to disinstall the version 1.5.1 before download and install 1.5.2?

Re: Saving macros

Posted: Thu 30.05.2019, 20:00
by Flambard
There is an uninstall option in the Start / Programs / MAngband menu on windows.

You might also want to visit the user pref dir (the one with user-win.prf and others) and delete the pref files you wrote earlier, as those are definitely broken.

Re: Saving macros

Posted: Thu 30.05.2019, 20:55
by ema
mmmh...I remember in the old versions of MAngband (some years ago) I used keys like "-", "N", "x" and "h", for example...
But now these keys interact with macros in other section of the game (like in the shops) or in creating macros (like \em1h with key "h" as macro command).
In this case should be an error in my sequence macro creating (I see now new command (8,9,0))?
Sorry for my unbelievable english...