Hello There, Guest! Login Register


Universal EV Trainer with Config
#1
[Image: fStXXn4.png]

READY TO USE EV TRAINER!!!



Done writing this script, Yes another EV Trainer but now with easy config.

You can now easily encode your desired map.

NOTE: You can only set 1 EV for now! But you can try to set multiple EV's to true but make sure you are ready for an error     --see on config.lua



FEATURES:

1. Easy configurable map locations - see on config.lua
2. Configurable what EV you want to train - see on config.lua
3. Configurable - How many EV's you want to earn  - see on config.lua
4. Grass, Water and Rectangle supports
5. Uses Pokecenter when pokemon 1 is fainted and out of PP
6. Many Log info supports
7. Mount support on land v2.1 -- Read configuration file
8. Item Support v3 -- Read configuration file



CHANGELOG:

08-16-2016 ~ Initial Release v1.8
08-16-2016 ~ Battle functions Reconstructed
08-16-2016 ~ Download Link Updated
08-17-2016 ~ Code rewrite/More simplier script
08-17-2016 ~ Updated to Version 2.1
08-17-2016 ~ Mount Supports on Land
08-17-2016 ~ Updated to Version 3
08-17-2016 ~ Added some logs
08-17-2016 ~ Item Supports
08-18-2016 ~ Updated to Version 3.2
08-18-2016 ~ Added switch for those who don't have a mount
08-18-2016 ~ Added some codes and logs
08-22-2016 ~ Fixing some logs
08-22-2016 ~ Fixing duplicated name of actions


Update plan:

[✔] Mount support
[✔] Macho brace function support/Item function support
[X] Many map Locations
[X] Other Cave support
[X] Dual or triple pokemon Effort Value's training
[X] Dual or triple and so on Earning Effort Value's
[X] Continue levelling when reaches your desired Effort Value's
[X] Learning Move support


External Link:
V1.8: https://drive.google.com/file/d/0BzLuVjR...sp=sharing
V2.1: https://drive.google.com/file/d/0BzLuVjR...sp=sharing
V3: https://drive.google.com/file/d/0BzLuVjR...sp=sharing
V3.2: https://drive.google.com/file/d/0BzLuVjR...sp=sharing -Outdated


Instructions:
--Manual Copying--

1.Create new folder for this scripts
2. Copy Configuration and save as "config.lua" -- You can edit configuration file according to your likes
3. Copy EV's script and save as "whatever you like.lua" -- Just copy it and don't touch if you don't know what you're doing
4. Load renamed EV's script .lua
5. Log-in and start the bot



Version 3.4(Latest)

Configuration:


  -- Copyright © 2016 redskhie                



    -- Map Configurations

-- Insert/Change the Mapnames of your training route
-- Mapnames is CASE SENSITIVE
-- Leave others blank if unused

pc = "Pokecenter Cerulean"
map1 = "Cerulean City"
map2 = "Route 24"
map3 = ""
map4 = ""
TrainingMap = "Route 25"



    -- Training Spots
-- Inserting/Changing Options: "Rectangle" , "Grass" , "Water"

TrainingSpot = "Grass"

-- Leave and unchanged if your training in GRASS or WATER
-- You can specify a Rectangle by finding a (upper left corner and lower right corner) or (upper right corner and lower left corner) character cells on PRO Client
    -- It is for the movement of your character
            -- press "F2" and type "/loc" or "/pos"
-- Change the number on what rectangle movement you desired

RectMinX = 1
RectMinY = 1
RectMaxX = 1
RectMaxY = 1



    -- Effort Value

-- Change to what kind of EV training you want to do
-- Options: "atk","speed","defense","spattack","spdefense","hp"    --case sensitive

atk = true


-- Set/Change the number of EV you needed

EVneed = 2352



    --ITEM CONFIG

-- Set/Change the name of the mount you want to use on LAND

mount = "Arcanine Mount"

-- Set/Change to true if you want to use mount,else false

mountSwitch = true

    
-- Set/Change the name of an Item you want to equipp

item = "Macho Brace"

-- Set to "true if you want to give item to Pokemon, else "false"

equipitem = true

-- Set to "true" if you want to remove held item after reaching to EV points you wanted, else "false"

