Post 2002-08-30 Feature Requests

A forum for the general posts relating to MacroQuest. *DEPRECATED: This forum is no longer in public use, but remains here for your reading pleasure. Enjoy

Moderator: MacroQuest Developers

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Sat Sep 07, 2002 9:33 pm

I can understand the want for exp info and thats a good idea IMHO but why do you want string manipulation features... what would you use it for?
rk

User avatar
DeathSpiral
a ghoul
a ghoul
Posts: 95
Joined: Thu Aug 22, 2002 6:31 pm

Post by DeathSpiral » Sun Sep 08, 2002 12:34 am

rizwank wrote:I can understand the want for exp info and thats a good idea IMHO but why do you want string manipulation features... what would you use it for?
I can think of a number of things I'd use text manipulation for, but only if it were coupled with a $strlen(). The ability to walk a string, for example, could potentially be useful. Also, using strtoupper, strtolower to make sure case is identical when doing string comparisons.

User avatar
L124RD
Site Admin
Site Admin
Posts: 1343
Joined: Fri Jun 14, 2002 12:15 am
Location: Cyberspace
Contact:

Post by L124RD » Sun Sep 08, 2002 12:54 am

Salutations,
MQ isn't case sensitive to begin with... except events i think...

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Sun Sep 08, 2002 3:06 am

OMG LOGO!

WALK 100
RT 90

khazil
orc pawn
orc pawn
Posts: 24
Joined: Wed Sep 04, 2002 8:52 pm

Post by khazil » Sun Sep 08, 2002 12:14 pm

No offense, Riz, but if you can't think of any uses for string manipulation functions, you haven't done much programming untill recently. :)

I'd use them for situations that require the macro to have very precise knowledge of the information it's given. I can think of several uses, such as parsing through a string sent to it by another macro (through tell, or whatnot). Yes, I know there's the $arg() function, but that doesn't cover everything I'd need.

As for Case Sensitivity, well, strings passed to arrays all end up lowercase, and ~~ doesn't seem to be case insensitive. For my macro, I had a list of names of people who could interact with it. When a tell or group invite was sent, the macro should have checked the names and given the correct people access. Instead, no one was able to use it. I tried everything, but eventually I had to go with using and authentication /tell to make sure unauthorized people don't have access. Highly annoying.

I don't mind that /if is case sensitive. I do mind the fact that I can't do anything about the strings in my variables, and the fact that arrays like to set everything to lowercase, regardless of how they went in.

Besides, if the functionality is there, people will use it, whether the original designers saw a use for it or not. It'll make coding that much easier.

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Sun Sep 08, 2002 12:58 pm

Slight offense taken, but ill shrug it off.

String manipulation is important, it was a question of its usefulness here... Someone said to "walk a string" and that is a good idea there... Im currently thinking in terms of the macros we have so far; and I cant see how many of them would benefit from these; however, if it is there, it will be used :)
khazil wrote:No offense, Riz, but if you can't think of any uses for string manipulation functions, you haven't done much programming untill recently. :)

I'd use them for situations that require the macro to have very precise knowledge of the information it's given. I can think of several uses, such as parsing through a string sent to it by another macro (through tell, or whatnot). Yes, I know there's the $arg() function, but that doesn't cover everything I'd need.
Last edited by rizwank on Sun Sep 08, 2002 8:54 pm, edited 1 time in total.

Valerian
a grimling bloodguard
a grimling bloodguard
Posts: 709
Joined: Sun Jul 28, 2002 3:29 am

Post by Valerian » Sun Sep 08, 2002 6:52 pm

no, someone said "walk a string" which is immensely different than "walk a path".
DeathSpiral wrote:I can think of a number of things I'd use text manipulation for, but only if it were coupled with a $strlen(). The ability to walk a string, for example, could potentially be useful. Also, using strtoupper, strtolower to make sure case is identical when doing string comparisons.

khazil
orc pawn
orc pawn
Posts: 24
Joined: Wed Sep 04, 2002 8:52 pm

Post by khazil » Wed Sep 11, 2002 12:41 pm

No one said anything about walking a path...

Either way, how bout it, coders? String manipulation functions?

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Wed Sep 11, 2002 12:48 pm

I edited my post from walk a path to walk a string ;p

I dunno, this is a Plaz question... I think there is a place to put it in the sourceforge thing too..

User avatar
Coraz
a lesser mummy
a lesser mummy
Posts: 41
Joined: Mon Sep 09, 2002 11:24 pm

Post by Coraz » Wed Sep 11, 2002 5:08 pm

I'd like a little help learning what all of the confusing#var=$~~! /sub blap stuff means! :shock:

I feel so dumb :oops:

Amadeus
The Maestro
The Maestro
Posts: 2036
Joined: Sat Jun 29, 2002 3:51 pm

Post by Amadeus » Wed Sep 11, 2002 8:21 pm

I would like to request a modification to /tell that would allow you to abbreviate names. This would only work within the current zone.

For example, I would love to be able to send a tell to Baowolfe by just typing /tell bao hey!!

...Maybe it's not possible, but it's a request all the same :)

Digitalxero
a ghoul
a ghoul
Posts: 129
Joined: Tue Sep 10, 2002 5:01 pm

