Berserker
Posts: 16731
|
|
25.05.2021 21:28 |
|
SergOz
Posts: 1330
|
igrik , выручай! 
Мне даже не столь важна смена картинки - кто там её разглядывает - мне нужно заменить описание способности "Враг".
Функционал способности полностью устраивает. Его менять не нужно.
Карта-мод "Война на Холсте"
|
|
25.05.2021 21:43 |
|
Berserker
Posts: 16731
|
|
26.05.2021 00:01 |
|
igrik
Posts: 2819
|
|
26.05.2021 08:53 |
|
Archer30
Posts: 1190
|
Interesting, looks like v1 should be avoided in most cases?
When I test Obelisk Rune option (script 35, option 43) on the official scenario Heroes of Might Not Magic (SoD map), there were several ERM error popping out, saying x coordinate was not right.
The code:
Code:
!?PI;
!!UN:P43/?y-1; [Check if script is enabled: y-1]
!!FU&y-1<>1:E; [Exit if script isn't enabled]
!!UN:U57/-1/?y-2; [Number of Obelisks on map: y-2]
!!VRv1:S-1; [Initialize v1 to -1 to work with new faster UN:U syntax]
!!DO5312/1/y-2/1&y-2>0:P; [Loop through all Obelisks to set spell]
!?FU5312;
!!UN:U57/-1/-1/1; [Store next Obelisk coordinates in v1/v2/v3]
!!FU$spell$:P0/0/1/0/1/0; [Determine random non-banned Adventure Spell number: y-99]
!!IF:M^%v1, %v2, %v3, %v4^;[For TESTING]
!!POv1/v2/v3:Sy-99; [Set spell number (S) to y-99 -- will be -1 if all spells banned]
Looks fine to me at the first glance. However, the value returned of v1 was 47379860.
Any idea why this happened?
It was an easy fix after I figure out v1 was the issue. Used v2 instead and everything's fine again.
Latest ERA mods and scripts in development - My GitHub
(This post was last modified: 26.05.2021 23:35 by Archer30.)
|
|
26.05.2021 23:13 |
|
Berserker
Posts: 16731
|
|
26.05.2021 23:15 |
|
Archer30
Posts: 1190
|
|
26.05.2021 23:34 |
|
Berserker
Posts: 16731
|
|
26.05.2021 23:48 |
|
Archer30
Posts: 1190
|
Strange. After shifting v-vars to +1, the script run well on Heroes of Might Not Magic, but the same issue happened on All for One (RoE scenario). x coordinate was wrong on one of the obelisk (returned -1).
Things are getting confusing. The v-var for x coordinate was set in !!UN:U, why it has to change before !!PO:S?
I tried with v3/v4/v5, problem's gone, but still wondering the reason of it.
Latest ERA mods and scripts in development - My GitHub
|
|
27.05.2021 02:06 |
|
Berserker
Posts: 16731
|
|
27.05.2021 02:09 |
|
SergOz
Posts: 1330
|
|
27.05.2021 11:40 |
|
Archer30
Posts: 1190
|
|
27.05.2021 13:10 |
|
fatsawhorse
Posts: 1022
|
Здравствуйте..
А как можно запретить артефакт командирский передать командиру?
Я очень бы хотел запретить артефакт 149 (шлем бессмертия) вставлять в командира? Что-то не могу додуматься как это вообще сделать?
(This post was last modified: 28.05.2021 20:34 by fatsawhorse.)
|
|
28.05.2021 20:29 |
|
SergOz
Posts: 1330
|
|
28.05.2021 23:08 |
|