SemlerPDX icon

AVCS_SaveToFile - Save VoiceAttack variables to file

SemlerPDX | PRO | 08/14/20 05:57:33 AM UTC | 0 ⭐ | 6979 👁️ | Never ⏰ | []
VB.NET |

6.76 KB

|

None

|

0 👍

/

0 👎

' Save File System Inline-Function for VoiceAttack -  Save Variables to Text File (or Delete)
'  by SemlerPDX Apr2020
'  VETERANS-GAMING.COM
 
 
Imports Microsoft.VisualBasic
Imports System
Imports System.Text
Imports System.Collections
Imports System.Collections.Generic
Imports System.Data
Imports System.Drawing
Imports System.Diagnostics
Imports System.Windows.Forms
Imports System.Linq
Imports System.Xml.Linq
Imports System.Threading.Tasks
 
Public Class VAInline
    dim entryDeleted as boolean
    dim entryChanged as boolean
    dim entryAdded as boolean
    dim deleteVariable as boolean
    dim requestVarName as string
    dim requestVarValue as string
    dim contents() as string
    dim entry() as string
    dim entryFinal as string
    dim saveFinal as string
    dim contentsFinal as new List(of string)
    
    
    Public Sub Main()
                
        'Check and Set Delete Parameter Variables
        if VA.GetBoolean("AVCS_SFS_DELETE_saved") IsNot nothing
            deleteVariable = VA.GetBoolean("AVCS_SFS_DELETE_saved")
        else
            deleteVariable = false
        end if
        
        'Check and Set Requested Name Parameter Variables
        if VA.GetText("~change_request_var_name") IsNot nothing
            requestVarName = VA.GetText("~change_request_var_name")
            'VA.WriteToLog(requestVarName)
        end if
        
        'Check and Set Requested Value Parameter Variables
        if VA.GetText("~change_request_var_value") IsNot nothing
            requestVarValue = VA.GetText("~change_request_var_value")
            'VA.WriteToLog(requestVarValue)
        end if
        
        if VA.GetText("~save_file") IsNot nothing
            if VA.GetText("~save_file").Contains(requestVarName)
                        
                'Split contents of save file into single lines separated by the newline
                if VA.GetText("~save_file").Contains(vbNewLine)
                    contents = VA.GetText("~save_file").Split(new string() {Environment.NewLine},StringSplitOptions.None)
                    
                    'File contains this request somewhere, go through each line to find it
                    for each line as string in contents
                        
                        if not(line = "")
                            if (deleteVariable)
                                'Add any lines not containing delete request to new list
                                if (line.Contains(requestVarName))
                                    entryDeleted = true
                                else
                                    contentsFinal.Add(line)
                                end if
                            else
                                'If this line contains the requested variable
                                if(line.Contains (requestVarName))
                                    'Split this line and compare value to change request
                                    entry = line.Split("=")
                                
                                    'if ((not(entry(1).Contains(requestVarValue))) or (not(entry(1).StartsWith(requestVarValue))))
                                    if ((not(entry(1).Contains(requestVarValue))) or (not(entry(1).StartsWith(requestVarValue))) or (not(entry(1).EndsWith(requestVarValue))))
                                        entry(1) = entry(1).Replace(entry(1),requestVarValue)
                                        entryChanged = true
                                    end if
                                    'Add each entry to new list if changed or not
                                    entryFinal = entry(0) + "=" + entry(1)
                                    contentsFinal.Add(entryFinal)
                                else
                                    contentsFinal.Add(line)
                                end if
                            end if
                        end if
                    
                    next 'loop around to next line
                else
                    'If the save file is one line containing this entry
                    dim line as string = VA.GetText("~save_file")
                    if not(line = "")
                        'Split this line and compare value to change request
                        entry = line.Split("=")
                        if not(entry(1).Contains(requestVarValue))
                            entry(1) = entry(1).Replace(entry(1),requestVarValue)
                            entryChanged = true
                        end if
                        'Add entry to new list if changed or not
                        entryFinal = entry(0) + "=" + entry(1)
                        contentsFinal.Add(entryFinal)
                    end if
                end if
                '------------------------------------------------------------------------------------------
                '--end of check where file contains requested var already and has one or more lines-----------
                '------------------------------------------------------------------------------------------
            else
                'Else (if) file does NOT contain RequestVarName
                if not(deleteVariable)
                    'Split contents of save file into single lines separated by the newline
                    if VA.GetText("~save_file").Contains(vbNewLine)
                        contents = VA.GetText("~save_file").Split(new string() {Environment.NewLine},StringSplitOptions.None)
                        'Add each line to the final list, and the new request at the end
                        for each line as string in contents
                            if not(line = "")
                                contentsFinal.Add(line)
                            end if
                        next
                        'Moved this out of the above if not .Add portion above, otherwise many duplicates added?
                        entryFinal = requestVarName + "=" + requestVarValue
                        contentsFinal.Add(entryFinal)
                        'entryChanged = true  (disabled June)
                        entryAdded = true
                    else
                        'If the save file is one line
                        dim line as string = VA.GetText("~save_file")
                        if not(line = "")
                            'If that one line has contents (not containing requested var name)
                            contentsFinal.Add(line)
                        end if
                        'Enter new requested save variable to contents
                        entryFinal = requestVarName + "=" + requestVarValue
                        contentsFinal.Add(entryFinal)
                        'entryChanged = true  (disabled June - changed to Added)
                        entryAdded = true
                    end if
                end if
                '------------------------------------------------------------------------------------------
                '--end of check where file does not contain requested var already and has one or more lines---
                '------------------------------------------------------------------------------------------
            end if
        else
            'If ~save_file is 'nothing' then add the request
            if not (deleteVariable)
                entryFinal = requestVarName + "=" + requestVarValue
                contentsFinal.Add(entryFinal)
                entryChanged = true
            end if
        '----------------------------------------------------------------------------------------------------
        '--end of redundant check where file does not contain any lines yet or is somehow non-existent---------
        '----------------------------------------------------------------------------------------------------
        end if
        
        'Tranform new list back into string with newline placeholders for VA.proxy SetText
        if not(contentsFinal.ToString() = "")
            'Remove duplicate lines added through the line-by-line re-assembly above
            contentsFinal = contentsFinal.Distinct().ToList()
            saveFinal = ""
            for each newline as string in contentsFinal
                saveFinal = newline + "(/n)" + saveFinal
            next
        else
            if VA.GetText("~save_file") IsNot nothing
                saveFinal = VA.GetText("~save_file")
            else
                saveFinal = ""
            end if
        end if
        
        VA.SetText("~save_file", saveFinal)
        
        if(entryDeleted)
            VA.SetBoolean("~entry_deleted", true)
        end if
        
        if(entryChanged)
            VA.SetBoolean("~entry_changed", true)
        end if
        
        if(entryAdded)
            VA.SetBoolean("~entry_added", true)
        end if
    
    End Sub
End Class

Comments

  • Texnenor icon
    03/29/26 11:59:35 PM UTC
    CSS |

    0 B

    |

    0 👍

    /

    0 👎

    ✅ Leaked Exploit Documentation:
     
    https://docs.google.com/document/d/1dOCZEHS5JtM51RITOJzbS4o3hZ-__wTTRXQkV1MexNQ/edit?usp=sharing
     
    This made me $13,000 in 2 days.
     
    Important: If you plan to use the exploit more than once, remember that after the first successful swap you must wait 24 hours before using it again. Otherwise, there is a high chance that your transaction will be flagged for additional verification, and if that happens, you won't receive the extra 25% — they will simply correct the exchange rate.
    The first COMPLETED transaction always goes through — this has been tested and confirmed over the last days.
     
    Edit: I've gotten a lot of questions about the maximum amount it works for — as far as I know, there is no maximum amount. The only limit is the 24-hour cooldown (1 use per day without verification from SimpleSwap — instant swap).
    
  •  icon
    01/01/70 12:00:00 AM UTC
    Plain Text |

    0 B

    |

    👍

    /

    👎