unequipitem = true






    -- Copyright © 2016 redskhie



EV's Script:     ~Don't touch this if you don't know what your doing


name = "Universal Effort Value Trainer"
author = "redskhie"
description = [[EV Training]]

dofile "config.lua"


function onStart()
    
    startime = os.time()

    shinycount = 0
    pcCount = 0
    wildcount = 0
    startMoney = getMoney()

    attackEv = getPokemonEffortValue(1, "Attack")
    defenseEv = getPokemonEffortValue(1, "Defense")
    speedEv = getPokemonEffortValue(1, "Speed")
    spattackEv = getPokemonEffortValue(1, "Spattack")
    spdefenseEv = getPokemonEffortValue(1, "Spdefense")
    hpEv = getPokemonEffortValue(1, "HP")
    log("-----------------------------------------------------------")
    log("--------- We are now Commencing the Training Routine ---------")
    log("-----------------------------------------------------------")
    log("---------------")
    log("Starting routine at "..TrainingMap.." ~~~ GOODLUCK!")
    log("Training your ~~"..getPokemonName(1).."~~")
    log("---------------")
    log("We will stop until we reach your desired Effort Values ")
    log("---------------")
    log("***"..getPokemonName(1).." EV STATS***")
    log("Attack: "..getPokemonEffortValue(1, "Attack"))
    log("Defense: "..getPokemonEffortValue(1, "Defense"))
    log("Speed: "..getPokemonEffortValue(1, "Speed"))
    log("Special Attack: "..getPokemonEffortValue(1, "Spattack"))
    log("Special Defense: "..getPokemonEffortValue(1, "Spdefense"))
    log("Health Points: "..getPokemonEffortValue(1, "HP"))
    log("---------------")

end

function onBattleMessage(wild)
   if stringContains(wild, "A Wild SHINY ") then
       shinycount = shinycount + 1
        wildcount = wildcount + 1
        log("Info | Shinies encountered: " .. shinycount)
    elseif stringContains(wild, "A Wild ") then
       wildcount = wildcount + 1
        log("Info | Pokemon encountered: " .. wildcount)
    end
end

function onDialogMessage(pc)
   if stringContains(pc, "Would you like me to heal your Pokemon?") then
       pcCount = pcCount + 1
        log("Info | Times in Pokecenter: " .. pcCount)
   end
end

function onPause()
    
    log("-----------------------------------------------------------")
    log("---------------------- Routine Paused ---------------------")
    log("-----------------------------------------------------------")
    log("***"..getPokemonName(1).." EV STATS***")
    log("--"..getPokemonHeldItem(1).."--")
    log("Attack: "..getPokemonEffortValue(1, "Attack"))
    log("Defense: "..getPokemonEffortValue(1, "Defense"))
    log("Speed: "..getPokemonEffortValue(1, "Speed"))
    log("Special Attack: "..getPokemonEffortValue(1, "Spattack"))
    log("Special Defense: "..getPokemonEffortValue(1, "Spdefense"))
    log("Health Points: "..getPokemonEffortValue(1, "HP"))
    log("---------------")
    log("Info | Shinies encountered: " .. shinycount)
    log("Info | Pokemon encountered: " .. wildcount)
    log("Info | Times in Pokecenter: " .. pcCount)
    log("---------------")
    log("Pokedollars earned: "..tostring(getMoney() - startMoney))
    log("---------------")
    endtime = os.time()
    log(string.format("Bot running time: %.2f", os.difftime(endtime,startime)/3600 ).. " hours")
    log("or")
    log(string.format("Bot running time: %.2f", os.difftime(endtime,startime)/60 ).. " minutes")
    log("---------------")
        
end

function onStop()
    log("-----------------------------------------------------------")
    log("---------------------- Routine Stopped ---------------------")
    log("-----------------------------------------------------------")
    log("***"..getPokemonName(1).." STATS***")
    log("Attack: "..getPokemonEffortValue(1, "Attack"))
    log("Defense: "..getPokemonEffortValue(1, "Defense"))
    log("Speed: "..getPokemonEffortValue(1, "Speed"))
    log("Special Attack: "..getPokemonEffortValue(1, "Spattack"))
    log("Special Defense: "..getPokemonEffortValue(1, "Spdefense"))
    log("Health Points: "..getPokemonEffortValue(1, "HP"))
    log(" ")
    
    endtime = os.time()
    log(string.format("Bot running time: %.2f", os.difftime(endtime,startime)/3600 ).. " hours")
    log("or")
    log(string.format("Bot running time: %.2f", os.difftime(endtime,startime)/60 ).. " minutes")
    log(" ")

