Please can someone help me to fix a script, I am not sure where is wrong. The script must make Solmyr jump at different locations at specified time. So far it works, but I have a few visual glitches and game slow when running, I guess there is a better way? Solmyr is green AI hero.
!#TM66:S1/999/1/8; green player every day
!?TM66&-51;
!!VRv55:S0; initialize Solmyr variable
!!VRv333:+1; daily counter
!!HE45:P?y5/?y6/?y7; *where is Solmyr
!!TRy5/y6/y7:T?y10/d/d/d/d/d/d/d;
!!VRv333&y10=8:-1;
!!FU&y10=8:E; If in boat, exit and retry tomorrow
[Count all towns and store number in y4]
!!UN:U98/-1/?y4;
!!VRv1:S-1; [Initialize v1 to -1 to work with new faster UN:U syntax]
!!DO333/1/y4/1|v333=127/v333=135/v333=148/v333=185/v333=195/v333=215/v333=223/v333=232/v333=240/v333=270/v333=300:P; the days when he must jump
!!VRv333&v55=45:-1; subtract if Solmyr in garrison and retry tomorrow
!?FU333;
[Store location of next castle in v1/v2/v3]
!!UN:U98/-1/-1/1;
!!CA1:H0/?v55; check for hero in garrison
!!FU&v55=45:E; exit if Solmyr in garrison
!!HE45&v333=127:P124/40/1/1;
!!HE45&v333=135:P73/40/0/1;
[...etc]
(This post was last modified: 16.07.2011 16:03 by Valery.)