Skip to content

Posts from Scripts

4.8 (8 ratings)
User Avatar
13 years ago
Auto-translated
aa. I understand. I thought there might be a simpler way to do it. Thanks.
13 years ago
Auto-translated
Is there a way to make specific artifacts appear in the artifact shop?
In reply to Mostovik
User Avatar
13 years ago
Auto-translated
Mostovik
Is it possible to set up the artifact shop so that specific artifacts appear there?
Ban all other artifacts on the map.
In reply to Mostovik
User Avatar
13 years ago
Auto-translated
Mostovik
Is it possible to make it so that specific artifacts appear in the artifact shop?
Is it specifically necessary to have it in the shop? What about posters? :rolleyes: :D
Or even simpler: a "pen" of artifacts, you open a certain door, and you get that artifact.
In reply to RedHeavenHero
User Avatar
13 years ago
Auto-translated
RedHeavenHero
Ban all other artifacts on the map.
Yeah, and how will you play with only 6 artifacts?

Added 2 minutes later
Dyrman
Is it necessary to be in the shop? What about posters? :rolleyes: :D
Or even simpler: an "enclosure" of artifacts, you open a door, and you get what's inside.
That's the right way, or it's easier to do and less of a hassle. But honestly, I remember seeing somewhere how to make only certain artifacts appear in the shop. But unfortunately, I don't remember.
User Avatar
13 years ago
Auto-translated
I don't understand something. I want to change the lighting on the map, and I'm doing it like this:

SetAmbientLight (0, "/Lights/_(AmbientLight)/BrighterDay.xdb#xpointer(/AmbientLight)" , nil, 0)

There's no error, but the light doesn't change either. What's the problem?
13 years ago
Auto-translated
Thank you, those methods don't work for me. :(
Also, do the items available in the shop somehow depend on the OGO (Overall Game Options) or who is accessing it? In RTA (The Restoration of Erathia), there was a situation where there was a small selection of amulets and relics, so in one of the shops (and there are 16+4 on the map in the castles of Dungeon and Academy), the relic slot was empty. I had to duplicate the amulet of absorption in the list of items on the map to prevent this (in this way, the probability of the amulet of absorption appearing probably increased by 2 times). I was wondering if it's possible to use such clever methods to assign specific artifacts to certain shops?!
In reply to Heroist
User Avatar
13 years ago
Auto-translated
Heroist
I don't understand something. I want to change the lighting on the map. I do it like this:

SetAmbientLight (0, "/Lights/_(AmbientLight)/BrighterDay.xdb#xpointer(/AmbientLight)" , nil, 0)

There's no error, but the light doesn't change. What's the problem?
You need to: copy the xdb file you need into the map, open it, and check if InternalName and Name are set. If not, set them (set whatever you want, but use Latin characters and no quotes).
Then, in map.xdb, find Ground(Underground)AmbientLights and add the following line:
, where Light is what you put in the Name and InternalName fields.
And only then use the script.
In reply to Heroist
User Avatar
13 years ago
Auto-translated
Heroist
I don't understand something. I want to change the lighting on the map. I do it like this:

SetAmbientLight (0, "/Lights/_(AmbientLight)/BrighterDay.xdb#xpointer(/AmbientLight)" , nil, 0)

There is no error, but the light doesn't change. What's the problem?
1. Add this lighting as one of the elements in GroundAmbientLights (or UndergroundAmbientLights if you plan to change the lighting in a dungeon) in the map properties.
2. The lighting must have a script name (InternalName); for this lighting, it's "BrighterDay"; for others, see the corresponding files. If there is no name, create one.
3. You need to write the script name in the function.
User Avatar
13 years ago
Auto-translated
It doesn't work.
In the editor, I added the necessary light, and I wrote the script names correctly.
The only thing is, when I viewed it with WinRAR, the new light didn't appear, but as soon as I created a folder named "lights" in the map, it immediately filled up as it should, with all the internal files.
I rewrote the link in the script, following the instructions, but there are no errors in the panel, yet it still doesn't work.
Could it be that the problem is that I have "original" lights on the map that work by default?
In reply to Heroist
User Avatar
13 years ago
Auto-translated
If you did everything correctly, it should work. I checked before writing this. What exactly did you do?

Added 12 minutes later
Perhaps both lighting options are very similar, and the change was not noticeable?
User Avatar
13 years ago
Auto-translated
Well, I wrote everything above. Now I'll try the same thing with any Inferno light; it will definitely be noticeable.
In reply to Heroist
User Avatar
13 years ago
Auto-translated
I already said that the script name for the lighting should be inserted into the function – "BrighterDay", "Inferno_light", which is in InternalName. And not the file path. Everything else is correct. :)
Yes, and it's also not necessary to include the lighting file that already exists in the game's resources. ;)
Thanks for the screenshots; they clarified everything.

Statistics

Welcome our newest member: recijeb