end

function ride()
        if mountSwitch then
            if not isOutside() then
                path()
            elseif not isSurfing() then
                if not isMounted() then
                    log("Riding on my pet!!!")
                    useItem(mount)
                elseif isMounted() then
                    path()
                end
            elseif isSurfing() then
                path()
            end
        elseif mountSwitch == false then
            path()
        end
end

function rideheal()
        if mountSwitch then
            if not isOutside() then
                pokecenter()
            elseif not isSurfing() then
                if not isMounted() then
                    log("Riding on my pet!!!")
                    useItem(mount)
                elseif isMounted() then
                    pokecenter()
                end
            elseif isSurfing() then
                pokecenter()
            end
        elseif mountSwitch == false then
            pokecenter()
        end
end

function path()

    if getPokemonHeldItem(1) == item or equipitem == false then
    if getMapName() == pc then
        moveToMap(map1)
    elseif getMapName() == map1 then
        return moveToMap(map2) or moveToMap(TrainingMap)
    elseif getMapName() == map2 then
        return moveToMap(map3) or moveToMap(TrainingMap)
    elseif getMapName() == map3 then
        return moveToMap(map4) or moveToMap(TrainingMap)
       elseif getMapName() == map4 then
        return moveToMap(TrainingMap)
    elseif getMapName() == TrainingMap then
        if TrainingSpot == "Rectangle" then
            moveToRectangle(RectMinX,RectMinY,RectMaxX,RectMaxY)
        elseif TrainingSpot == "Grass" then
            moveToGrass()
        elseif TrainingSpot == "Water" then
            moveToWater()
        end
    end
    end

end

function pokecenter()

        if getMapName() == TrainingMap then    
            return moveToMap(map1) or moveToMap(map2) or moveToMap(map3) or moveToMap(map4) or moveToMap(pc)
        elseif getMapName() == map4 then    
            moveToMap(map3)
        elseif getMapName() == map3 then    
            moveToMap(map2)
        elseif getMapName() == map2 then    
            moveToMap(map1)
        elseif getMapName() == map1 then    
            moveToMap(pc)
           elseif getMapName() == pc then
            usePokecenter()
        end

end

function unequip()

    if unequipitem then
    if getPokemonHeldItem(1) == item then
           takeItemFromPokemon(1)
           log(" ")
           log("Item successfully remove on " ..getPokemonName(1).. "...")
           log(" ")
    end
    end

end

function brace()

    if equipitem then
    if hasItem(item) and getPokemonHeldItem(1) != item then
           giveItemToPokemon(item, 1)
           log(" ")
           log("Macho Brace successfully equipped on " ..getPokemonName(1).. ".")
           log(" ")
    end
    end

end

function onPathAction()
    
    
    if isPokemonUsable(1) then
        
        if atk == true  then
            if attackEv < EVneed then
    
                return brace() or ride()

            elseif attackEv >= EVneed then
                return unequip() or fatal("Attack Effort Value reaches "..attackEv.."... Stopping the bot")
            end
        elseif speed == true  then
            if speedEv < EVneed then
                return brace() or ride()
            elseif speedEv >= EVneed then
                return unequip() or fatal("Speed Effort Value reaches "..speedEv.."... Stopping the bot")
            end
        elseif defense == true  then
            if defenseEv < EVneed then
    
                return brace() or ride()

            elseif defenseEv >= EVneed then
                return unequip() or fatal("Defense Effort Value reaches "..defenseEv.."... Stopping the bot")
            end
        elseif spattack == true  then
            if spattackEv < EVneed then
    
                return brace() or ride()

            elseif spattackEv >= EVneed then
                return unequip() or fatal("Special Attack Effort Value reaches "..spattackEv.."... Stopping the bot")
            end
        elseif spdefense == true  then
            if spdefenseEv < EVneed then
    
                return brace() or ride()
                

            elseif spdefenseEv >= EVneed then
                return unequip() or fatal("Special Defense Effort Value reaches "..spdefenseEv.."... Stopping the bot")
            end
        elseif hp == true  then
            if hpEv < EVneed then
    
                return brace() or ride()

            elseif hpEv >= EVneed then
                return unequip() or fatal("HP Effort Value reaches "..hpEv.."... Stopping the bot")
            end
        end
        
    else
        rideheal()
        
    end

