Not getting last sub properly when includes used

A forum for reporting bugs NOT related to custom plugins.

Moderator: MacroQuest Developers

dark2phoenix
a hill giant
a hill giant
Posts: 218
Joined: Wed Dec 22, 2004 9:42 am

Not getting last sub properly when includes used

Post by dark2phoenix » Wed Mar 09, 2005 11:43 pm

I'm not exactly sure what's going on, but here's what I figured out. With the 03/05+ versions of MQ2 the autoenc.mac from the VIP section stopped working. When you run it says:

Code: Select all

Flow ran into another subroutine 
move.inc@46 (MoveToLoc(MoveToY, MoveToX)):Sub MoveToLoc9MoveToY, MoveToX) 
ench.mac@313 (Main): /if (!${validTarget} || (!${nukeMode} && !${useDebuff} && !${useMez})) { 
After playing around with this for 3 days I figured out it wasn't getting out of the last routine in the gen_routines.inc file that was getting included. Not sure why, but I tried moving that routine around. Doing that, I found whichever routine was LAST didn't ever end properly, almost like it isn't getting imported properly.

I was able to see this problem with other macros that used includes (though, honestly, they were all by Rusty and used spell_routines.inc and gen_routines.inc and move.inc).

I "fixed" all my problem by just creating a dummy routine at the end of each include file that I wouldn't ever use.

Is there some way someone can verify the problem and the solution?

JGC84
a ghoul
a ghoul
Posts: 116
Joined: Sat Nov 29, 2003 2:51 am

Post by JGC84 » Wed Mar 09, 2005 11:47 pm

just sounds to me like your missing a /return on one of your subs i'd go through every subroutine in move.inc and ench.mac and check them all.
ACK! I think I blew it up....

I dont think your allowed to talk about this outside of a "free speech zone" anymore.

Lax
We're not worthy!
We're not worthy!
Posts: 3524
Joined: Thu Oct 17, 2002 1:01 pm
Location: ISBoxer
Contact:

Post by Lax » Wed Mar 09, 2005 11:54 pm

dkaa recently added some code that was supposed to fix a bug with includes -- the last line would sometimes get ignored apparently, probably because of no cr/lf at the end.

I would make sure you have an empty line at the end of all your include files.
Lax Lacks
Master of MQ2 Disaster
Purveyor of premium, EULA-safe MMORPG Multiboxing Software
* Multiboxing with ISBoxer: Quick Start Video
* EQPlayNice, WinEQ 2.0

dark2phoenix
a hill giant
a hill giant
Posts: 218
Joined: Wed Dec 22, 2004 9:42 am

Post by dark2phoenix » Thu Mar 10, 2005 1:18 am

OK, I feel stupid.

I swear I tried adding returns to the files but when I checked only my main macro had the extra carriage return.

Everything seems to be working now. I did reload all my .inc's from the VIP posts before I know about the Group changes so maybe that's why they worked before and now now (used ot have the extra returns, didn't when I reloaded them).

Oh well, anyways, thanks!

User avatar
dont_know_at_all
Developer
Developer
Posts: 5450
Joined: Sun Dec 01, 2002 4:15 am
Location: Florida, USA
Contact:

Post by dont_know_at_all » Thu Mar 10, 2005 3:42 am

This should be fixed with the latest zip.

xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:09 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:10 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:12 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:49 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:50 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:51 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:52 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:53 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:54 pm


xyilla
naggy
naggy
Posts: 33673
Joined: Sun Feb 23, 2025 5:36 am

Re: Not getting last sub properly when includes used

Post by xyilla » Tue Apr 29, 2025 8:56 pm