Jump to content

lavezzi

Members
  • Posts

    13
  • Joined

  • Last visited

About lavezzi

  • Birthday 03/03/1979

lavezzi's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Hi, Ive got this function in a dll: Public Function evDiff(ByVal chipsPtr As IntPtr, ByVal sb As Integer, ByVal bb As Integer, ByVal ante As Integer, ByVal handIndex As Integer, ByVal noSB As Boolean, ByVal isPush As Boolean, ByVal myPos As Integer, ByVal allN As Integer) As Double I've wrote in my au3 code this line: $x=dllcall("GameAnalysis.dll","int","evDiff","ptr",$myarray[3],"int",50,"int",100,"int",0,"int",52, "int",false,"int",1,"int",2,"int",0) but the result seems not correct, any fix pls?
  2. Hello, knowing the title of a window is there a command to kill the correspondant process? I've got an app tha somethime stops working and I need to be killed with out any confirmation, I wanna kill it if I was killing the process. ty
  3. need to test it (im at work), but yes, I will donate!
  4. Martin no one accepted and delivered the work. I'm doing it by myself. Actually the following code does not work (im working on it right now), but I should be near to the solution. $string="4,0,0,0" ;~ $a=issplittable("3,1,1") ;~ split($string) distrib(5,3) Exit func distrib($coins,$boxes) ;~ GENERATE ARRAY local $p[$boxes+1] local $x=$boxes local $msg local $mysequence $p[1]=$coins-$boxes+1 while $x>1 $p[$x]=1 $x=$x-1 wend $y=1 while $y<=$boxes $mysequence=$mysequence & $p[$y] & "," $y=$y+1 wend $mysequence=StringTrimRight($mysequence,1) while $p[1]>0 $a= issplittable($mysequence) MsgBox("","is splittable:",$a & "(" & $mysequence & ")") $activeElement=1 while $activeElement<$boxes while issplittable($mysequence)=1 $mysequence=split($mysequence) MsgBox("","After Split",$mysequence) wend $activeElement=$activeElement+1 wend $p[1]=$p[1]-1 $p[2]=$p[2]+1 wend MsgBox("","END","THE END") EndFunc func split($string) $elements=StringSplit($string,",",1) $arrayCount=Ubound($elements) $elements[1]=$elements[1]-1 $elements[2]=$elements[2]+1 $x=1 $string="" while $x<$arrayCount $string=$string & $elements[$x] & "," $x=$x+1 wend $string=StringTrimRight($string,1) return $string EndFunc func issplittable($string) $elements=StringSplit($string,",",1) $arrayCount=Ubound($elements) ;~ MsgBox("","count",$arrayCount) if $arrayCount-1>2 then if ($elements[1]>$elements[2] AND $elements[1]+1>$elements[2]) Then return 1 EndIf else if ($elements[1]+1>$elements[2]) then return 1 Else return 0 EndIf endif EndFunc PS:I've given an user 10$, if he will return them to me I will donate them to Autoit
  5. easy solution for distribution problem: http://en.wikipedia.org/wiki/Category:Cont...s_distributions
  6. That's the smarter reply I've received. Both the assumptions are extremely right, but: the first can be solved easly because I can pass to the function the total number of coins less the number of boxes so I will get no boxes with zero value. the second is also correct. I've already found a permutation functions but it works only with a string containing a single digit char where i need bigger number (3 dgt). To your question I have to reply no, this is not my homework. Well I've found two ppl that wanted to code this, 1 never replied via PM and the oher had some problem. So yes, I needed at least to try this twice. That permutations functions seems not to permute something like 12,222,33, I will investigate, but it does not seems to give me unique distribution. I will not ask with any other thread. I will ask elsewhere and try to study this: http://en.wikipedia.org/wiki/Permutation http://en.wikipedia.org/wiki/Recursion_(computer_science) http://en.wikipedia.org/wiki/Divide_and_conquer_algorithm
  7. Hello. I need some1 to code this function for me. Please write down your bid and release time. What the function should do (example): Given X boxes and Y coins it should tell me each of the possibile combination. For 3 Boxes and 4 coins the result is only 1 and should be: 211 For 3 Boxes and 5 coins the result should be: 311 221 Obviously the function should be dynamic so the number of coins or boxes may be any number. The function need to accept as params X and Y as explained above. X and Y are numbers. I dont need the number of combination, i need each result. For each possible distribution I need its permutation. so 211 will also be: 121 112 This function is not so easy if we take in account as boxes 2000 and coins 100.000, dont be fooled! Other than paying the coder Ill do a small donation to autoit!!
  8. You are perfecly right and I'll do a small donation to Autoit too, but as told before I've no time for it. btw DCCD 30$ wins due to timeout of the other. please send a mail to galaga987 AT hotmail DOT COM
  9. Well, can u tell me the total price?
  10. Hello, I need some one to code a function for me. I've not such time to do it bymyself (prolly im unable to do it). I don't know if I can post this here, so I do apologize if I was wrong. Please PM or write down your email with your bid and email. An example to explain what I need: I've X coins and Y boxes. For every possible distribution I need each possible permuations (each box contain at least 1 coin). So if I've 6 coins and 3 boxes the function should return: 411 (distribution) 141 (1st permutation) 114 (2st permutation) 321 (distribution) 312 (1st permutation) 231 (2nd permutation) 213 (3rd permutation) 132 (4th permutation) 123 (5th permutation) ....... obviously the function should work with every kind of integer like X=5000 Y=12 Payment: I want pay something around 50$ I'll pay 10$ when the function do distribution and the rest when I do verify that it do also permutations correctly. I can pay only via paypal or neteller Note: I know this code should be easy to be made or that there are already those kind of functions out there, but i'm so busy I cannot do that bymyself. Thank you !
  11. How do I set fucus on a specified tab page?
  12. WinMove("Senza nome - Blocco note", "", 0, 0) $ocr = _rectOCR("Senza nome - Blocco note",0,0,200,200) MsgBox(0,"OCR", $ocr) Func _rectOCR($wTitle, $rX, $rY, $rWidth, $rHeight) $xy = WinGetPos($wTitle) $Title = WinGetTitle($wTitle) $hwnd = Dec(StringTrimLeft(WinGetHandle($Title), 2)) $obj = ObjCreate("TCaptureX.TextCaptureX") $results = $obj.GetTextFromRect($hwnd, $xy[0]+$rX, $xy[1]+$rY, $rWidth, $rHeight) return $results EndFunc im getting Variable must be of type Object, any solution? I will appreciate any help Ty Giovanni
×
×
  • Create New...