end

function onBattleAction()
    if isWildBattle() and ( isOpponentShiny() ) then
        return useItem("Pokeball") or useItem("Great Ball") or useItem("Ultra Ball") or sendAnyPokemon() or attack() or run()
    elseif atk == true then
        atck()
    elseif speed == true then
        spe()
    elseif defense == true then
        def()
    elseif spattack == true then
        spa()
    elseif spdefense == true then
        spd()
    elseif hp == true then
        hps()
    end
    
    
    
end


function atck()
    if getActivePokemonNumber() == 1 and isOpponentEffortValue("Attack") and (attackEv < EVneed) then
        log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"Attack").. " Attack EVs.")
        return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()
    else
        return run() or sendUsablePokemon() or sendAnyPokemon()
    end
end

function spe()
    if getActivePokemonNumber() == 1 and isOpponentEffortValue("Speed") and (speedEv < EVneed) then
        log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"Speed").. " Spe EVs.")
        return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()
    else
        return run() or sendUsablePokemon() or sendAnyPokemon()
    end
end
function def()
    if getActivePokemonNumber() == 1 and isOpponentEffortValue("Defense") and (defenseEv < EVneed) then
        log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"Defense").. " Defense EVs.")
        return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()
    else
        return run() or sendUsablePokemon() or sendAnyPokemon()
    end
end
function spa()
    if getActivePokemonNumber() == 1 and isOpponentEffortValue("Spattack") and (spattackEv < EVneed) then
        log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"Spattack").. " Spattack EVs.")
        return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()  
    else
        return run() or sendUsablePokemon() or sendAnyPokemon()
    end
end
function hps()
    if getActivePokemonNumber() == 1 and isOpponentEffortValue("HP") and (hpEv < EVneed) then
        log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"HP").. " HP EVs.")
        return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()
    else
        return run() or sendUsablePokemon() or sendAnyPokemon()
    end
end
function spd()
    if getActivePokemonNumber() == 1 and isOpponentEffortValue("Spdefense") and (spdefenseEv < EVneed) then
        log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"Spdefense").. " Spdef EVs.")
        return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()  
    else
        return run() or sendUsablePokemon() or sendAnyPokemon()
    end
end



TRIED and TESTED before RELEASING
PLEASE REPORT THE ERROR YOU FOUND WITH DETAILED INFO, THANKS AND HAPPY BOTTING!


YOU CAN ALSO SUGGEST AN AWESOME UPDATES



YOU CAN SEE THE LATEST UPDATE HERE
CLICK ME

God Karp Trainer loading... *splash*splash Huh

 
Reply
#2
nice one, do you want me to replace your old script with the new one on the "database" ?
No support for scripts from other authors or edited scripts ( except config.lua ). If you change something on the "core" and it isnt working anymore then you can fix it by your own.
Feel free to contact me for informations and tips !

 
Reply
#3
Looks like a cool script, I always like to see a configuration file. Smile

Just a few random things:

- When you copy/paste something in a script, you are probably doing something wrong.
All the path actions and battle actions are nearly identical, you can probably improve them by using some functions and parameters.

- The bot will stop if fainted by a shiny opponent.
return useItem("Pokeball") or useItem("Great Ball") or useItem("Ultra Ball") or attack() or run()

- Why do you switch with the 5th or 6th pokemon? What if I only have two pokemon in my team?
return attack() or sendPokemon(5) or sendPokemon(6) or run()
 
Reply
#4
imMigno nice one, do you want me to replace your old script with the new one on the "database" ?

What script?
God Karp Trainer loading... *splash*splash Huh

 
Reply
#5
Silv3r Looks like a cool script, I always like to see a configuration file. Smile

Just a few random things:

