Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/28/2021 in all areas

  1. No way to test, but this should work: ; Set Global Variables - Change these to match your values Global $sMqttPub = "C:\Program Files\Mosquitto\mosquitto_pub.exe" Global $sHost = "192.168.0.81" Global $sTopic = "home/amaya" Local $sJob = "_ABC Test.ofm" Local $sCstitch = "0" Local $sActifeed = "1" ; Write to Console ConsoleWrite("Job Name = " & $sJob & @CRLF) ConsoleWrite("Stitch = " & $sCstitch & @CRLF) ConsoleWrite("Acti-feed = " & $sActifeed & @CRLF) Local $TheJson = '{"cJob":"_ABC Test.ofm","actifeed":"1","cStitch":"0"}' $sMQTT = '"' & $sMqttPub & '" -h ' & $sHost & " -t " & $sTopic & " -m " & "'" & $TheJson & "'" ConsoleWrite($sMQTT & @CRLF) ; Send to MQTT Broker ;~ run($sMQTT, '', @SW_HIDE)
    1 point
  2. Jos

    Convert ASM code to AutoIT

    When you want help you need to post a question with a proper goal or purpose... so try again.
    1 point
  3. @junkew please can you write the code i requested ? please
    1 point
  4. There is a manual https://www.autoitscript.com/autoit3/docs/functions/FileMove.htm
    1 point
  5. Jos

    Convert ASM code to AutoIT

    Anything wrong with your helpfile? (and why did you mention that it isn't game related? ) Test() Func Test() EndFunc
    1 point
  6. Loc

    Convert ASM code to AutoIT

    I'm learning about ASM, so I'm studying and studying to switch to AutoIT. This code is just for calling 1 function(Not game related).
    1 point
  7. UEZ

    GDIPlus Fill Shape

    You mean something like this?: #include <GDIPlus.au3> #include <GUIConstantsEx.au3> #Include <Misc.au3> Opt("GUIOnEventMode", 1) Opt("MouseCoordMode",2) Global $dll = DllOpen("user32.dll") _GDIPlus_Startup() Global $bitmap_from_file = _GDIPlus_BitmapCreateFromFile(@ScriptDir & '\Europe.bmp') Global $width = _GDIPlus_ImageGetWidth ($bitmap_from_file) Global $height = _GDIPlus_ImageGetHeight ($bitmap_from_file) Global $hwnd = GUICreate("GDI32: Flood Fill Example", $width, $height) GUISetOnEvent(-3, "Close") GUISetState() Global $hDC = _WinAPI_GetDC($hWnd) Global $hGraphics = _GDIPlus_GraphicsCreateFromHDC($hDC) _GDIPlus_GraphicsDrawImageRect($hGraphics, $bitmap_from_file, 0, 0, $width, $height) Global $hBrush = DllCall("gdi32.dll", "long", "CreateSolidBrush", "int", 0xFF5050) ; fill color BGR Global $obj_orig = DLLCall("gdi32.dll", "int", "SelectObject", "int", $hDC, "int", $hBrush[0]) While Sleep(50) If _IsPressed("01") And WinActive($hWnd) Then $mp = MouseGetPos() DllCall("gdi32.dll", "int", "FloodFill", "int", $hDC, "int", $mp[0], "int", $mp[1], "int", 0x000000) EndIf WEnd Func Close() DllClose($dll) DLLCall("gdi32.dll", "int", "SelectObject", "hwnd", $hwnd, "int", $obj_orig[0]) DLLCall("gdi32.dll", "int", "DeleteObject", "int",$hBrush[0]) _WinAPI_ReleaseDC($hWnd, $hDC) _GDIPlus_GraphicsDispose($hGraphics) _GDIPlus_Shutdown() Exit EndFunc Br, UEZ
    1 point
  8. Achilles

    Making a map!

    I'm planning on making a game that quizes the user on the capitals and positions of South American countries (eventually all the world once I get to summer...). However, In order to ask a question the computer will randomly highlight one of the countries by making the whole country a specific unique color. Instead of making about 15 different images where each different image has a different color highlighted I was wondering if there was a way to "fill" (like paint does) a certain country. I have a short example: GuiCreate('Map of South America', 516, 761) GuiCtrlCreatePic(@ScriptDir & '\South America Map.gif', 5, 5, 506, 751) ;Image is attached GUISetState() Do Sleep(50) Until GuiGetMsg() = -3
    1 point
×
×
  • Create New...