failed to parse non-numeric... /crashing head

Need help with a macro you are writing? Ask here!

Moderator: MacroQuest Developers

mauroxx
orc pawn
orc pawn
Posts: 24
Joined: Mon Jan 31, 2005 5:23 am

failed to parse non-numeric... /crashing head

Post by mauroxx » Mon Feb 14, 2005 6:10 am

Code: Select all

Sub Event_reqa(text,player,Fulltext)
 /echo ${player} asking for ${fulltext}
 /if (${Fulltext.Equal[ch])==1) /varset Fulltext "Complete Healing"
 /target ${player}
 /call cast "${Fulltext}" gem8 2s   
/return
error is on

Code: Select all

/if (${Fulltext.Equal[ch])==1)
non-numeric ... i tryed also without ==1 ... but cant solve this, i get always stuck on if conditions... i m still newbie...

help me plz!

Mauroxx

Devious_D
a lesser mummy
a lesser mummy
Posts: 30
Joined: Wed Jan 05, 2005 2:59 pm

Post by Devious_D » Mon Feb 14, 2005 6:38 am

instead of

Code: Select all

/if (${Fulltext.Equal[ch][color=cyan])==1)[/color]
try

Code: Select all

/if (${Fulltext.Equal[ch]})
Your main problem was not having } instead you just had )

Arune
a hill giant
a hill giant
Posts: 216
Joined: Sat Jul 03, 2004 1:51 pm

Post by Arune » Mon Feb 14, 2005 9:52 am

Correct me if I am wrong, but wouldnt using that make the mac execute the CH string with words like each, peach, tech, chair, school, etc?

wassup
Official Guardian and Writer of TFM
Official Guardian and Writer of TFM
Posts: 1487
Joined: Sat Oct 26, 2002 5:15 pm

Post by wassup » Tue Feb 15, 2005 2:25 am

Arune wrote:Correct me if I am wrong, but wouldnt using that make the mac execute the CH string with words like each, peach, tech, chair, school, etc?
That would be

Code: Select all

/if (${Fulltext.Find[ch]})

User avatar
blueninja
a grimling bloodguard
a grimling bloodguard
Posts: 541
Joined: Thu Aug 28, 2003 7:03 am
Location: Göteborg, Sweden

Post by blueninja » Tue Feb 15, 2005 4:01 am

I don't really know how mq2 handles this but in other languages you wouldn't be able to change a variable that's been passed as an argument to your function..

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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:27 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:28 pm


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

Re: failed to parse non-numeric... /crashing head

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


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:30 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:32 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:33 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:34 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:35 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:36 pm


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

Re: failed to parse non-numeric... /crashing head

Post by xyilla » Thu Apr 10, 2025 8:37 pm