|
Thread: ERA II - Source code - Help and discussion | This thread is pages long: 1 2 3 4 5 6 7 8 9 10 11 · «PREV / NEXT» |
|
gamemaster
Adventuring Hero
|
posted April 12, 2020 02:13 PM |
|
|
@Bersy
Last commit (12d1f35) on github is unfinished, work in progress?
There are lot problems with VR receiver.
All but !#VR:S is unrecognized and produce error message.
All !!VR produce arithmetic error.
Tested with wog and basic scripts only.
|
|
Bersy
Honorable
Supreme Hero
|
posted April 13, 2020 12:36 AM |
|
|
|
gamemaster
Adventuring Hero
|
posted April 22, 2020 10:21 PM |
|
|
in last commit (519b27a):
is operation involving +^...^ still work in progress?
|
|
Bersy
Honorable
Supreme Hero
|
posted April 25, 2020 07:25 PM |
|
|
|
bloodsucker
Legendary Hero
|
posted May 19, 2020 07:09 PM |
|
|
Hi, I haven't been playing Wog/Era for quite sometime but suddenly I remembered some stuff and wanted to make a few suggestions. I'm not sure where they would fit, so decided to make them here. Sorry for the inconvenience.
1. The week of the creature script doesn't save the actual parameters of the creature, so when the week ends it returns them to the original. If you have used the Emerald Tower or similar to change them, you lose everything. It would be a good idea to save those values and return them to where they were.
2. If you maintain the decision of keeping the Emerald Towers bugged so they work only once, something I wish you reconsidered, then I think it would be better to create a simpler object with less interactions, since many end up making no sense. It should have a fight instead of a cost, since that's how one time visit objects generally work.
____________
|
|
RerryR
Promising
Supreme Hero
Researching Magic
|
posted May 19, 2020 08:35 PM |
|
|
I never knew the reason for this bug, but that makes sense.
Maybe I can change it.
|
|
bloodsucker
Legendary Hero
|
posted May 19, 2020 09:23 PM |
|
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted May 19, 2020 09:58 PM |
|
|
Well the error with emerald towers is here, a simple typo y-1/v1
!!UN:U63/65/?y-1; [Number of Emerald Towers: v1]
!!VRv1:S-1; [Initialize v1 to -1 to work with new faster UN:U syntax]
!!DO10910/1/v1/1&y-1>0:P; [Loop through all Emerald Towers]
Strange that we didn't fix it in wog revised.
|
|
RerryR
Promising
Supreme Hero
Researching Magic
|
posted May 19, 2020 10:15 PM |
|
Edited by RerryR at 22:19, 19 May 2020.
|
Salamandre said: Well the error with emerald towers is here, a simple typo y-1/v1
!!UN:U63/65/?y-1; [Number of Emerald Towers: v1]
!!VRv1:S-1; [Initialize v1 to -1 to work with new faster UN:U syntax]
!!DO10910/1/v1/1&y-1>0:P; [Loop through all Emerald Towers]
Strange that we didn't fix it in wog revised.
Thanks, I will forward to Igrik, so it can be included in the next WoG scripts update.
Edit: In the current Git reposit it seems already correct.
|
|
bloodsucker
Legendary Hero
|
posted May 19, 2020 11:31 PM |
|
|
Salamandre said: Strange that we didn't fix it in wog revised.
You decided not to because Emerald Towers are broken for AI, at least as far as I recall it.
____________
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted May 19, 2020 11:45 PM |
|
|
I don't think so, probably I ignored it because other priorities. If it was broken, we would have fixed at least the typo and set them at visit once only, as it is now is just script with error.
|
|
bloodsucker
Legendary Hero
|
posted May 20, 2020 12:20 AM |
|
|
I don't want to start a discussion when I'm getting what I want but you knew how to solve it (did it for your own maps) and instead of a fix there is a comment on the Wog Options page stating that the Emerald Tower only works once in Era.
____________
|
|
Salamandre
Admirable
Omnipresent Hero
Wog refugee
|
posted May 20, 2020 07:00 AM |
|
|
Yeah probably because a lot of custom maps already used this feature so fixing it would have make them unplayable. But then I should have fixed it in wog revised, I don't remember why I didn't, especially with such tiny error.
|
|
bloodsucker
Legendary Hero
|
posted May 20, 2020 09:22 AM |
|
|
Btw, in english You is both singular and plural, I'm not saying "Salamandre took this decision", just that it was a decision.
____________
|
|
gamemaster
Adventuring Hero
|
posted May 31, 2020 09:55 PM |
|
|
@Bersy
Last build "43fdcd5" ported.
This error is presented also in '2c0d42a' commit but not in commits before.
Occurs on mouse enter to town screen.
Edit:
Problem is with 'GetZVarAddr'. It is not replaced in all places with 'GetInterpolatedZVarAddr'.
Erm.pas(6097): Value.pc:= GetZVarAddr(Value.v);
Erm.pas(6100): Value.pc:= GetZVarAddr(Value.v);
Another question:
Is it possible to add 3rd button to "Ask" function.
Or at least detect Shift+click,
Or any other option to get result beside 'ok' and 'cancel' in "Ask" function that is used to report error in game.
|
|
Bersy
Honorable
Supreme Hero
|
posted June 01, 2020 02:20 AM |
|
|
Hi, gamemaster!
Thank you for attention and reports.
Erm.pas(6097): Value.pc:= GetZVarAddr(Value.v);
No sense for interpolation of base writable z-var. ERT-vars do not pass IsMutableZVarIndex check.
Same with 6100:
Base string var of non-z type is global named variable s^...^ (SN:W^...^). During GetErmParamValue call it's interpolated automatically and saved as temporal z-variable.
I was not able to reproduce your error. Released Era 3.0.0 alpha package. Could you extract proof-of-concept short ERM code for testing?
"Ask" function is a wrapper upon Msg. No such functionality is in default Heroes 3 dialog. You can use Msg function wrapper and specify 2 images and MES_MAY_CHOOSE type. See IF:Q in ERM help for details. 2 images for selection + ok/cancel buttons. 3 variants.
____________
Heroes 3 Era and everything for it. Releases folder for releases.
|
|
gamemaster
Adventuring Hero
|
posted June 01, 2020 02:10 PM |
|
|
I will recheck above problem.
I will try change ask wrapper to msg as you suggested.
Another thing in Erm.pas:
function IsMutableZVarIndex (Ind: integer): boolean;
begin
result := ((Ind >= Low(z^)) or (Ind <= High(z^))) or (-Ind in [Low(nz^)..High(nz^)]);
end;
If i am right this function should return true if index is in range 1 to 1000 and -1 to -10.
It will return true even for z-25 because first 'or'.
Perhaps first 'or' should be 'and'.
Just recheck this code.
For now i did not detect any problem with this merely because there are no script that has z-25 or so...
|
|
Bersy
Honorable
Supreme Hero
|
posted June 01, 2020 02:54 PM |
|
|
|
gamemaster
Adventuring Hero
|
posted June 01, 2020 04:03 PM |
|
|
Regarding problem with 'GetZVarAddr'. There is no problem. I made mistake during test.
|
|
Bersy
Honorable
Supreme Hero
|
posted June 01, 2020 10:28 PM |
|
|
|
|