Hi everyone, im trying make a refiner via macro, already try another but dont work fine for me.
I make this:
automacro forjando {
location prt_in
eval $::config{Forja} eq "1" ## I added this in config, only bcz i use the same config to sell too.
timeout 1
call forjandom
}
macro forjandom {
if equipped rightHand = none goto up0 ## I ALREADY TRY WITHOUT THE EQUAL (=) BUT DOESNT WORK ##
:up0 ## AND TRY PUT ALL IF BEFORE THE ":GOTOS" ##
do eq @inventory (Main Gacuhe [4])
goto end
if equipped rightHand = Main Gauche [4] goto up1
:up1
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +1 Main Gauche [4] goto up2
:up2
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +2 Main Gauche [4] goto up3
:up3
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +3 Main Gauche [4] goto up4
:up4
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +4 Main Gauche [4] goto up5
:up5
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +5 Main Gauche [4] goto up6
:up6
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +6 Main Gauche [4] goto up7
:up7
do talknpc 63 60 c r0 c r0 n
goto end
if equipped rightHand = +7 Main Gauche [4] goto up8
:up8
do talknpc 63 60 c r0 c r0 c c r0 n
goto end
if equipped rightHand = +8 Main Gauche [4] goto up9
:up9
do talknpc 63 60 c r0 c r0 c c r0 n
goto end
if equipped rightHand = +9 Main Gauche [4] goto up10
:up10
do talknpc 63 60 c r0 c r0 c c r0 n
goto end
if equipped rightHand = +10 Main Gauche [4] goto pronto
:pronto
do uneq +10 Main Gauche [4]
goto end
if (@invamount "Phracon" < 1) goto comprafracon
:comprafracon
do talknpc 56 68 c r0 c d70 n
goto end
:end
}
but after all test, i get this:
and insisting search i dont found or make any progress in hours, and it make me angry and i dont think well angry , soo im asking for help..
If anyone can help me, or a suggestion..
Thanks!
[Idle/Partially Solved]If functions
Moderator: Moderators
-
- Noob
- Posts: 8
- Joined: 08 Jan 2015, 07:10
- Noob?: No
Re: If functions
That's not how you write if statements, http://www.tizag.com/perlT/perlif.php
-
- Noob
- Posts: 8
- Joined: 08 Jan 2015, 07:10
- Noob?: No
Re: If functions
Thanks for the link Virulent!
I will remake for a clean macro..
again, thanks.
I solution for time:
I will remake for a clean macro..
again, thanks.
I solution for time:
automacro up0 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1" ## Add a line Forja in Config.txt ##
equipped rightHand none
timeout 1
call {
do eq Main Gauche [4]
}
}
automacro up1 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up2 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +1 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up3 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +2 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up4 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +3 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up5 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +4 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up6 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +5 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up7 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +6 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 n
}
}
automacro up8 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +7 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 c c r0 n
}
}
automacro up9 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +8 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 c c r0 n
}
}
automacro up10 {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +9 Main Gauche [4]
timeout 1
call {
do talknpc 63 60 c r0 c r0 c c r0 n
}
}
automacro upok {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
equipped rightHand +10 Main Gauche [4]
timeout 1
call {
do uneq +10 Main Gauche [4]
}
}
automacro fracon {
location prt_in
exclusive 1
eval $::config{Forja} eq "1"
inventory "Phracon" < 5
timeout 1
call {
do talknpc 56 68 c r0 c d50 n
}
}