Leaderboard
Popular Content
Showing content with the highest reputation on 10/18/2013 in all areas
-
S3d.au3 This UDF enables you to draw simple 3D graphics. Features: Simple and easy to useDoesn't require external libraries. You don't need OpenGL or DirectX. Available Functions: _S3d_SelectGraphic($hGraphic, $iWidth, $iHeight, $iSmooth = 2) _S3d_SelectPen($hPen) _S3d_SelectBrush($hBrush) _S3d_SelectFont($hFont) _S3d_SelectFormat($hFormat) _S3d_SetClipCount($iCount) _S3d_Dist($nPos1X = 0, $nPos1Y = 0, $nPos1Z = 0, $nPos2X = 0, $nPos2Y = 0, $nPos2Z = 0) _S3d_DistFromCamera($nPosX = 0, $nPosY = 0, $nPosZ = 0) _S3d_SetCamera($nCameraX, $nCameraY, $nCameraZ, $nTargetX, $nTargetY, $nTargetZ, $nVAngle = 0, $nFAngle = 0.8, $nFScale = 1000) _S3d_SetCameraEx($nCameraX, $nCameraY, $nCameraZ, $nXYAngle = 0, $nXZAngle = 0, $nVAngle = 0, $nFAngle = 0.8, $nFScale = 1000) _S3d_SetLocalMatrix($n00 = 1, $n01 = 0, $n02 = 0, $n03 = 0, $n10 = 0, $n11 = 1, $n12 = 0, $n13 = 0, $n20 = 0, $n21 = 0, $n22 = 1, $n23 = 0, $n30 = 0, $n31 = 0, $n32 = 0, $n33 = 1) _S3d_MultiplyLocalMatrix($n00 = 1, $n01 = 0, $n02 = 0, $n03 = 0, $n10 = 0, $n11 = 1, $n12 = 0, $n13 = 0, $n20 = 0, $n21 = 0, $n22 = 1, $n23 = 0, $n30 = 0, $n31 = 0, $n32 = 0, $n33 = 1, $fRefresh = True) _S3d_LocalTranslate($nX, $nY, $nZ, $fRefresh = True) _S3d_LocalScale($nX, $nY, $nZ, $fRefresh = True) _S3d_LocalRotateX($nAngle, $fDeg = False, $fRefresh = True) _S3d_LocalRotateY($nAngle, $fDeg = False, $fRefresh = True) _S3d_LocalRotateZ($nAngle, $fDeg = False, $fRefresh = True) _S3d_GetLocalMatrix() _S3d_SetLocalMatrixEx(ByRef $aMatrix) _S3d_GetPos($nX, $nY, $nZ) _S3d_InitCurrentPos() _S3d_MoveTo($nX, $nY, $nZ = Default) _S3d_Clear($nColor = 0xFF000000) _S3d_Line($nX1, $nY1, $nZ1, $nX2, $nY2, $nZ2) _S3d_LineTo($nX, $nY, $nZ) _S3d_Box($nX1, $nY1, $nZ1, $nX2, $nY2, $nZ2) _S3d_Arrow($nX1, $nY1, $nZ1, $nX2, $nY2, $nZ2, $nLen = 30, $nAngle = 0.6) _S3d_Circle($nX, $nY, $nZ, $nRad, $fFill = False) _S3d_Polygon($aPoints, $fFill = False) _S3d_RegPolygon($nX, $nY, $nZ, $nRad, $iNum, $fFill = True) _S3d_Star($nX, $nY, $nZ, $nRad1, $nRad2, $iNum, $fFill = True) _S3d_Square($nX1, $nY1, $nZ1, $nX2, $nY2, $nZ2, $nX3, $nY3, $nZ3, $nX4, $nY4, $nZ4, $fFill = True) _S3d_MoveTo2($nXL, $nYL, $nZL, $nXR, $nYR, $nZR) _S3d_RibbonTo($nXL, $nYL, $nZL, $nXR, $nYR, $nZR) _S3d_String($sString, $nX, $nY, $nZ) New version!S3d.zip v1.3.1 (09/JUN/2014) * Archives S3d.zip v1.3.0 (05/SEP/2013) S3d.zip v1.2.3 (16/AUG/2013) Enjoy!1 point
-
An improved _ArrayUnique
jaberwacky reacted to BrewManNH for a topic
The function _ArrayUnique in the Array UDF has some serious design flaws in it, not to mention it's incredibly slow. This is a rewrite of that function. Practically nothing from the original function has remained. This version... doesn't rely upon using _ArrayAdd, not using that shaved 4 seconds off when using this with a 4100+ row array. has extensive bounds checking on all parameters of the function, something the original didn't do at all. streamlines the error checking process so it returns quicker when something sent to it isn't set correctly, all done at the top of the function doesn't use Dim eliminates the $vDelim parameter, which even the documentation says about it, "However, cannot forsee its usefullness" adds the ability to return a 2D array if sent a 2D array, and the $bReturn2 parameter is set to true. This will search the column requested, finding any duplicated entries, removing those duplicate entries, but returning all the rows that were found first. I don't know if anyone will find any use for this part of the function, but it was surprisingly easy to implement it, so I figured I'd leave it in. This version is approximately 50 - 80% faster than the original, and won't crash your script if you send it the wrong values in the parameters. Please play around with this to see if you can break it, or improve it. There is an example script inside the archive that uses the MusicList file as input. The MusicList file is just a text file with 4104 lines and 6 columns, try running the new and original versions using the 6th column as a search and see the difference in execution time. Returning a 2D array on a large array is going to take a lot longer than just returning a single dimension of the array. Using it on the 6th column of this array is still faster than returning a 1D array using the original function. __ArrayUnique.zip1 point -
Are you running the script as a 32 bit process?1 point
-
Will do some tests as soon as I return to my office.1 point
-
HELP!!! built over script
jdelaney reacted to 13lack13lade for a topic
After some research i discovered what you will need to do to get it back 'decompile' which is a nono on here for obvious reasons, sucks for me since i genuinely just want MY file back but as stated, obvious reasons why this isnt allowed.. my own fault, live and learn! Ive got an old version of the script i will have to redo the changes and as you said, chance to improve!!1 point -
These might do it for you: https://github.com/MattDiesel/au3-console/blob/master/Console.au3 I've been meaning to work on this for a while but never got round to it.1 point
-
@remin Take into account any letters Local $sText = "a title case only if a word is at start of line. or is preceding with a space." $iOffset = 1 Do $aRes = StringRegExp($sText, '(?<![\x{41}-\x{ffff}])[\x{41}-\x{ffff}]', 1, $iOffset) If @error Then ExitLoop $iOffset = @extended $sText = StringReplace($sText, $iOffset - 1, StringUpper($aRes[0])) Until 0 MsgBox(0, 'Yes?', $sText)1 point
-
Nee help in TCP and GUI list
Alexxander reacted to bogQ for a topic
------- im correcting you with this link it will show you picture from 3 comps on network connected with driveresial as their identificator over TCP with no problems in that topic that picture is from my old striped code ( ) that i implemanted in example that op is using, that old example shud be usable still (i think) and it already have one small "an array in a GUI list view" in itself ------- From what i see on first look from OPs code is that he have If @error Then _TCPAccept(), that part isnt good, coz if you dont get anything from client youl gona bee traped (@error is set if it dont recive anything) inside accept do untill loop till someone new connect so you do not need "do untill" on accept just puit accept in normal main lop as normall call to func, and you do not need if error to call accept, you only need to call accept and nothing else, "if error" shud not b connected in any way to your accept func and accep dont need inside lop that will pause rest of script. as for array i did explain on example post how its working you set empty array where first element is there to count connections other elements are automaticly added when new user connect if you add gui you only need instead "to display data on msgbox" to display it in gui wiith some gui command, shud that b input list listview or something third its your choice how to redirect data from script to displayu it to where you need it edit: small working example but youl need to work on it ofcors and b shure to read comment on timeint so that you can sort out if client isnt responding anymore #include <Array.au3> #include <GUIConstantsEx.au3> #include <GuiListView.au3> #include <GuiImageList.au3> GUICreate("Form1", 615, 227) $hListView = GUICtrlCreateListView("ID|PC Name|Operating system|timeint", -1, -1, 615, 227) ;timeint can b used if comp dcced to decide to delite socket and clear listview and update its and array index position, so this part i leave to you to sorte out :) _GUICtrlListView_AddItem($hListView, "1", 0) _GUICtrlListView_AddItem($hListView, "2", 0) _GUICtrlListView_AddItem($hListView, "3", 0) _GUICtrlListView_AddItem($hListView, "4", 0) GUISetState() TCPStartup() Dim $Socket_Data[1] $Socket_Data[0] = 0 $Listen = TCPListen(@IPAddress1, 1018, 500) If @error Then ConsoleWrite('!--> TCPListen error number ( ' & @error & ' ), look in the help file (on MSDN link) on func TCPListen to get more info about this error.' & @CRLF) Exit EndIf While 1 For $x = $Socket_Data[0] To 1 Step -1 $Recv = TCPRecv($Socket_Data[$x], 1000000) If $Recv Then $data = StringSplit($Recv,'$') _GUICtrlListView_AddSubItem($hListView,$x-1,$data[1],1) _GUICtrlListView_AddSubItem($hListView,$x-1,$data[2],2) _GUICtrlListView_AddSubItem($hListView,$x-1,TimerInit(),3) EndIf Next _Accept() WEnd Func _Accept() Local $Accept = TCPAccept($Listen) If $Accept <> -1 Then _ArrayAdd($Socket_Data, $Accept) $Socket_Data[0] += 1 EndIf EndFunc ;==>_Accept TCPStartup() $Socket = TCPConnect(@IPAddress1, 1018) If @error Then ConsoleWrite('!--> TCPConnect error number ( ' & @error & ' ), look in the help file (on MSDN link) on func TCPConnect to get more info about this error.' & @CRLF) Exit EndIf While 1 TCPSend($Socket, @ComputerName &'$'& @OSVersion) Sleep(1000) WEnd dont forget to use real server IP networ adress on clients script instead @IPAddress1 macro1 point -
editbox linked to word doc
13lack13lade reacted to water for a topic
Try the example script provided with _GUICtrlRichEdit_Create.1 point -
Just because. Here is a workaround. HotKeySet ("i", "Function1") HotKeySet ("l", "Function1") HotKeySet ("o", "Function1") While 1 Sleep (50) WEnd Func Function1 () Switch @HotKeyPressed Case "i" _ThisIsFunc1 ("Hello") Case "l" _ThisIsFunc2 ("Hello", "Goodbye") Case "o" _ThisIsFunc3 ("Hello", "Goodbye", 0) EndSwitch EndFunc Func _ThisIsFunc1 ($msg) MsgBox (0, "", $msg) EndFunc Func _ThisIsFunc2 ($msg, $title) MsgBox (0, $title, $msg) EndFunc Func _ThisIsFunc3 ($msg, $title, $flag) MsgBox ($flag, $title, $msg) EndFunc1 point