Custom variable names

Post by Digitalxero » Wed Sep 11, 2002 8:22 pm

Custom var names
Currently you can only have v# p# a# l# ect as var
names, what I would like is to be able to have custom
var names

/varset string Textvar "This is a string variable"

/echo $Textvar

[MacroQuest]This is a string variable

Others I would like to see

/varset array arrayvar [one,two,three,four,testing,ect]

/echo $arrayvar[0]

[MacroQuest]one

/varset array arrayvarone[one=>1,hp=>$target
(hp,pct),ect=>other stuff]

/echo $arrayvarone[one]
/echo $arrayvarone[hp]
[MacroQuest]1
[MacroQuest]35

/varset int intagervar 15
/varset loc locvar ###.##,###.##,###.##
/varset sloc Locname sx,sy

sx and sy = screen xy cords


Might think of others after those are added and I play
with them a bit.

Custom var names just could not have the same name
as one of your static ones, this would make the macro's
alot easyer to read also, and you wont have namespace
spillover if people start combining several macros. Also
currently there is only support for v0 - v100 This should
be increased to atleast 1000 or 10,000 untill you can
add customvar names. That way people can pick a
range of 100 vars they wana work with.


You also might consider adding ; as the end of
command determiner so that formating becomes easyer
once you add custom var names, and such

ie. /varset array Arrayvar [
HP=>$target(hp,cur),
MANA=>$char(mana,cur),
ECT=>more stuff];

That way it can spreat to multi lines easyer.

Wouldnt mind if you added a new command also

@<Variable Name> = <text string,array(array options),
#, Loc,screen)

##Example of declaring an array
@Arrayvar = array(
HP=>$target(hp,cur),
Mana=>$char(mana,cur),
ECT=>other shit);


##String
@Stringvar = "This is a string variable";
OR
@Stringvar = "$target(name)";

##Int
@Intvar = 7;

##Loc
@Locvar = 75.23,189.01,30.5;

##Screen
@Screencord = 50,100;


Also I think if you get rid of a few of the / commands
such as /if it may speed up the parsing a bit since it
knows it isnt an EQ command it wont try and parse it as
such

mouseto
if
for
sendkey
press
click
echo
goto
call
doevents
return

All of those should be removed from the slash command
list and just made keywords. I would keep the / versions
in the for backward compatability but make them
deprciated and have MacroQuest spit a warning when it
loads a macro with the old version saying that these are
depreciated and will be removed in future release ect.

if should be changed to support and add elseif

Code: Select all

if(xxx==yyy OR xxx=zzz AND xxx!=aaa){ 
do this shit 
} 
elseif(xxx==bbb){ 
do something else 
} 
else{ 
Do yet another thing 
} 
for should also support this format

Code: Select all

for(i=0;i<$something;i++){ 
the for loop; 
} 

User avatar
L124RD
Site Admin
Site Admin
Posts: 1343
Joined: Fri Jun 14, 2002 12:15 am
Location: Cyberspace
Contact:

Post by L124RD » Wed Sep 11, 2002 9:18 pm

Salutations,
custom var names... dum dum dum...
[[Apparently l124rd can't read write code brackets... /boggle l124rd]]

Code: Select all

#define hp v0
#define mana v1
#define class v2
#define race v3
#define level v4
#define name v5

sub main
 /varset hp $char(hp,max)
 /varset mana $char(mana,max)
 /varset class $char(class)
 /varset race $char(race)
 /varset level $char(level)
 /varset name $char(name)
 /echo $name is a level $level $reace $class with $hp hit points and $mana mana.
/return
Last edited by L124RD on Wed Sep 11, 2002 9:53 pm, edited 1 time in total.

Valerian
a grimling bloodguard
a grimling bloodguard
Posts: 709
Joined: Sun Jul 28, 2002 3:29 am

Post by Valerian » Wed Sep 11, 2002 9:42 pm

and I thought L124RD liked code brackets... *chuckles*
L124RD wrote:/return[/code[

User avatar
Fippy
a snow griffon
a snow griffon
Posts: 499
Joined: Tue Jul 16, 2002 10:42 am

Post by Fippy » Thu Sep 12, 2002 5:54 am

I would like to see a filter for alerts so I can specify a loc and a radius so i could do something like

Code: Select all

/alert clear 1
/alert add basilisk

/alert clear 2
/alert add 2 loc 210,340 radius 90


/target alert 1 noalert 2

What this would do is avoid targeting basilisks that are within the radius of the specified loc. That way you can avoid an inappropriate bath in a lava pool.

What would also be cool would be Events based on the alert list so to continue the example above

Code: Select all


sub main

:Loop
/alert clear 1
/alert add basilisk

/alert clear 2
/alert add 2 loc 210,340 radius 90

/doevents
/target alert 1 noalert 2

/goto :Loop
/return

/sub Event_Alert

 /echo Alert $p0 was triggered by Alert line $p1

/return
this would echo to the screen something like

Alert 1 was triggered by Alert Line a, basilisk
Alert 1 was triggered by Alert Line a, basilisk
Alert 1 was triggered by Alert Line a, basilisk
Alert 2 was triggered by loc 210,340 radius 90
Alert 1 was triggered by Alert Line a, basilisk