Looking for pointers on integrating two scripts

To be clear, I'm not expecting someone to build the solution for me!


Unlike when I was younger, I'm attempting to learn RGSS, so this is a good opportunity.

I'm attempting to integrate three scripts together that would make for an incredible combination. Starting with the first two though!
However, no matter what script order or (admittedly, probably ridiculous) changes I try to make. I can't seem to get past two errors.

The creator of one script is nowhere to be found, and the other has long since moved on to MZ.

If anyone might be willing to throw me a few pointers to help out an RGSS newbie. Help would be greatly appreciated. You can message me here, or soon I'll have contact info on my profile!
I'm happy to help you, but you haven't given any information on which scripts you're trying to integrate or what the errors are.
The problem here is that unless scripts are independent and automatically work together, it is almost always an individual rewrite of some functions in form of a compatibility patch that is needed, and there are no "general rules" on how to go at that, it always is different and based on which scripts are to be combined.
Sure! My apologies, I wasn't at my desk just yet.

I'm attempting to integrate Blizzard & Winkio's BlizzABS with Heretic86's Dynamic Lighting.

When ordered as I have them normally, both at the bottom of my order with Lighting above the ABS, things work just fine...except time doesn't move. I have it set to continue passing time even when in battle and while the interpreter is running - still nothing.
Manually changing the time works UNTIL the shift into dawn when the light events opacity begins to change. Forcing dawn with a script call works, but is immediate. As soon as he shift to dawn begins, I'm met with:

NoMethod Error - undefined method 'reset_light_event_daynight_opacity' for #<Map_Enemy:0xb79df70>

Which is referring to:

#-------------------------------------------------------------------------- # * Reset Event Light Daynight Opacity - Game_System # - Resets Opacity of Lights and Events responsive to Day / Night Cycles #-------------------------------------------------------------------------- def reset_event_light_daynight_opacity # Return if no Game Map exists return unless $game_map # Iterate every Event for event in $game_map.events.values # Set the Event and any Lights to proper Opacity Levels event.reset_light_event_daynight_opacity end end

With the event call method being

#-------------------------------------------------------------------------- # * Reset Light Event Daynight Opacity - Game_Event # - Resets Lights and Events to proper Opacities # - Used when an Event sets the Game_Variable that holds Time #-------------------------------------------------------------------------- def reset_light_event_daynight_opacity # If this Event's Opacity responds to Day / Night Cycles if not @light_event_opacity.nil? and @light_event_opacity[1].is_a?(Numeric) # Reset any Lightning Opacities reset_lightning_opacity # Clear Property @light_opacity_duration = nil # Call Setup Method to determine Opacity event_light_opacity_setup end # If Event has a Light and reacts to Daynight Transitions if @light and @light.daynight_opacity and @light.daynight_opacity[1] # Reset any Lightning Opacities @light.reset_lightning_opacity # Call Setup Method to determine Opacity @light.daynight_opacity_setup end end

Now I'm positive this has to do with light processing on ABS Enemies. If I reverse the script order, I get an instant crash with:

'Blizz-ABS Part 2' NoMethodError undefined method 'refresh' for #<Game_Player>

This is just simply referring to a $game_player.refresh call, which doesn't get redefined or aliased in either scripts.

My best guess for a fix is to ad an exception for the event.daynight_reset to ignore ABS enemies when its iterating through events, but If I can't get lights to work for enemies, that would be a huge bummer.

I don't know really, I just started learning RGSS like 3 days ago. x.x
I'm just now realizing that Map_Enemy is a custom subclass of a custom class in the ABS. Perhaps I could alias a method to add the lighting info and methods to it? I dont even know where to start there, haha.

So Im assuming a custom compatibility script is about the only way to do this, then.
I'm in way over my head methinks on this one.
The creator of one script is nowhere to be found, and the other has long since moved on to MZ.
To clarify, Heretic is still around, but mostly pops in whenever he has questions regarding some programming project he's working on (seems to be an editor on a web browser). Blizzard uses MV, but still can answer questions regarding RGSS/his scripts. However, neither are in the mood to support their scripts when it comes to adding compatibility with others. That's been my job on the CP forums for the past decade.

Anyways, seems I have answered this question before a few years ago:

This requires a number of modifications to Dynamic Lights to support for BABS. I wouldn't recommend this be your first rodeo into making scripts compatible.
You know, I was honestly considering hitting you up on Discord a few hours ago, I just figured popping up out of the blue would be odd. I know you're one of the few active coders hanging around Chaos Project forums.


Im surprised I never found that reply through all my searching, but I'll definitely bookmark it! Glad to hear that Heretic is still around, I figured he had just moved on from XP like most everyone.

I spent the whole day just trying to get the iteration to recognize Map_Enemy and you're absolutely right, it's way beyond my current skill level to make an add-on that would have to go that high up in the hierarchy.
I've made some testy scripts work together before but Blizz-ABS and Heretic's Lighting are on another level of complexity. I'm going to fry up some smaller fish first.

Thank you so much though! That answers that. ^^
Moved to: RGSSx Script Support

Double-post notice: @RhizTekar

Original thread: https://forums.rpgmakerweb.com/threads/looking-for-pointers-on-integrating-two-scripts.141752/