|
 Having some troubles { Educational Material Inside } : EverQuest 2 Premium Discussions - Page 4
|
|
Posted: February 4th, 2005, 10:22 pm
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
why not do it this way?
$betty = "Hello there Loraik!"
Func SayHello($betty) MsgBox(0, "Hello", $betty) EndFunc
SayHello($betty)
Loraik
|
|
|
|
|
Posted: February 4th, 2005, 10:56 pm
|
|
|
|
tault_pickled
tault_pickled's Reps:
|
You can do it that way! Let me explain something (!empty($user->lang['CODE'])) ? $user->lang['CODE'] : ucwords(strtolower(str_replace('_', ' ', 'CODE'))): ; Variables declared outside a function exist forever ; Variables declared inside a function only last the duration of that function call
$value = 1000
Func ChangeValue($value) $value = 4000 MsgBox(0, "Value", "Value INSIDE the Function is now = " & $value) EndFunc
;Main body of script
;Deliberately change Value (was passed as 1000) ChangeValue($value)
;Back outside of function in main script MsgBox(0, "Value", "Value OUTSIDE of Function is now = " & $value)
;The moral of this is that Value was never changed in the main body ;It was only changed in the function during the time it 'existed' in the function
What we have learned here is a thing called variable SCOPE Variables declared outside of a function EXIST throughout the script. Variables declared inside a function only BELONG to that function call. If you pass a $var to a function, $var only exists in the function, once the function ends the $var still equals the same as what it entered. Global Scope = $variables delcared outside a function, exist througout exectuion. Local Scope = $variables available to that function, during the function call.
|
|
|
|
|
Posted: February 5th, 2005, 12:23 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Ok so if you call out a variable in a function once the function is ended you can't refer to that variable frome another function or elsewhere in the script correct? If you did need to refer to it you would set it up as global variable.
I am assuming one of the bonus's to doing this is to not have a ton of un-needed variables in memory bogging stuff down.
Loraik
|
|
|
|
|
Posted: February 5th, 2005, 1:00 am
|
|
Posted: February 5th, 2005, 1:12 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Ok I am using the macro located here http://www.tault.com/phpBB2/viewtopic.php?t=5866 currently as it is the only working crafting macro I can find up here (ok only crafting macro I can make work) so what do I have to do to mod the window size. It just isn't jumping out at me but I can tell you working in such a small space where my chat windows get all covered up SUCKS!!!! Seriously I hate it is so small I need it larger plus then I can try to figure out how to adjust all the data to work for me then. Loraik
|
|
|
|
|
Posted: February 5th, 2005, 1:23 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Ok found it: (!empty($user->lang['QUOTE'])) ? $user->lang['QUOTE'] : ucwords(strtolower(str_replace('_', ' ', 'QUOTE'))): Func SetWindow() $Returnvalue="False" WinActivate($strEQIItitle) $arrWinPos=WinGetPos ($strEQIItitle) If (($arrWinPos[2]=1032) AND ($arrWinPos[3]=746)) Then $Returnvalue="True" Else $strMessage="Window doesnt fit, it is currently " & $arrWinPos[2] & "*" & $arrWinPos[3] & ", Sets the window to 1032*746." & @CRLF _ & "You must now relogg to get all windows at right position!" & @CRLF & "Make sure the craftingwindow and manawindow(Playerwindow) is at the default place when you have logged in again." _ & @CRLF & "The script will now quit!" MsgBox(0,"Window settings",$strMessage ) WinActivate($strEQIItitle) WinMove ( $strEQIItitle, "", 0, 0 , 1032 , 746 ) Exit(0) EndIf Return $Returnvalue EndFunc So by changing this string "If (($arrWinPos[2]=1032) AND ($arrWinPos[3]=746)) Then" to better match the window area will hook me up right? Then I just need to go thru and reconfigure the pixel and mouse info.? Loraik
|
|
|
|
|
Posted: February 5th, 2005, 1:28 am
|
|
|
|
tault_pickled
tault_pickled's Reps:
|
I'll email you the new recipe thing i've done soon - that code you have there is from the old old version of the orginal script. Plus the code their is bugged, it dosent check for 0,0 position which is fatal. Just finishing up some loose ends on it. WinMove(0,0,x,y) is the function to Resize a window.... But to be honest I wouldnt dare change it, as its a HUGE task going through all the code and then re-writing all the x,y' and colors, then you'd have to check them all, lol your looking at about 10 hours work ++  End of the day... it's going to be running AFK, so as long as you can see it initially to get it going? Re-working the RecipeCrafter will take even longer 
|
|
|
|
|
Posted: February 5th, 2005, 1:45 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Well it is important to me just from the fact I don't quite trust letting it run while I am not even in the house. I downloaded the combat stats probram which lets me link any line of text to a .wav file so I have it set so if I get a /tell I hear a loud chime over my house intercom system then I can run down and answer the tell but if I can't see the chat easy....
I don't want to loose my accounts by doing something stupid like having a GM suspect me of botting and me not be there to answer.
ATM I am trying to harvest nodes on one machine while fighting in RE grouped on the other machine and it isn't easy cause if you slack on the nodes someone else nabs them. Not to mention I don't wish to kill group members cause I am not paying 100% attention to the group (so far no problems have occured).
The harvesting bots end of it comes in handy while I am eating or playing with son so one way or another I have my toons working while I am within ear shot of the puters.
Loraik
|
|
|
|
|
Posted: February 5th, 2005, 1:59 am
|
|
|
|
tault_pickled
tault_pickled's Reps:
|
The auto harvesting I developed which works well Only works for a class that can pull with a bow (due to a facing exploit on nodes)  Will not work with nuker/priest classes - yet.
|
|
|
|
|
Posted: February 5th, 2005, 2:08 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Ahhhh Crap... Figures, I use my cleric to do the harvesting since his lvl keeps him safe.... Why the heck can't a cleric use a bow anyway? I mean they can wear heavy armor, one would think pulling the string of a bow would be easier then lugging 8000 lbs of armor around....
mlm SOE
Loraik
|
|
|
|
|
Posted: February 5th, 2005, 2:30 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Question, and this is just cause I wana know. You said your using some kind of sploit for current harvesting method but couldn't you do something like:
Set pathing 0,0,0 to 100,100,100 to move between these points (yes I am sure this is no easy task)
Have macro spam the "~" key (isn't this the key that togles between nearby targets?)
$log = log names here $bush = bush names here $rock = rock names here $den = den names here
and have some kinda thing like (if "current target" = "$log, $bush, $rock, #den" then press so and so key (set hose values also)
have it do this until current target = 0 or something then return to 0,0,0 and loop..
I know this is a chopy concept but I think you will understand what I am saying. Maybe use (sleep) to set run time? Duno just thinking out loud...
Loraik
|
|
|
|
|
Posted: February 5th, 2005, 2:40 am
|
|
|
|
tault_pickled
tault_pickled's Reps:
|
Too many factors with no pathing in place and with No /face command - it's a complete waste of time and little gain for huge effort. My current one walks me all over the place, but I need to disable fishing sometimes or I wake up in the sea 
|
|
|
|
|
Posted: February 5th, 2005, 2:59 am
|
|
|
|
tault_loraik
tault_loraik's Reps:
|
Doesn't attacking an object face you? I know I know I am beating a dead horse, the concept seems simple enough but having all the commands to get done what you needing to is a whole different story. But wouldn't you know I have a Mage as my main and a Priest twink.... My scout is no where near the lvl to get into an area I need to harvest.
What about throwing skill? Does it or would it work like a bow for the sploit? I think priest and mages can throw.. I don't know if throwing items work like in EQlive though where you could have a stack in your inventory that your throwing skill will pull out of instead of having to replace the stack in the throwing slot all the time.
Oh question, if you say have a lvl 50 crafter but toon is lvl 14 are the mobs in areas like EL and Zek still KOS to you or does your crafting lvl protect you? If this is the case I will craft my scout to 30ish and do that...
Loraik
|
|
|
|
|
Posted: February 5th, 2005, 3:36 am
|
|
Posted: February 5th, 2005, 3:49 am
|
|
|
|
tault_pickled
tault_pickled's Reps:
|
Heres one for you, test it yourself before posting what actually... dosent work 
|
|
|
|
|
Who is online |
|
Users browsing this forum: No registered users and 147 guests |
|
|
|