Thread: Puttering around with Automation
-
March 27th, 2022, 21:53 #11
Modifying manager_actions_xxx; how naughty is this?
Ronnke and Damned
Is it bad (not good practice) for an extension to modify/replace an manager_actions_xxx.lua? I'm wondering because it would be best (I think, to call for a critical roll directly from those files instead of sniffing the chat until the appropriate message pops up). I'm not sure on this though. I'll post the extension (which is still raw (not RAW, but somewhat sloppy and uncooked) but working) shortly if anyone wants to have a gander. Currently it is registering melee/ranged criticals (success and failure); unarmed critical failure; spell critical failure; and head hit critical success (if the hit location is skull or face).
Mostly I want to get an idea from people that have more experience is I should keep it as it is 'observing' chat, or roll it from one of the combat/spell etc actions (which is scary in my mind but would only change a few lines basically calling the process).
Thanks!Anybody want a peanut!
-
March 27th, 2022, 22:35 #12
You can replace specific functions in those named lua scripts, no need to replace them all. You can even do your stuff and then call the original function.
See the onInit function here: https://github.com/bmos/FG-PFRPG-Spe...ll_failure.lua
-
March 27th, 2022, 22:58 #13
Thanks Bmos; I figured I could, just not sure if I SHOULD I'll putter around and see if it's worth it; I suspect it might be better, but I have to look at them again (I only scanned them trying to learn all this stuff).
Anybody want a peanut!
-
March 27th, 2022, 23:12 #14
The baby is starting to function!
I need to do a lot of editing to remove some of the stuff that isn't used or was used once, then reconfigured (I've started and abandoned this as I grew better skills with lua and extensions; I have to say I'm probably at the peak of that first learning curve when I think I know a lot, but I actually don't -- I know I don't know a lot, but I don't know what I don't know ).
Anybody want a peanut!
-
March 27th, 2022, 23:57 #15
- Join Date
- Apr 2010
- Location
- Australia
- Posts
- 905
Timezone: Australian EST (GMT +10).
Systems/Rulesets: GURPS 4th Edition.
Campaigns (Ultimate License Holder)
GURPS Traveller - The Empty Peace
GURPS Shadowrun - Power Plays
GURPS Banestorm - Dark Clouds Rising
-
March 28th, 2022, 03:16 #16
I should have mentioned that gm rolls currently need to be on (and there is a little combat automation choice in options that has to be turned on). I'm not sure why gm rolls have to be on, but it's for whatever reason the audiooverseer also needs to... maybe the chat callback?
I'm looking into Bmos' suggestionAnybody want a peanut!
-
March 28th, 2022, 19:37 #17
If I have this right in my head now (it'll take me some time to really parse it to make sense to me fully) I have to roll the critical (if there is one, and they have the options turned on) in the _melee or _ranged (or spell, once I find that file ) and just after
Code:rMessage.diemodifier = (bAddMod and rRoll.nMod or 0); Comm.deliverChatMessage(rMessage);
I'm 99 44/100% sure that I can't do this in the GamesSystem.rollResult(#, #) because that only contains if it's critical and nothing else (it could return a critical for a skill roll, and I don't want to be rolling on a table since that function only gets passed #, not a roll. Side note I think I'm slowing understanding the DB functions a bit too (not sure what sMode is, but I'm suspecting it might be cut/imp/pi etc; I haven't done a search but I notice it isn't actually used in the _melee and _ranged, but it's declared)
(most of the time when I ask a question it's like thinking out loud)Anybody want a peanut!
-
March 28th, 2022, 22:00 #18
- Join Date
- May 2013
- Location
- East Coast USA.
- Posts
- 962
-
March 28th, 2022, 22:27 #19What does Gurps Criticals rough.ext do? I loaded it up and I didn't see any difference.
Then roll melee, ranged, spell, unarmed (can't be the skill, has to be punch, kick bite, etc -- I may be missing some unarmed techniques though) or spell
if Ronnke or someone else with brains (ie. anyone by me ) is looking, I seem to get an error (nil value) when I try to use GameSystem.rollResult... I basically cut and pasted the _melee file and all the other GameSystem results work; for now I've copied the rollResult into the 'new' _melee that I'm making and it works fine in there. So I'm not sure why it's being grumpy.Anybody want a peanut!
-
March 28th, 2022, 22:42 #20
Me for an hour and a half: Why isn't it picking up the fact that the spell is a critical failure!
Me an hour and half later: .... because you're using _melee....Anybody want a peanut!
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks