TextPad is finally working correctly

This commit is contained in:
EverythingWindows 2022-11-07 14:16:34 +07:00
parent 78525e6c04
commit afd327f7b8
3 changed files with 341 additions and 151 deletions

View file

@ -3,18 +3,17 @@
Module FileManagement Module FileManagement
Public Sub CatFile(filename As String) Public Sub CatFile(filename As String)
If File.Exists(Terminal.CurrentDirectory & "\" & filename) = True Then If File.Exists(Terminal.CurrentDirectory & "\" & filename) = True Then
Try Dim ContentsFinal As String = File.ReadAllText(Terminal.CurrentDirectory & "\" & filename)
Dim Contents As Byte() = File.ReadAllBytes(Terminal.CurrentDirectory & "\" & filename) Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & ContentsFinal
Dim ContentsFinal As String = Convert.ToString(Contents)
Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & ContentsFinal
Catch ex As Exception
Try
Dim ContentsFinal As String() = File.ReadAllLines(Terminal.CurrentDirectory & "\" & filename)
Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & ContentsFinal
Catch ex As Exception
End Try
End Try
End If End If
End Sub End Sub
Public Sub SaveFile(filename As String)
'If File.Exists(Terminal.CurrentDirectory & "\" & filename) = False Then
' File.WriteAllText(Terminal.CurrentDirectory & "\" & filename, Terminal.TextBox1.Text)
'Else
' File.WriteAllText(Terminal.CurrentDirectory & "\" & filename, Terminal.TextBox1.Text)
'End If
File.WriteAllText(Terminal.CurrentDirectory & "\" & filename, Terminal.TextBox1.Text)
End Sub
End Module End Module

View file

@ -1,9 +1,9 @@
Imports System.IO Imports System.IO
Public Class Terminal Public Class Terminal
Public TrackPos As Integer
Public command As String Public command As String
Public DefaultPrompt As String Public DefaultPrompt As String
Public TrackPos As Integer
Public AdvancedCommand As Boolean Public AdvancedCommand As Boolean
Public BadCommand As Boolean Public BadCommand As Boolean
Public DisplayStory As Integer Public DisplayStory As Integer
@ -266,11 +266,6 @@ Public Class Terminal
TextBox1.Text = TextBox1.Text & Environment.NewLine TextBox1.Text = TextBox1.Text & Environment.NewLine
AdvancedCommand = False AdvancedCommand = False
BadCommand = False BadCommand = False
Case "textpad"
ChangeInterpreter = True
AppHost("textpad", True)
AdvancedCommand = False
BadCommand = False
Case "pwd" Case "pwd"
TextBox1.Text = TextBox1.Text & Environment.NewLine & CurrentDirectory.Replace(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) & "\ShiftOS\ShiftFS", "!") TextBox1.Text = TextBox1.Text & Environment.NewLine & CurrentDirectory.Replace(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) & "\ShiftOS\ShiftFS", "!")
AdvancedCommand = False AdvancedCommand = False
@ -365,12 +360,18 @@ Public Class Terminal
If AdvancedCommand = True Then If AdvancedCommand = True Then
If command Like "cat *" Then If command Like "cat *" Then
CatFile(command.Substring(4)) If Strings.AvailableFeature(16) = 1 Then
CatFile(command.Substring(4))
AdvancedCommand = False
BadCommand = False
End If
End If End If
If command Like "cd *" Then If command Like "cd *" Then
NavigateDir(command.Replace("cd ", "")) If Strings.AvailableFeature(16) = 1 Then
AdvancedCommand = False NavigateDir(command.Replace("cd ", ""))
BadCommand = False AdvancedCommand = False
BadCommand = False
End If
End If End If
If command Like "color *" Then If command Like "color *" Then
GetColor("terminal", command.Substring(6, 1), command.Substring(7, 1)) GetColor("terminal", command.Substring(6, 1), command.Substring(7, 1))
@ -481,14 +482,28 @@ Public Class Terminal
End If End If
End If End If
If command Like "mkdir *" Then If command Like "mkdir *" Then
CreateDir(command.Replace("mkdir ", "")) If Strings.AvailableFeature(16) Then
AdvancedCommand = False CreateDir(command.Replace("mkdir ", ""))
BadCommand = False AdvancedCommand = False
BadCommand = False
End If
End If
If command Like "print *" Then
If Strings.AvailableFeature(2) = "1" Then
TextBox1.Text = TextBox1.Text & Environment.NewLine & command.Substring(6)
Dim printed As String = command.Replace("print ", "")
''It has the same issue, only displays in lowercase
'TextBox1.Text = TextBox1.Text & Environment.NewLine & printed
BadCommand = False
AdvancedCommand = False
End If
End If End If
If command Like "rmdir *" Then If command Like "rmdir *" Then
RemoveDir(command.Replace("rmdir ", "")) If Strings.AvailableFeature(16) = 1 Then
AdvancedCommand = False RemoveDir(command.Replace("rmdir ", ""))
BadCommand = False AdvancedCommand = False
BadCommand = False
End If
End If End If
If command Like "shiftorium *" Then If command Like "shiftorium *" Then
Dim prompt As String = command.Replace("shiftorium ", "") Dim prompt As String = command.Replace("shiftorium ", "")
@ -506,16 +521,15 @@ Public Class Terminal
BadCommand = False BadCommand = False
End If End If
End If End If
If command Like "print *" Then If command Like "textpad *" Then
If Strings.AvailableFeature(2) = "1" Then If Strings.AvailableFeature(17) = 1 Then
TextBox1.Text = TextBox1.Text & Environment.NewLine & command.Substring(6) ChangeInterpreter = True
Dim printed As String = command.Replace("print ", "") command = command.Replace("textpad ", "")
''It has the same issue, only displays in lowercase AppHost("textpad", True)
'TextBox1.Text = TextBox1.Text & Environment.NewLine & printed AdvancedCommand = False
BadCommand = False BadCommand = False
End If End If
End If End If
AdvancedCommand = False
End If End If
If BadCommand = True Then If BadCommand = True Then
@ -523,124 +537,212 @@ Public Class Terminal
End If End If
End Sub End Sub
Public Sub TextRebind()
TextBox1.Select(TextBox1.Text.Length, 0)
TextBox1.ScrollToCaret()
End Sub
Private Sub txtterm_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBox1.KeyDown Private Sub txtterm_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBox1.KeyDown
TerminalApps.KeyInput = e.KeyData
Select Case e.KeyData Select Case e.KeyData
Case (Keys.Control + Keys.Q) Case (Keys.Control + Keys.Q)
If CurrentInterpreter = "terminal" Then If CurrentInterpreter = "terminal" Then
Else Else
TerminateApp() TerminateApp(TerminalApps.KeyInput)
PrintPrompt() TextRebind()
End If End If
Case Else
CaptureKeyBinding(TerminalApps.KeyInput)
End Select End Select
'Select Case e.KeyCode 'If ReleaseCursor = True Then
' Case e.KeyCode = Keys.T AndAlso e.Control
' e.SuppressKeyPress = True 'Else
' Case e.KeyCode = Keys.Q AndAlso e.Control ' Select Case e.KeyCode
' If CurrentInterpreter = "terminal" Then ' Case Keys.ShiftKey
' TrackPos = TrackPos - 1
' Case Keys.Alt
' TrackPos = TrackPos - 1
' Case Keys.CapsLock
' TrackPos = TrackPos - 1
' Case Keys.ControlKey
' TrackPos = TrackPos - 1
' Case Keys.LWin
' TrackPos = TrackPos - 1
' Case Keys.RWin
' TrackPos = TrackPos - 1
' Case Keys.Right
' If TextBox1.SelectionStart = TextBox1.TextLength Then
' TrackPos = TrackPos - 1
' End If
' Case Keys.Left
' If TrackPos < 1 Then
' e.SuppressKeyPress = True
' TrackPos = TrackPos - 1
' Else
' TrackPos = TrackPos - 2
' End If
' Case Keys.Up
' e.SuppressKeyPress = True
' TrackPos = TrackPos - 1
' Case Keys.Down
' e.SuppressKeyPress = True
' TrackPos = TrackPos - 1
' End Select
'End If
'If e.KeyCode = Keys.Enter Then
' e.SuppressKeyPress = True
' If TextBox1.ReadOnly = True Then
' Else
' ReadCommand()
' If ChangeInterpreter = True Then
' DoChildCommand()
' PrintPrompt()
' TextBox1.Select(TextBox1.Text.Length, 0)
' Else ' Else
' TerminateApp() ' DoCommand()
' PrintPrompt()
' TextBox1.Select(TextBox1.Text.Length, 0)
' End If ' End If
'End Select ' End If
' 'If command = "clear" Then
' ' PrintPrompt()
' ' TextBox1.Select(TextBox1.Text.Length, 0)
' 'Else
' ' PrintPrompt()
' ' TextBox1.Select(TextBox1.Text.Length, 0)
' 'End If
' TrackPos = 0
'Else
' If ReleaseCursor = True Then
' Else
' If e.KeyCode = Keys.Back Then
' Else
' TrackPos = TrackPos + 1
' End If
' End If
'End If
'If e.KeyCode = Keys.Back Then
' If TrackPos < 1 Then
' e.SuppressKeyPress = True
' Else
' If TextBox1.SelectedText.Length < 1 Then
' TrackPos = TrackPos - 1
' Else
' e.SuppressKeyPress = True
' End If
' End If
'End If
'TextBox1.Select(TextBox1.TextLength, 0)
'TextBox1.ScrollToCaret()
If ReleaseCursor = True Then If ReleaseCursor = True Then
Else Else
If ReleaseCursor = True Then Select Case e.KeyData
Case Keys.Enter
e.SuppressKeyPress = True
If TextBox1.ReadOnly = True Then
Else
Select Case e.KeyCode
Case Keys.ShiftKey
TrackPos = TrackPos - 1
Case Keys.Alt
TrackPos = TrackPos - 1
Case Keys.CapsLock
TrackPos = TrackPos - 1
Case Keys.ControlKey
TrackPos = TrackPos - 1
Case Keys.Right
If TextBox1.SelectionStart = TextBox1.TextLength Then
TrackPos = TrackPos - 1
End If
Case Keys.Left
If TrackPos < 1 Then
e.SuppressKeyPress = True
TrackPos = TrackPos - 1
Else
TrackPos = TrackPos - 2
End If
Case Keys.Up
e.SuppressKeyPress = True
TrackPos = TrackPos - 1
Case Keys.Down
e.SuppressKeyPress = True
TrackPos = TrackPos - 1
End Select
End If
Select Case e.KeyCode
Case Keys.LWin
TrackPos = TrackPos - 1
Case Keys.RWin
TrackPos = TrackPos - 1
End Select
If e.KeyCode = Keys.Enter Then
e.SuppressKeyPress = True
If TextBox1.ReadOnly = True Then
Else
ReadCommand()
If ChangeInterpreter = True Then
DoChildCommand()
PrintPrompt()
TextBox1.Select(TextBox1.Text.Length, 0)
Else Else
DoCommand() ReadCommand()
PrintPrompt() If ChangeInterpreter = True Then
TextBox1.Select(TextBox1.Text.Length, 0) DoChildCommand()
PrintPrompt()
TextRebind()
Else
DoCommand()
PrintPrompt()
TextRebind()
End If
End If End If
End If TrackPos = 0
Case Keys.ShiftKey, Keys.Alt, Keys.ControlKey, Keys.LWin, Keys.RWin
'If command = "clear" Then e.SuppressKeyPress = True
' PrintPrompt() Case Keys.Back
' TextBox1.Select(TextBox1.Text.Length, 0) If TrackPos <= 0 Then
e.SuppressKeyPress = True
'Else Else
' PrintPrompt() TrackPos = TrackPos - 1
' TextBox1.Select(TextBox1.Text.Length, 0) 'If TextBox1.SelectedText.Length < 1 Then
'End If ' TrackPos = TrackPos - 1
'Else
TrackPos = 0 ' e.SuppressKeyPress = True
Else 'End If
If ReleaseCursor = True Then End If
Case Keys.Right
Else If TextBox1.SelectionStart = TextBox1.TextLength Then
If e.KeyCode = Keys.Back Then
Else Else
TrackPos = TrackPos + 1 TrackPos = TrackPos + 1
End If End If
End If 'If TrackPos <= 0 Then
End If ' Dim CommandChar As String
' CommandChar = TextBox1.Lines(TextBox1.Lines.Length - 1)
If ReleaseCursor = True Then ' CommandChar = CommandChar.Replace(DefaultPrompt, "")
' TrackPos = CommandChar.Length - 1
Else ' TextBox1.Select(TextBox1.TextLength, 0)
If e.KeyCode = Keys.Back Then ' TextBox1.ScrollToCaret()
If TrackPos < 1 Then 'End If
Case Keys.Left
If TextBox1.SelectionStart = 0 Then
e.SuppressKeyPress = True e.SuppressKeyPress = True
Else Else
If TextBox1.SelectedText.Length < 1 Then TrackPos = TrackPos - 1
TrackPos = TrackPos - 1
Else
e.SuppressKeyPress = True
End If
End If End If
End If If TrackPos <= 0 Then
End If Dim CommandChar As String
CommandChar = TextBox1.Lines(TextBox1.Lines.Length - 1)
CommandChar = CommandChar.Replace(DefaultPrompt, "")
TrackPos = CommandChar.Length - 1
TextBox1.Select(TextBox1.TextLength, 0)
TextBox1.ScrollToCaret()
End If
'If TrackPos < 1 Then
' e.SuppressKeyPress = True
' TrackPos = TrackPos - 1
'Else
' TrackPos = TrackPos - 2
'End If
Case Keys.Up
e.SuppressKeyPress = True
Case Keys.Down
e.SuppressKeyPress = True
Case Else
TrackPos = TrackPos + 1
End Select
End If End If
TextBox1.Select(TextBox1.TextLength, 0) 'If e.KeyCode = Keys.Enter Then
TextBox1.ScrollToCaret() ' 'If command = "clear" Then
' ' txtterm.Text = txtterm.Text + ShiftOSDesktop.username & "@" & ShiftOSDesktop.osname & " $> "
' ' txtterm.Select(txtterm.Text.Length, 0)
' 'Else
' ' txtterm.Text = txtterm.Text + Environment.NewLine & ShiftOSDesktop.username & "@" & ShiftOSDesktop.osname & " $> "
' ' txtterm.Select(txtterm.Text.Length, 0)
' 'End If
'Else
' If e.KeyCode = Keys.Back Then
' Else
' TrackPos = TrackPos + 1
' End If
'End If
'If e.KeyCode = Keys.Back Then
' 'If TrackPos < 1 Then
' ' e.SuppressKeyPress = True
' 'Else
' ' If TextBox1.SelectedText.Length < 1 Then
' ' TrackPos = TrackPos - 1
' ' Else
' ' e.SuppressKeyPress = True
' ' End If
' 'End If
'End If
End Sub End Sub
Private Sub TextBox1_Click(sender As Object, e As EventArgs) Handles TextBox1.Click, TextBox1.MouseDoubleClick Private Sub TextBox1_Click(sender As Object, e As EventArgs) Handles TextBox1.Click, TextBox1.MouseDoubleClick
@ -718,5 +820,10 @@ Public Class Terminal
End If End If
InfoBar.Text = InfoBar.Text & " " & CurrentInterpreter & " |" InfoBar.Text = InfoBar.Text & " " & CurrentInterpreter & " |"
InfoBar.Text = InfoBar.Text & " " & Strings.ComputerInfo(2) & " CP |" InfoBar.Text = InfoBar.Text & " " & Strings.ComputerInfo(2) & " CP |"
InfoBar.Text = InfoBar.Text & " " & TrackPos & " |"
End Sub
Private Sub TextBox1_Click(sender As Object, e As MouseEventArgs) Handles TextBox1.MouseDoubleClick, TextBox1.Click
End Sub End Sub
End Class End Class

View file

@ -1,5 +1,8 @@
Module TerminalApps Imports System.IO
Module TerminalApps
Public ShouldChange As Boolean = False Public ShouldChange As Boolean = False
Public KeyInput As Keys
'This is for GTN's RAM 'This is for GTN's RAM
Public TheNumber As Integer = 0 Public TheNumber As Integer = 0
Public FreezeText As String Public FreezeText As String
@ -12,6 +15,9 @@
Public BC_CurrentNumber As String Public BC_CurrentNumber As String
Public BC_Result As Integer Public BC_Result As Integer
Public BC_Operation2 As String Public BC_Operation2 As String
'TextPad's RAM
Public TextPad_FileName As String
Public TextPad_TempText As New Timer
Public Sub ChangeCP(Addition As Boolean, NeededCP As Integer) Public Sub ChangeCP(Addition As Boolean, NeededCP As Integer)
Dim TempCP As Integer = Convert.ToInt32(Strings.ComputerInfo(2)) Dim TempCP As Integer = Convert.ToInt32(Strings.ComputerInfo(2))
@ -50,17 +56,18 @@
Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & Environment.NewLine & "Type any package you want to investigate" Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & Environment.NewLine & "Type any package you want to investigate"
ShouldChange = True ShouldChange = True
Case "textpad" Case "textpad"
Terminal.DefaultPrompt = "" Terminal.DefaultPrompt = Nothing
Terminal.TextBox1.Text = Nothing
Terminal.ToolBarUse = True Terminal.ToolBarUse = True
Terminal.CheckFeature() Terminal.CheckFeature()
Terminal.CurrentInterpreter = "textpad" Terminal.CurrentInterpreter = "textpad"
Terminal.ToolBar.Text = "TextPad - " & Environment.NewLine & "Ctrl-Q Exit | Ctrl-N New | Ctrl-O Open | Ctrl-S Save | F12 Save As" TextPad_CheckExist(Terminal.command)
Terminal.TextBox1.Text = Nothing Terminal.ToolBar.Text = "TextPad - " & Terminal.command & Environment.NewLine & "Ctrl-Q Exit | Ctrl-N New | Ctrl-O Open | Ctrl-S Save | F12 Save As"
Terminal.ReleaseCursor = True Terminal.ReleaseCursor = True
End Select End Select
If Terminal.ReleaseCursor = True Then If Terminal.ReleaseCursor = True Then
Strings.OnceInfo(5) = Terminal.TrackPos 'Strings.OnceInfo(5) = Terminal.TrackPos
Terminal.TrackPos = Nothing 'Terminal.TrackPos = Nothing
End If End If
If ShouldChange = True Then If ShouldChange = True Then
Terminal.ChangeInterpreter = True Terminal.ChangeInterpreter = True
@ -68,17 +75,67 @@
End If End If
End Sub End Sub
Public Sub TerminateApp() Public Sub CaptureKeyBinding(KeysInput As Keys)
If Terminal.ReleaseCursor = True Then Select Case KeysInput
Terminal.TrackPos = Strings.OnceInfo(5) Case (Keys.S + Keys.Control)
Strings.OnceInfo(5) = 0 If File.Exists(Terminal.CurrentDirectory & "\" & Terminal.command) = True Then
End If Dim TempCompare As String = File.ReadAllText(Terminal.CurrentDirectory & "\" & Terminal.command)
Terminal.ToolBarUse = False If Terminal.TextBox1.Text = TempCompare Then
Terminal.ChangeInterpreter = False
Terminal.ReleaseCursor = False Else
Terminal.CurrentInterpreter = "terminal" Dim BeforeCP As Integer = Strings.ComputerInfo(2)
Terminal.CheckFeature() SaveFile(Terminal.command)
Terminal.AssignPrompt() TextPad_GenerateCP_SavedFile()
Dim AfterCP As Integer = Strings.ComputerInfo(2) - BeforeCP
Terminal.ToolBar.Text = "TextPad - " & Terminal.command & " - You've got " & AfterCP & " Codepoints" & Environment.NewLine & "Ctrl-Q Exit | Ctrl-N New | Ctrl-O Open | Ctrl-S Save | F12 Save As"
End If
Else
Dim BeforeCP As Integer = Strings.ComputerInfo(2)
SaveFile(Terminal.command)
TextPad_GenerateCP_SavedFile()
Dim AfterCP As Integer = Strings.ComputerInfo(2) - BeforeCP
Terminal.ToolBar.Text = "TextPad - " & Terminal.command & " - You've got " & AfterCP & " Codepoints" & Environment.NewLine & "Ctrl-Q Exit | Ctrl-N New | Ctrl-O Open | Ctrl-S Save | F12 Save As"
End If
End Select
End Sub
Public Sub TerminateApp(KeyInput As Keys)
Select Case Terminal.CurrentInterpreter
Case "textpad"
Dim BeforeCP As Integer = Strings.ComputerInfo(2)
If File.Exists(Terminal.CurrentDirectory & "\" & Terminal.command) = True Then
Dim TextCompare As String = My.Computer.FileSystem.ReadAllText(Terminal.CurrentDirectory & "\" & Terminal.command)
If Terminal.TextBox1.Text = TextCompare Then
Terminal.TextBox1.Text = Nothing
Else
SaveFile(Terminal.command)
TextPad_GenerateCP_SavedFile()
Dim AfterCP As Integer = Strings.ComputerInfo(2) - BeforeCP
Terminal.TextBox1.Text = "You've got " & AfterCP & " Codepoints"
End If
Else
SaveFile(Terminal.command)
TextPad_GenerateCP_SavedFile()
Dim AfterCP As Integer = Strings.ComputerInfo(2) - BeforeCP
Terminal.TextBox1.Text = "You've got " & AfterCP & " Codepoints"
End If
Terminal.ToolBarUse = False
Terminal.ChangeInterpreter = False
Terminal.ReleaseCursor = False
Terminal.CurrentInterpreter = "terminal"
Terminal.CheckFeature()
Terminal.AssignPrompt()
Terminal.PrintPrompt()
Terminal.TextRebind()
Case Else
Terminal.ToolBarUse = False
Terminal.ChangeInterpreter = False
Terminal.ReleaseCursor = False
Terminal.CurrentInterpreter = "terminal"
Terminal.CheckFeature()
Terminal.AssignPrompt()
Terminal.TextRebind()
End Select
End Sub End Sub
Public Sub DoChildCommand() Public Sub DoChildCommand()
@ -86,7 +143,7 @@
Case "guess" Case "guess"
Select Case Terminal.command Select Case Terminal.command
Case "exit" Case "exit"
TerminateApp() TerminateApp(Nothing)
Case Else Case Else
Try Try
GTN_CheckNumber() GTN_CheckNumber()
@ -99,7 +156,7 @@
Case "" Case ""
Case "exit" Case "exit"
TerminateApp() TerminateApp(Nothing)
Case Else Case Else
ShiftoriumFX_DisplayPackages() ShiftoriumFX_DisplayPackages()
Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & Environment.NewLine & "Type any package you want to investigate" & Environment.NewLine & "Invalid package or bad command" Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & Environment.NewLine & "Type any package you want to investigate" & Environment.NewLine & "Invalid package or bad command"
@ -111,7 +168,7 @@
Case "ojas" Case "ojas"
Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & "dis calculator is very gud" & Environment.NewLine & "it counts from another universe" Terminal.TextBox1.Text = Terminal.TextBox1.Text & Environment.NewLine & "dis calculator is very gud" & Environment.NewLine & "it counts from another universe"
Case "exit" Case "exit"
TerminateApp() TerminateApp(Nothing)
Case Else Case Else
BC_ReadNumbers = 0 BC_ReadNumbers = 0
BC_ThriceMoreValue = 1 BC_ThriceMoreValue = 1
@ -200,6 +257,33 @@
End If End If
End Sub End Sub
Public Sub TextPad_CheckExist(TxtFileName As String)
If File.Exists(Terminal.CurrentDirectory & "\" & TxtFileName) = True Then
Terminal.TextBox1.Text = My.Computer.FileSystem.ReadAllText(Terminal.CurrentDirectory & "\" & TxtFileName)
End If
End Sub
Public Sub TextPad_GenerateCP_SavedFile()
Select Case Terminal.TextBox1.TextLength
Case 1 To 9
Dim GetCP As New Random
Dim GotCP As Integer = GetCP.Next(1, 6)
ChangeCP(True, GotCP)
Case 10 To 99
Dim GetCP As New Random
Dim GotCP As Integer = GetCP.Next(1, 51)
ChangeCP(True, GotCP)
Case 100 To 999
Dim GetCP As New Random
Dim GotCP As Integer = GetCP.Next(1, 501)
ChangeCP(True, GotCP)
Case 1000 To 9999
Dim GetCP As New Random
Dim GotCP As Integer = GetCP.Next(1, 5001)
ChangeCP(True, GotCP)
End Select
End Sub
Public Sub ShiftoriumFX_DisplayPackages() Public Sub ShiftoriumFX_DisplayPackages()
Terminal.TextBox1.Text = "Shiftorium FX!" & Environment.NewLine & "The place to shiftisize the ShiftOS" & Environment.NewLine & Environment.NewLine & "Available Package(s)" Terminal.TextBox1.Text = "Shiftorium FX!" & Environment.NewLine & "The place to shiftisize the ShiftOS" & Environment.NewLine & Environment.NewLine & "Available Package(s)"
Shiftorium_ListFeatures() Shiftorium_ListFeatures()