- When you copy/paste something in a script, you are probably doing something wrong.
All the path actions and battle actions are nearly identical, you can probably improve them by using some functions and parameters.

- The bot will stop if fainted by a shiny opponent.
return useItem("Pokeball") or useItem("Great Ball") or useItem("Ultra Ball") or attack() or run()

- Why do you switch with the 5th or 6th pokemon? What if I only have two pokemon in my team?
return attack() or sendPokemon(5) or sendPokemon(6) or run()


Oops Sorry I forgot to edit it just copy and paste it on my old script. Thanks!
God Karp Trainer loading... *splash*splash Huh

 
Reply
#6
redskhie
Silv3r Looks like a cool script, I always like to see a configuration file. Smile

Just a few random things:

- When you copy/paste something in a script, you are probably doing something wrong.
All the path actions and battle actions are nearly identical, you can probably improve them by using some functions and parameters.

- The bot will stop if fainted by a shiny opponent.
return useItem("Pokeball") or useItem("Great Ball") or useItem("Ultra Ball") or attack() or run()

- Why do you switch with the 5th or 6th pokemon? What if I only have two pokemon in my team?
return attack() or sendPokemon(5) or sendPokemon(6) or run()


Oops Sorry I forgot to edit it just copy and paste it on my old script. Thanks!

I'll try to improve them tomorrow ,I'm gonna sleep. Thanks again sir Smile
God Karp Trainer loading... *splash*splash Huh

 
Reply
#7
redskhie
imMigno nice one, do you want me to replace your old script with the new one on the "database" ?

What script?

This one with your previous EV Trainer:
https://proshine-bot.com/viewtopic.php?id=1232
No support for scripts from other authors or edited scripts ( except config.lua ). If you change something on the "core" and it isnt working anymore then you can fix it by your own.
Feel free to contact me for informations and tips !

 
Reply
#8
UPDATED:See changelogs
God Karp Trainer loading... *splash*splash Huh

 
Reply
#9
imMigno
redskhie
imMigno nice one, do you want me to replace your old script with the new one on the "database" ?

What script?

This one with your previous EV Trainer:
https://proshine-bot.com/viewtopic.php?id=1232

