How to reduce delay in macro loop

For everything NOT server specific support. Do NOT ask for connectivity help here!.

Moderator: Moderators

Message
Author
Turbo
Noob
Noob
Posts: 2
Joined: 27 Jun 2015, 01:17
Noob?: Yes

How to reduce delay in macro loop

#1 Post by Turbo »

Code: Select all

automacro kill {
exclusive 1
priority 1
player /(Turbo)/i
call {
$player = @player ($.lastMatch1)
do sp 46 $player
}
}
I'm using this by Xkore, on a private server with ping 150-200
I need to spam this macro when the player mentioned is my range, but there is so much delay for each loop. it has like 1-2 seconds delay for each double strafe. Need help in spamming the macro loop without delay. To be short, i want to make openkore macro work like a WPE packet sender, except here i can change the skill ID and player name whenever i want.

Thanks in advance to the community.
Regards
Turbo

andora
Noob
Noob
Posts: 19
Joined: 24 Mar 2015, 17:20
Noob?: No

Re: How to reduce delay in macro loop

#2 Post by andora »

I believe you can make use of this code:

Code: Select all

macro_delay (timeout)
to know more of the macro codes you can look here:

this is from the latest openkore svn.

Code: Select all

# $Id: Data.pm r6753 2009-07-02 00:43:00Z ezza $
package Macro::Data;

use strict;

require Exporter;
our ($rev) = q$Revision: 6753 $ =~ /(\d+)/;
our @ISA = qw(Exporter);
our @EXPORT = qw(@perl_name %macro %automacro %varStack $queue $onHold %amSingle %amMulti $macroKeywords);

our @perl_name;
our %macro;
our %automacro;
our %varStack;
our $queue;
our $onHold;
our $inBlock;

our %amSingle = (
	'map' => 1,          # map check
	'mapchange' => 1,    # map change check
	'class' => 1,        # job class check
	'timeout' => 1,      # setting: re-check timeout
	'delay' => 1,        # option: delay before the macro starts
	'run-once' => 1,     # option: run automacro only once
	'disabled' => 1,     # option: automacro disabled
	'call' => 1,         # setting: macro to be called
	'spell' => 1,        # check: cast sensor
	'notMonster' => 1,   # check: disallow monsters other than ~
	'pm' => 1,           # check: private message
	'pubm' => 1,         # check: public chat
	'system' => 1,       # check: system chat
	'guild' => 1,        # check: guild chat
	'party' => 1,        # check: party chat
	'console' => 1,      # check: console message
	'overrideAI' => 1,   # option: override AI
	'orphan' => 1,       # option: orphan handling
	'macro_delay' => 1,  # option: default macro delay
	'hook' => 1,         # check: openkore hook
	'priority' => 1,     # option: automacro priority
	'exclusive' => 1,    # option: is macro interruptible
	'playerguild' => 1,  # check: player guilds
	'eval' => 1,         # check : eval
	'whenGround' => 1,   # check : when ground statuses
	'areaSpell' => 1     # check : area spell
);

our %amMulti = (
	'set' => 1,          # set: variable
	'save' => 1,         # setting: save hook arguments
	'monster' => 1,      # check: monster on screen
	'aggressives' => 1,  # check: aggressives
	'location' => 1,     # check: player's location
	'var' => 1,          # check: variable / value
	'varvar' => 1,       # check: nested variable / value
	'base' => 1,         # check: base level
	'job' => 1,          # check: job level
	'hp' => 1,           # check: player's hp
	'sp' => 1,           # check: player's sp
	'spirit' => 1,       # check: spirit spheres
	'weight' => 1,       # check: player's weight
	'cartweight' => 1,   # check: cart weight
	'soldout' => 1,      # check: sold out shop slots
	'zeny' => 1,         # check: player's zeny
	'cash' => 1,         # check: player's cash
	'player' => 1,       # check: player name near
	'equipped' => 1,     # check: equipment
	'status' => 1,       # check: player's status
	'inventory' => 1,    # check: item amount in inventory
	'storage' => 1,      # check: item amount in storage
	'shop' => 1,         # check: item amount in shop
	'cart' => 1,         # check: item amount in cart
	'localtime' => 1     # check: localtime
);

our $macroKeywords =
	"npc"          . "|" .
	"store"        . "|" .
	"player"       . "|" .
	"monster"      . "|" .
	"venderitem"   . "|" .
	"venderprice"  . "|" .
	"venderamount" . "|" .
	"random"       . "|" .
	"rand"         . "|" .
	"invamount"    . "|" .
	"cartamount"   . "|" .
	"shopamount"   . "|" .
	"storamount"   . "|" .
	"[Ii]nventory" . "|" .
	"[Ss]torage"   . "|" .
	"[Cc]art"      . "|" .
	"vender"       . "|" .
	"config"       . "|" .
	"eval"         . "|" .
	"arg"          . "|" .
	"listitem"     . "|" .
   	"nick"         . "|" .
	"listlenght"
;

1;


Turbo
Noob
Noob
Posts: 2
Joined: 27 Jun 2015, 01:17
Noob?: Yes

Re: How to reduce delay in macro loop

#3 Post by Turbo »

andora wrote: I believe you can make use of this code:

Code:
macro_delay (timeout)


to know more of the macro codes you can look here:

this is from the latest openkore svn.
Thanks for the information, but i believe macro_delay is used for a pause inside the loop.

andora
Noob
Noob
Posts: 19
Joined: 24 Mar 2015, 17:20
Noob?: No

Re: How to reduce delay in macro loop

#4 Post by andora »

nope. that would be 'pause' and 'delay'

Post Reply