Puls3 Posted September 28, 2018 Posted September 28, 2018 (edited) Hi, This is my first post on the AutoIt Forums, I most of the time was able to get help from this community by merely searching though google and have been able to solve hundreds of problems this way, though in this case I was incapable of finding a solution to my problem. I am quite confident that it is a user error (And my fault) but I haven't been able to determine what I did wrong, any and all help would be greatly appreciated! I have uploaded my whole script pardon passwords to provide as much information as possible. I declared a global array at the top of the script and am having issues when I try to set it's value, and I fail to understand why. Error Message: "D:\Projects\AutoIt\Arena\Base.au3" (270) : ==> Subscript used on non-accessible variable.: $ExpMax[$i] = IniRead($TempSavePath, "Combatant" & $i, "ExpMax", $ExpMax[0]) $ExpMax^ ERROR ConsoleWrite Log: Ran. Checking launch parameters. No launch parameters. Initiating load. Checking for save file. Save file not found. Load canceled. Loading or creating Combatant 1 Base.au3 Edited September 28, 2018 by Puls3 added code No, I'm not making a bot, keylogger, password stealer, virus, or anything else malicious, there are over a million different reasons someone would ask for whatever I did. Yes, I need to figure out the answer to the exact question I asked because I have valid reasons as to why I'm not using the alternatives. No, I cannot prove I'm not doing anything malicious because this is a forum and that is impossible. Thank you AutoIt community for always accusing people of doing something evil, good day. - The Infamous Impulsive Puls3
Moderators Melba23 Posted September 28, 2018 Moderators Posted September 28, 2018 (edited) Welcome to the AutoIt forum. Unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game automation - and then you will understand why you will get no help and this thread will now be locked. See you soon with a legitimate question I hope. The Moderation team Edited September 28, 2018 by Melba23 See below Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
Puls3 Posted September 28, 2018 Author Posted September 28, 2018 (edited) Locked Post Misunderstanding: My post was locked due to it being about game automation, this was 100% a misunderstanding and I would like to clearly state that I am creating a UI based game of my own inside AutoIt and Autoit only, all code of the game so far is inside the posted script, It cannot be about game automation if the game is written inside AutoIt (And written by me) as it would be a game feature and not automation. I already read the rules and found no way to appeal a locked post due to a misunderstanding so I apologize if I should have taken another action instead of re-posting with an explanation, though this forum really should add the ability to appeal locked posts. The "Game" is merely a simulation of a fight between two simulated fighters and as you can see in the script does not interact with any outside information besides the save files created by the script. Edited September 28, 2018 by Puls3 removed code No, I'm not making a bot, keylogger, password stealer, virus, or anything else malicious, there are over a million different reasons someone would ask for whatever I did. Yes, I need to figure out the answer to the exact question I asked because I have valid reasons as to why I'm not using the alternatives. No, I cannot prove I'm not doing anything malicious because this is a forum and that is impossible. Thank you AutoIt community for always accusing people of doing something evil, good day. - The Infamous Impulsive Puls3
Moderators Melba23 Posted September 28, 2018 Moderators Posted September 28, 2018 Puls3, Quote Locked Post Misunderstanding: My post was locked due to it being about game automation, this was 100% a misunderstanding and I would like to clearly state that I am creating a UI based game of my own inside AutoIt and Autoit only, all code of the game so far is inside the posted script, It cannot be about game automation if the game is written inside AutoIt (And written by me) as it would be a game feature and not automation. I already read the rules and found no way to appeal a locked post due to a misunderstanding so I apologize if I should have taken another action instead of re-posting with an explanation, though this forum really should add the ability to appeal locked posts. Thread unlocked - but it would have helped if you had stated all of that in the OP. And all you have to do to appeal is send me a PM - but no harm done. M23 Puls3 1 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
Puls3 Posted September 28, 2018 Author Posted September 28, 2018 I discovered what I was doing wrong on my own, It was a simple error that I had missed. Func Defaults() $Name[0] = "Combatant" $Level[0] = 1 $Exp[0] = 0 $ExpMax = 20; <--- $Dead[0] = 0 $Health[0] = 20 $HealthMax[0] = 20 $Attack[0] = 1 $Defense[0] = 1 EndFunc I turned it from an array into a simple variable as I forgot to add a "[0]" to the end, and so $ExpMax[$i], no matter what number was put into it, would not exist as it was no longer an array. Xandy 1 No, I'm not making a bot, keylogger, password stealer, virus, or anything else malicious, there are over a million different reasons someone would ask for whatever I did. Yes, I need to figure out the answer to the exact question I asked because I have valid reasons as to why I'm not using the alternatives. No, I cannot prove I'm not doing anything malicious because this is a forum and that is impossible. Thank you AutoIt community for always accusing people of doing something evil, good day. - The Infamous Impulsive Puls3
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now