Open LostTemple1990 opened 3 years ago
after checking out all the random-target effect, it seems that only this spell causes two effects on a random target
As I changed things as stated in https://github.com/LostTemple1990/Issues-of-self-debugged-VenturePlan/issues/8#issuecomment-915915975, I have the following outcomes:
1
with no oracle, the random targets could be wrong and thus incorrect regardless of this.0
with no oracle, the range of the checkpoints across all forks will be correct, but it will be inefficient and inaccurate due to the quantity of incorrect forks.I had wondered about how such a scenario would work when I was working through the data, as it never came up before. For the sake of scenario 2, I agree that the target logic should be adjusted to reuse the same random target across all effects for a spell, which will drastically reduce the number of forks needed.
Off the top of my head, implementation could be as simple as:
mu:cast
, do self.randomTargets[sourceIndex..'-'..sid] = nil
or similar, to reset any saved target.mu:qcast
(where I've already rewritten a lot), add a new condition after the forkTargets
checking that is similar to if self.randomTargets[sourceIndex..'-'..sid] then forkTarget = self.randomTargets[sourceIndex..'-'..sid] end
, to use an earlier effect's target if it already exists.mu:qcast
(again), change some conditions for forkTarget
to only use it if the forkTarget
is truthy but not true
, to handle cases where there was no valid target on the earlier effect, so it should still skip trying to get a new target and forking.mu:qcast
(still), do self.randomTargets[sourceIndex..'-'..sid] = tt or true
or similar within the forkTarget
handling, to save the target even if there was no valid targets.
in patch 9.15 the spell 125 was set to
though it works well in sim but there is a problem this spell select a random-enemy and deal the effect 1 and 2 to the same target which is selected but in sim,it seems to run twice for this spell when it casts (first for the first effect,and second for the next) It seems that a new target logic is needed if keep dividing spell effects by effect index in real log Perhaps it may change to
which
target
is the key of the original table like the keyfirstTurn
does