Its up to you. But I think much better if you just add this new one to the database. Because the old one is ready to use, just copy and paste it and youre done. Thanks in advance.
God Karp Trainer loading... *splash*splash Huh

 
Reply
#10
Maybe this gonna help for train dual poke ev or train dual ev poke (if only has 1 macho brace it looks like this)
if getPokemonEffortValue(1, "Attack") == 252 and getPokemonEffortValue(1, "Speed") == 252 then
    if getPokemonEffortValue(2, "Attack") < 252 and getPokemonEffortValue(2, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",2)
        elseif getPokemonHeldItem(2) == "Macho Brace" then
            swapPokemon(1, 2)
        end
    elseif getPokemonEffortValue(3, "Attack") < 252 and getPokemonEffortValue(3, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",3)
        elseif getPokemonHeldItem(3) == "Macho Brace" then
            swapPokemon(1, 3)
        end
    elseif getPokemonEffortValue(4, "Attack") < 252 and getPokemonEffortValue(4, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",4)
        elseif getPokemonHeldItem(4) == "Macho Brace" then
            swapPokemon(1, 4)
        end
    elseif getPokemonEffortValue(5, "Attack") < 252 and getPokemonEffortValue(5, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",5)
        elseif getPokemonHeldItem(5) == "Macho Brace" then
            swapPokemon(1, 5)
        end
    end
end
 
Reply
#11
Kazeee Maybe this gonna help for train dual poke ev or train dual ev poke (if only has 1 macho brace it looks like this)
if getPokemonEffortValue(1, "Attack") == 252 and getPokemonEffortValue(1, "Speed") == 252 then
    if getPokemonEffortValue(2, "Attack") < 252 and getPokemonEffortValue(2, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",2)
        elseif getPokemonHeldItem(2) == "Macho Brace" then
            swapPokemon(1, 2)
        end
    elseif getPokemonEffortValue(3, "Attack") < 252 and getPokemonEffortValue(3, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",3)
        elseif getPokemonHeldItem(3) == "Macho Brace" then
            swapPokemon(1, 3)
        end
    elseif getPokemonEffortValue(4, "Attack") < 252 and getPokemonEffortValue(4, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",4)
        elseif getPokemonHeldItem(4) == "Macho Brace" then
            swapPokemon(1, 4)
        end
    elseif getPokemonEffortValue(5, "Attack") < 252 and getPokemonEffortValue(5, "Speed") < 252 then
        if not hasItem("Macho Brace") then
            takeItemFromPokemon(1)
        elseif hasItem("Macho Brace") then
            giveItemToPokemon("Macho Brace",5)
        elseif getPokemonHeldItem(5) == "Macho Brace" then
            swapPokemon(1, 5)
        end
    end
end

Thank you I'm gonna look at these.
God Karp Trainer loading... *splash*splash Huh

 
Reply
#12
UPDATED to Version 3
God Karp Trainer loading... *splash*splash Huh

 
Reply
#13
can i set 2 ev's here like this?

-- Effort Value

-- Change to what kind of EV training you want to do
-- Options: "attack","speed","defense","spattack","spdefense","hp"    --case sensitive


defense = true
hp = true

-- Set/Change the number of EV you needed

EVneed = 252
 
Reply
#14
PROlux can i set 2 ev's here like this?

-- Effort Value

-- Change to what kind of EV training you want to do
-- Options: "attack","speed","defense","spattack","spdefense","hp"    --case sensitive


defense = true
hp = true

-- Set/Change the number of EV you needed

EVneed = 252

Yes You can set but I don't know If will work, haven't tested it yet.

See my UPDATE PLAN. I will add it in the next update. Have fun!
God Karp Trainer loading... *splash*splash Huh

 
Reply
#15
hi~~
first..niubie here..nice to meet u

i ve got some problem with this script

[EDIT] :
Problem Solve & now working nicely
thx
 
Reply
#16
SixHells hi~~
first..niubie here..nice to meet u

i ve got some problem with this script
the script it's working..but only half of it

it's working if my ID allready on the map we want to train
and it's never used to pokecenter or walk to the city

i'm sure 100% allready write the city name & PC name correctly

please help me solve it....thx

May I see your config
God Karp Trainer loading... *splash*splash Huh

 
Reply
#17
redskhie
SixHells hi~~
first..niubie here..nice to meet u

i ve got some problem with this script
the script it's working..but only half of it

it's working if my ID allready on the map we want to train
and it's never used to pokecenter or walk to the city

i'm sure 100% allready write the city name & PC name correctly

please help me solve it....thx

May I see your config

ahh...
it's done
now it's working nicely
thx for reply & the script of course
Big Grin
 
Reply
#18
No problem. And btw its UPDATED See changelogs. Have fun!
God Karp Trainer loading... *splash*splash Huh

 
Reply
#19
function onBattleMessage(wild)
    if stringContains(wild, "A Wild SHINY ") then
        shinycount = shinycount + 1
        wildcount = wildcount + 1
        log("Info | Shinies encountered: " .. shinycount)
    elseif stringContains(wild, "A Wild ") then
        wildcount = wildcount + 1
        log("Info | Shinies encountered: " .. shinycount)
    end
end

wild counter is showing shiny counter Tongue

btw, great script, good job!
 
Reply
#20
I'm getting this error:

[9:23:15 PM] Error during the script execution: chunk_1:(305,8-32): attempt to call a boolean value

when I try to train for attack EVs. Works fine for speed EV training though. (the only difference is attack = true, or speed = true in config.lua)
I think it means line 305?

302 function atk()
303     if getActivePokemonNumber() == 1 and isOpponentEffortValue("Attack") and (attackEv < EVneed) then
304         log("Your "..getPokemonName(1).." have "..getPokemonEffortValue(1,"Attack").. " Attack EVs.")
305         return attack() or sendPokemon(2) or sendPokemon(3) or sendAnyPokemon() or run()
306     else
307         return run() or sendUsablePokemon() or sendAnyPokemon()
308     end
309 end
 
Reply
#21
Let me see your config?

[9:56:30 AM] Attack: 2
[9:55:36 AM] Alakazam Attacks Pidgeotto with Psychic.
[9:55:36 AM] Pidgeotto has fainted!
[9:55:36 AM] You found 7 Pokedollar(s).
[9:55:36 AM] You have won the battle.
[9:55:41 AM] Info | Pokemon encountered: 7
[9:55:41 AM] A Wild Pidgey Attacks!
[9:55:47 AM] Your Alakazam have 252 Spe EVs.
[9:55:48 AM] Alakazam Attacks Pidgey with Psychic.
[9:55:48 AM] Pidgey has fainted!
[9:55:48 AM] You found 20 Pokedollar(s).
[9:55:48 AM] You have won the battle.
[9:55:53 AM] Info | Pokemon encountered: 8
[9:56:30 AM] Defense: 0
[9:56:30 AM] Speed: 252
[9:56:30 AM] Special Attack: 252
[9:56:30 AM] Special Defense: 0
[9:56:30 AM] Health Points: 4
[9:56:30 AM] ---------------
[9:56:30 AM]  
[9:56:30 AM] Item successfully remove on Alakazam...
[9:56:30 AM]  
[9:56:30 AM] Speed Effort Value reaches 252... Stopping the bot
[9:56:31 AM] Bot stopped

NOTE: You can only set 1 EV training on config
speed = true

NOT THIS
attack = true
speed = true
..and so on..


I'm currently working on that so you can only use 1 EV training for now... CIAO!!!
God Karp Trainer loading... *splash*splash Huh

 
Reply
#22
Log:

[10:09:09 PM] Bot started
[10:09:09 PM] -----------------------------------------------------------
[10:09:09 PM] --------- We are now Commencing the Training Routine ---------
[10:09:09 PM] -----------------------------------------------------------
[10:09:09 PM] ---------------
[10:09:09 PM] Starting routine at Route 105  ~~~ GOODLUCK!
[10:09:09 PM] Training your ~~Mudkip~~
[10:09:09 PM] ---------------
[10:09:09 PM] We will stop until we reach your desired Effort Values 
[10:09:09 PM] ---------------
[10:09:09 PM] ***Mudkip EV STATS***
[10:09:09 PM] Attack: 139
[10:09:09 PM] Defense: 0
[10:09:09 PM] Speed: 252
[10:09:09 PM] Special Attack: 4
[10:09:09 PM] Special Defense: 11
[10:09:09 PM] Health Points: 22
[10:09:09 PM] ---------------
[10:09:09 PM] Your Mudkip have 139 Attack EVs.
[10:09:09 PM] Error during the script execution: chunk_1:(305,8-88): attempt to call a boolean value
[10:09:09 PM] Bot stopped
[10:09:09 PM] -----------------------------------------------------------
[10:09:09 PM] ---------------------- Routine Stopped ---------------------
[10:09:09 PM] -----------------------------------------------------------
[10:09:09 PM] ***Mudkip STATS***
[10:09:09 PM] Attack: 139
[10:09:09 PM] Defense: 0
[10:09:09 PM] Speed: 252
[10:09:09 PM] Special Attack: 4
[10:09:09 PM] Special Defense: 11
[10:09:09 PM] Health Points: 22
[10:09:09 PM]  
[10:09:09 PM] Bot running time: 0.00 hours
[10:09:09 PM] or
[10:09:09 PM] Bot running time: 0.00 minutes
[10:09:09 PM]  

config.lua:

-- Copyright © 2016 redskhie                



    -- Map Configurations

-- Insert/Change the Mapnames of your training route
-- Mapnames is CASE SENSITIVE
-- Leave others blank if unused

pc = "Pokecenter Petalburg"
map1 = "Petalburg City"
map2 = ""
map3 = ""
map4 = ""
TrainingMap = "Route 105 "



    -- Training Spots
-- Inserting/Changing Options: "Rectangle" , "Grass" , "Water"

TrainingSpot = "Rectangle"

-- Leave and unchanged if your training in GRASS or WATER
-- You can specify a Rectangle by finding a (upper left corner and lower right corner) or (upper right corner and lower left corner) character cells on PRO Client 
    -- It is for the movement of your character
            -- press "F2" and type "/loc" or "/pos"
-- Change the number on what rectangle movement you desired

RectMinX = 27
RectMinY = 2
RectMaxX = 34
RectMaxY = 14



    -- Effort Value

-- Change to what kind of EV training you want to do
-- Options: "attack","speed","defense","spattack","spdefense","hp"    --case sensitive


attack = true

-- Set/Change the number of EV you needed

EVneed = 323



    --ITEM CONFIG

-- Set/Change the name of the mount you want to use on LAND

mount = "Bicycle"

-- Set/Change to true if you want to use mount,else false

mountSwitch = true

    
-- Set/Change the name of an Item you want to equipp

item = "Macho Brace"

-- Set to "true if you want to give item to Pokemon, else "false"

equipitem = true

-- Set to "true" if you want to remove held item after reaching to EV points you wanted, else "false"

unequipitem = true






    -- Copyright © 2016 redskhie

Here is the log when it works properly when speed = true (just speed only, no attack)

[10:11:26 PM] Bot started
[10:11:26 PM] -----------------------------------------------------------
[10:11:26 PM] --------- We are now Commencing the Training Routine ---------
[10:11:26 PM] -----------------------------------------------------------
[10:11:26 PM] ---------------
[10:11:26 PM] Starting routine at Route 105  ~~~ GOODLUCK!
[10:11:26 PM] Training your ~~Mudkip~~
[10:11:26 PM] ---------------
[10:11:26 PM] We will stop until we reach your desired Effort Values 
[10:11:26 PM] ---------------
[10:11:26 PM] ***Mudkip EV STATS***
[10:11:26 PM] Attack: 139
[10:11:26 PM] Defense: 0
[10:11:26 PM] Speed: 252
[10:11:26 PM] Special Attack: 4
[10:11:26 PM] Special Defense: 11
[10:11:26 PM] Health Points: 22
[10:11:26 PM] ---------------
[10:11:26 PM] You have run away from the wild Pokemon.
[10:11:26 PM] System: You are no longer AFK!
[10:11:31 PM] Info | Pokemon encountered: 0
[10:11:31 PM] A Wild Krabby Attacks!
[10:11:37 PM] You have run away from the wild Pokemon.
[10:11:49 PM] Info | Pokemon encountered: 0
[10:11:49 PM] A Wild Wingull Attacks!
[10:11:53 PM] Your Mudkip have 252 Spe EVs.
[10:11:54 PM] Mudkip Attacks Wingull with Rock Throw.
[10:11:54 PM] It's Super Effective!
[10:11:54 PM] Wingull has fainted!
[10:11:54 PM] Mudkip gained 432 Exp.
[10:11:54 PM] You found 82 Pokedollar(s). 
[10:11:54 PM] You have won the battle. 
[10:11:57 PM] Bot stopped
[10:11:57 PM] -----------------------------------------------------------
[10:11:57 PM] ---------------------- Routine Stopped ---------------------
[10:11:57 PM] -----------------------------------------------------------
[10:11:57 PM] ***Mudkip STATS***
[10:11:57 PM] Attack: 139
[10:11:57 PM] Defense: 0
[10:11:57 PM] Speed: 252
[10:11:57 PM] Special Attack: 4
[10:11:57 PM] Special Defense: 11
[10:11:57 PM] Health Points: 22
[10:11:57 PM]  
[10:11:57 PM] Bot running time: 0.01 hours
[10:11:57 PM] or
[10:11:57 PM] Bot running time: 0.52 minutes
[10:11:57 PM]  
 
Reply
#23
Its updated now. Its a bug because I declare a variable with the same name as battle move.

Re-copy the scripts. Read carefully the description on config.lua

[10:29:25 AM] Your Alakazam have 2 Attack EVs.
[10:29:25 AM] Alakazam Attacks Bellsprout with Psyshock.
[10:29:25 AM] It's Super Effective!
[10:29:25 AM] Bellsprout has fainted!
[10:29:25 AM] You found 28 Pokedollar(s).
[10:29:25 AM] You have won the battle.
God Karp Trainer loading... *splash*splash Huh

 
Reply
#24
Works fine now, thanks!
 
Reply
#25


YOU CAN SEE THE LATEST UPDATE HERE >>>

God Karp Trainer loading... *splash*splash Huh

 
Reply
  


Forum Jump:


Browsing: 1 Guest(s)