Jump to content
Sign in to follow this  
DanielLaCosta

Script running in the background running application.

Recommended Posts

DanielLaCosta

Hello.

I need a script that is pre-written script for a certain program / ​​in-game run.

For example, if I am writing a script, which is 25 seconds by pressing the "w", where such a program in which I want the script to work lay in the tray, and watch the Firefox or any other program then there should not interfere with the writing and so on.

So then only the specified program to detect a button press, if it runs in the background.

I hope you can help me with this.

Sorry for bad English, I used google translator.

This is a simple markup should be put to the program in which I choose a running.

(Some of the code is written in Hungarian. the msgbox parts.)

;
; AutoIt Version: 3.0
; Language:    HUN
; Platform:    WinXP
; Author:       Daniel La Costa (daniel_la_costa@hotmail.com)
;
; Script Function:
;   Opens Notepad, types in some text and then quits.
;

; Prompt the user to run the script - use a Yes/No prompt (4 - see help file)
Local $answer = MsgBox(4, "SA:MP Auto mower v0.1", "Ez a Program automatikusan lenyomja 25mp-enként a (w) gombot." & @CRLF &  "-Indítsd a SA:MP-ot" & @CRLF & "-Csatlakozz a szerverhez, majd lépj be a karakteredhez" & @CRLF & "-Bújj el vele, majd nyomj ALT+TAB-ot" & @CRLF & "-Majd nyomj az Igen-re és lépj vissza a játék ablakra" & @CRLF & "Indítsam?" & @CRLF & "Készítette: Daniel")

; Check the user's answer to the prompt (see the help file for MsgBox return values)
; If "No" was clicked (7) then exit the script
If $answer = 7 Then
MsgBox(0, "SA:MP Auto mower v0.1", "OK.  Bye!")
Exit
EndIf

While 1
Send("w")
sleep(25000) ; 2500000 sec
Wend

; Finished!

Share this post


Link to post
Share on other sites
DanielLaCosta

"I'm sorry but we're not allowed to discuss game automation here."

That is no automating game. That is a simple on step mower/helper, for the game server no kick out when i am AFK.

this script every 25 seconds by pressing the (W). This is only a single utility.

Share this post


Link to post
Share on other sites
1RV34

Well I don't know if the mods here consider it automation or not but to be safe I'm not gonna give you info to automate it in AutoIt.

A slight suggestion I might could do is if the game as an ingame console maybe you can use that to do something like

alias loop "+forward;wait 10;-forward;wait 750000;loop"

Try to use that in-game method because even tho it is a simple W press it is still ingame and an automation :/


MsgBox(0x40040, "", "Hello Forum!")

Share this post


Link to post
Share on other sites
Melba23

DanielLaCosta,

I was asked to look at this thread as a possible "game automation" rule breaker. As far as I can see you are coding something to keep a connection alive and not interacting with the game itself. Unless someone can show me that sending "w" at 25 sec intervals is an interaction to your advantage within the game I am happy that this specific question is legal. :)

But please do not post any subsequent questions concerning the automation of the game proper. ;)

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
Melba23

AdmiralAlkex,

Rather than post sarcastic comments why not do what I asked above and tell me that, in your opinion, this is game interaction? ;)

I do not play games - I find my real life quite exciting enough - and so rely on others to help out in cases like this. Next time please could you do so in a manner more befitting an MVP. ;)

DanielLaCosta,

It appears that sending "w" does interact with the game - so I am locking the thread. Do not start another one. :)

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×