Requesting add-on or modification for XAS abs script

'sup guys.
Wile taking a small break from my main, bigger, rm2k3 project, I'm working on some easy peasy stuff for rmvxa, and I'm working on a small hack&slash-like title that revolves around the XAS Active Battle System, which I think everybody knows ('tho I'll post the script down there for those who don't).

Now, wile the BS itself is pretty awesome and works perfectly with what I'm doing, it lacks a small feature that I could use, and that's the ability turn on one of the monster's event self switch when the latter is killed.

The script already provides you with the ability to turn on a specific switch, but considering those are very limited in VXA (it's not even the number of switches itself, because it's probably more than enough, but the way the system works, I would have to create X copies of the same enemy for each istance of said enemy in the game, and those ARE limited indeed), I wouldn't mind if I could activate selfswitches as well.

I think this require an addon script.
Alternatively, I guess i could edit somewhere in the script to modify what happens when the event get erased, to instead having it to turn on Self Switch C, since I don't plan on using the erase event funcion (or, to be specific, the event page that would be active when SelfSwitch C is on would take care of erasing the event)... this could actually be like a one-string editing, but still I have no clue what string to edit and what to put, since I'm just one inch above the "total noob" at scripting and I don't plan on learning rgss since I don't plan of doing much stuff with VXA anyway.

I wanted to post the script but apparently it's too long,
I'll link the official page (or whar I think it's the official page 😛 ) in the hope i'm not breaking any rule:
https://atelierrgss.wordpress.com/rgss3-xiderowg-action-system-xas/
You'll be pleased to know that giving a link was exactly the right thing to do. We always ask for a link, and not the script itself, because many scripters do not like their scripts being reposted, and it also ensures that anyone who needs to check it has access to any other info or discussion on the original web page which can help.
just giving this a small bump, 'tho I actually made some progress:
so I put this stuff somewhere in between the script

execute_active_switch(enemy)
execute_active_selfsw(enemy) #ghostino
execute_defeated_animation(enemy)


around line 5488 (it might be different because the script already has some modification made by me, to shoot ranged weapons from the "shield" slot) - where you see #ghostino is my edit.

A little bit down I put the following:

#---------------------------------------------------------------------------
# ● Execute Active Self Switch (Addon by ghostino)
#---------------------------------------------------------------------------
def execute_active_selfsw(enemy)
if enemy.note =~ /<Active SelfSwitch>/
$game_self_switches[[@map_id, 12, 'C']] = true
end
end

Pretty easy to understand: whenever an enemy with the <Active SelSwitch> notetag is killed, self-switch C of event 12 of the current map (@map_id) is turned on, and... it works! well... kinda 😛

I know I'm kinda on the right path, but I need to understand what "code" to put instead of the number 12 to make the game understand that I'm refering to the event-monster I just killed. I already tried with @event_id, but didnt work.

Can anyone help me?
That should be a simple @id instead of @event_id.
That should be a simple @id instead of @event_id.

it worked!

man this was awesome, thanks a lot, you really helped me out 🙂

Original thread: https://forums.rpgmakerweb.com/threads/requesting-add-on-or-modification-for-xas-abs-script.89895/