mirror of
				https://github.com/onyx-and-iris/voicemeeter-api-powershell.git
				synced 2025-11-03 22:01:45 +00:00 
			
		
		
		
	check size of script
This commit is contained in:
		
							parent
							
								
									2ad8118f2c
								
							
						
					
					
						commit
						1df92afcfe
					
				@ -188,6 +188,9 @@ function Set_By_Script {
 | 
			
		||||
    param(
 | 
			
		||||
        [string]$script
 | 
			
		||||
    )
 | 
			
		||||
    if ($script.Length -gt 48000) {
 | 
			
		||||
        throw [VMError]::new("Script size cannot be larger than 48kB")
 | 
			
		||||
    }
 | 
			
		||||
    $retval = [int][Voicemeeter.Remote]::VBVMR_SetParameters($script)
 | 
			
		||||
    if ($retval -notin @(0)) { 
 | 
			
		||||
        throw [CAPIError]::new($retval, "VBVMR_SetParameters") 
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user