World of Kungfu Bot (Updated)

You may request or share scripts for MicroMacro in this forum.
Message
Author
supercraz
Posts: 10
Joined: Tue May 20, 2008 5:13 am

Re: World of Kungfu Bot (Updated)

#41 Post by supercraz »

Sorry about that.

what happens if alt F4 dont work on the game? is there an alternative?
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#42 Post by Administrator »

You could reproduce opening the menu (typically pressing ESC a few times), and clicking the "exit game" button. You could also induce the OS's kill command to kill the process.
supercraz
Posts: 10
Joined: Tue May 20, 2008 5:13 am

Re: World of Kungfu Bot (Updated)

#43 Post by supercraz »

alt f4 doesn't work. Os kill as in shut down computer? hmm. :) what about task manager to kill the game
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#44 Post by Administrator »

Actually, I was thinking more along the lines of this:

Code: Select all

os.execute("taskkill /IM whatever.exe");
supercraz
Posts: 10
Joined: Tue May 20, 2008 5:13 am

Re: World of Kungfu Bot (Updated)

#45 Post by supercraz »

sweet where do i put that command?
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#46 Post by Administrator »

Put it in place of the ALT F4 press from the previous code.
juzanoob
Posts: 6
Joined: Tue Jul 15, 2008 2:06 am

Re: World of Kungfu Bot (Updated)

#47 Post by juzanoob »

when i was botting i found tat the char will get stuck(rocks,trees..etc) sometime and do nth. is there anyway to fix this?
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#48 Post by Administrator »

Well, the easiest thing to do would be to bot in an area that's wide open and devoid of anything you can get stuck on. If this is not an option, you can try making a timed function to switch targets after 1 minute of not killing the targeted monster.

Add this anywhere outside of any function

Code: Select all

function switch_target_timer()
  target_monster();
  unregisterTimer("switch_target");
end
Then modify your fight function by adding the noted lines

Code: Select all

function fight_warrior()
  registerTimer("attack_timer", 3000, attack_timer);
  registerTimer("switch_target", minutesToTimer(1), switch_target_timer); -- ADD THIS

  while( have_target() ) do
    if( HP < HP_potion ) then
      hp_potion(); end
    if( MP < MP_potion ) then
      mp_potion(); end
    keyboardPress(key_skill1);
    yrest(120); 
    keyboardPress(key_skill2);
    yrest(120);  
    keyboardPress(key_skill3);
    yrest(120);
    coroutine.yield();	
  end

  unregisterTimer("attack_timer");
  unregisterTimer("switch_target"); -- ADD THIS

  yrest(1000);
end
That should help, at least. You can also try having the character jump (if WoKF supports this), or move a few steps.
juzanoob
Posts: 6
Joined: Tue Jul 15, 2008 2:06 am

Re: World of Kungfu Bot (Updated)

#49 Post by juzanoob »

very nice of u to reply so fast. thx alot , tat shd help :D
juzanoob
Posts: 6
Joined: Tue Jul 15, 2008 2:06 am

Re: World of Kungfu Bot (Updated)

#50 Post by juzanoob »

hmm any idea y it doesnt work? :?

-------------------------------------------------
-- FUNCTION MAIN
-------------------------------------------------
function main()
win = findWindow("Kungfu Client");
hdc = openDC(win);
proc = openProcess( findProcessByExe("GongfuClient.exe") );
attach(win);

registerTimer("update_vars", 100, update_vars);
registerTimer("buff1_timer", buff1_duration, buff1_timer);
registerTimer("buff2_timer", buff2_duration, buff2_timer);
registerTimer("buff3_timer", buff3_duration, buff3_timer);


function switch_target_timer()
target_monster();
unregisterTimer("switch_target");
end

i tried puting it above
-- update client variables by reading from it's memory function update_vars()
but it doesnt work too
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#51 Post by Administrator »

You need to define "doesn't work." Does the script run? Does the script exit in error? Does it appear to run fine, just does not switch targets after that 1 minute?
juzanoob
Posts: 6
Joined: Tue Jul 15, 2008 2:06 am

Re: World of Kungfu Bot (Updated)

#52 Post by juzanoob »

yea it does run normally but it doesnt change target after 1min
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#53 Post by Administrator »

target_monster() seems to just be pressing the TAB button. If you have a target, and press TAB, does it switch to a new target, or keep the same target?
juzanoob
Posts: 6
Joined: Tue Jul 15, 2008 2:06 am

Re: World of Kungfu Bot (Updated)

#54 Post by juzanoob »

yup it does change target when i press tab
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#55 Post by Administrator »

Edit switch_target_timer(). Add

Code: Select all

printf("switch_target_timer");
to it, and make sure the function is actually being called. If you see the line "switch_target_timer" printed to MicroMacro's screen, then it is obviously being called.
juzanoob
Posts: 6
Joined: Tue Jul 15, 2008 2:06 am

Re: World of Kungfu Bot (Updated)

#56 Post by juzanoob »

in which line to change u mean?
this registerTimer("switch_target", minutesToTimer(1), switch_target_timer);
or
function switch_target_timer()
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#57 Post by Administrator »

I said to add that line into the function. You should not be changing any lines, just adding one.
felix_fx2
Posts: 11
Joined: Fri Feb 01, 2008 9:01 pm

Re: World of Kungfu Bot (Updated)

#58 Post by felix_fx2 »

elverion, do you have hackbar's msn ? need his help again for the new offsets.

or someone has knowledge on how to get that.

PM me, i'll be checking my pm tonight when i reach work
User avatar
Administrator
Site Admin
Posts: 5340
Joined: Sat Jan 05, 2008 4:21 pm

Re: World of Kungfu Bot (Updated)

#59 Post by Administrator »

I do not have his MSN address, however, he has marked his e-mail address for his profile. You could just click that little mail icon under his name on his first post in this topic. At least, I think you can see that, right?
pheiv
Posts: 3
Joined: Mon Jul 14, 2008 9:40 pm

Re: World of Kungfu Bot (Updated)

#60 Post by pheiv »

How can this game be played when it lags like hell. :|
Post Reply