Posted: Fri Sep 15, 2023 6:14 am Post subject: Script to input sequence of values over time?
Brand new to the forum so apologies if this is the wrong place or if I'm not following etiquette...
The title might be a bad description but I'll try to explain in more detail here.
I'm using the Hexington table for Elden Ring to manipulate which attacks an enemy can throw out. This is done by inputting the Anim. ID in the "Value" field for "Idle Animation", which then gets fed into the "Current Animation" row at the next opportunity. The Value of "Idle Animation" then resets to -1 once the animation has begun.
What I'd like to be able to do is feed an entire combo sequence into the "Idle Animation" field over time. So something like this (obviously have no idea what language or syntax would actually be used, just using to illustrate):
Set Value to 3016
Wait
If Value = -1, Then
Set Value to 3018
Wait
If Value = -1, Then
Set Value to 3023
Wait
If Value = -1, Then
I'm a complete noob with more advanced functionality of CE. I don't mind doing my own further reading, but I just need some recommendations for what literature to look at and where to start.
-- strings are what you'd enter into "Change Value" prompt
local values = {
'3016',
'3018',
'3023',
}
if setAnimTimer then setAnimTimer.destroy(); setAnimTimer = nil end
local memrec = AddressList.getMemoryRecordByDescription'Idle Animation'
assert(memrec, 'Memory record does not exist')
local i = 1
setAnimTimer = createTimer()
setAnimTimer.OnTimer = function(t)
if memrec.NumericalValue == -1 then
memrec.Value = values[i]
if i == #values then
t.Enabled = false
end
i = i + 1
end
end
_________________
I don't know where I'm going, but I'll figure it out when I get there.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum