mirror of
https://github.com/P3D-Legacy/P3D-Legacy.git
synced 2025-07-27 15:54:25 +02:00
Added pkmn gender constructs + fix hidden grotto
This commit is contained in:
parent
552548b5ad
commit
5747c2f1ce
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -113,6 +113,18 @@
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If StringHelper.IsNumeric(Me.TextureID) = False Then
|
||||||
|
If System.IO.File.Exists(GameController.GamePath & "\" & GameModeManager.ActiveGameMode.ContentPath & texturePath & Me.TextureID & PokemonAddition & ".png") = False Then
|
||||||
|
If Me.TextureID.Contains("_") Then
|
||||||
|
Me.TextureID = Me.TextureID.GetSplit(0, "_")
|
||||||
|
ElseIf Me.TextureID.Contains("-") Then
|
||||||
|
Me.TextureID = Me.TextureID.GetSplit(0, "-")
|
||||||
|
ElseIf Me.TextureID.Contains(";") Then
|
||||||
|
Me.TextureID = Me.TextureID.GetSplit(0, ";")
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
If UseGameJoltID = True And Core.Player.IsGameJoltSave = True And GameJolt.API.LoggedIn = True AndAlso Not GameJolt.Emblem.GetOnlineSprite(GameJoltID) Is Nothing Then
|
If UseGameJoltID = True And Core.Player.IsGameJoltSave = True And GameJolt.API.LoggedIn = True AndAlso Not GameJolt.Emblem.GetOnlineSprite(GameJoltID) Is Nothing Then
|
||||||
Me.Texture = GameJolt.Emblem.GetOnlineSprite(GameJoltID)
|
Me.Texture = GameJolt.Emblem.GetOnlineSprite(GameJoltID)
|
||||||
Else
|
Else
|
||||||
|
@ -128,18 +128,30 @@
|
|||||||
Case 0
|
Case 0
|
||||||
musicLoop = args(i)
|
musicLoop = args(i)
|
||||||
Case 1
|
Case 1
|
||||||
introType = int(args(i))
|
If args(i) <> "" Then
|
||||||
|
introType = int(args(i))
|
||||||
|
End If
|
||||||
End Select
|
End Select
|
||||||
Next
|
Next
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
If argument.Length > 0 Then
|
If argument.Length > 0 Then
|
||||||
Dim ID As Integer = int(argument.GetSplit(0).Split(CChar("_"))(0))
|
Dim ID As Integer
|
||||||
Dim AD As String = ""
|
Dim AD As String = ""
|
||||||
If argument.GetSplit(0).Contains(CChar("_")) Then
|
If argument.GetSplit(0).Contains("-") Then
|
||||||
AD = argument.GetSplit(0).Split(CChar("_"))(1)
|
ID = int(argument.GetSplit(0).GetSplit(0, "-"))
|
||||||
|
ElseIf argument.GetSplit(0).Contains(";") Then
|
||||||
|
ID = int(argument.GetSplit(0).GetSplit(0, ";"))
|
||||||
|
AD = argument.GetSplit(0).GetSplit(1, ";")
|
||||||
|
Else
|
||||||
|
ID = int(argument.GetSplit(0).GetSplit(0, "_"))
|
||||||
|
|
||||||
|
If argument.GetSplit(0).Contains("_") Then
|
||||||
|
AD = PokemonForms.GetAdditionalValueFromDataFile(argument.GetSplit(0))
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim Level As Integer = int(argument.GetSplit(1))
|
Dim Level As Integer = int(argument.GetSplit(1))
|
||||||
|
|
||||||
If AD IsNot "" Then
|
If AD IsNot "" Then
|
||||||
@ -151,7 +163,6 @@
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
Dim args() As String = argument.Split(CChar(","))
|
Dim args() As String = argument.Split(CChar(","))
|
||||||
|
|
||||||
For i = 0 To args.Length - 1
|
For i = 0 To args.Length - 1
|
||||||
@ -163,7 +174,20 @@
|
|||||||
Case 3
|
Case 3
|
||||||
musicLoop = args(i)
|
musicLoop = args(i)
|
||||||
Case 4
|
Case 4
|
||||||
introType = int(args(i))
|
If args(i) <> "" Then
|
||||||
|
introType = int(args(i))
|
||||||
|
End If
|
||||||
|
Case 5
|
||||||
|
If args(i) <> "" Then
|
||||||
|
Select Case int(args(i))
|
||||||
|
Case 0
|
||||||
|
p.Gender = Pokemon.Genders.Male
|
||||||
|
Case 1
|
||||||
|
p.Gender = Pokemon.Genders.Female
|
||||||
|
Case 2
|
||||||
|
p.Gender = Pokemon.Genders.Genderless
|
||||||
|
End Select
|
||||||
|
End If
|
||||||
End Select
|
End Select
|
||||||
Next
|
Next
|
||||||
End If
|
End If
|
||||||
|
@ -17,6 +17,19 @@
|
|||||||
Case "data"
|
Case "data"
|
||||||
Dim index As Integer = int(argument.GetSplit(0))
|
Dim index As Integer = int(argument.GetSplit(0))
|
||||||
Return Core.Player.Pokemons(index).GetSaveData().Replace(",", "§").Replace("[", "«").Replace("]", "»")
|
Return Core.Player.Pokemons(index).GetSaveData().Replace(",", "§").Replace("[", "«").Replace("]", "»")
|
||||||
|
Case "gender"
|
||||||
|
Dim index As Integer = int(argument.GetSplit(0))
|
||||||
|
Return Core.Player.Pokemons(index).Gender
|
||||||
|
Case "genderchance"
|
||||||
|
Dim dexID As String = argument.GetSplit(0)
|
||||||
|
Dim dexAD As String = ""
|
||||||
|
If dexID.Contains("_") = True Then
|
||||||
|
dexAD = PokemonForms.GetAdditionalValueFromDataFile(dexID)
|
||||||
|
dexID = dexID.GetSplit(0, "_")
|
||||||
|
End If
|
||||||
|
Dim p As Pokemon = Pokemon.GetPokemonByID(CInt(dexID), dexAD)
|
||||||
|
|
||||||
|
Return p.IsMale
|
||||||
Case "level"
|
Case "level"
|
||||||
Dim index As Integer = int(argument.GetSplit(0))
|
Dim index As Integer = int(argument.GetSplit(0))
|
||||||
Return Core.Player.Pokemons(index).Level
|
Return Core.Player.Pokemons(index).Level
|
||||||
|
@ -192,7 +192,8 @@ Namespace ScriptVersion2
|
|||||||
New ScriptArgument("level", ScriptArgument.ArgumentTypes.Int),
|
New ScriptArgument("level", ScriptArgument.ArgumentTypes.Int),
|
||||||
New ScriptArgument("shiny", ScriptArgument.ArgumentTypes.Int, True, "-1"),
|
New ScriptArgument("shiny", ScriptArgument.ArgumentTypes.Int, True, "-1"),
|
||||||
New ScriptArgument("musicloop", ScriptArgument.ArgumentTypes.Str, True, ""),
|
New ScriptArgument("musicloop", ScriptArgument.ArgumentTypes.Str, True, ""),
|
||||||
New ScriptArgument("introtype", ScriptArgument.ArgumentTypes.Int, True, "0-10")}.ToList(), "Initializes the battle with a wild Pokémon."))
|
New ScriptArgument("introtype", ScriptArgument.ArgumentTypes.Int, True, "0-10"),
|
||||||
|
New ScriptArgument("gender", ScriptArgument.ArgumentTypes.Int, True, "")}.ToList(), "Initializes the battle with a wild Pokémon."))
|
||||||
r(New ScriptCommand("battle", "setvar", {New ScriptArgument("varName", ScriptArgument.ArgumentTypes.Str, {"canrun", "cancatch", "canblackout", "canreceiveexp", "canuseitems", "frontiertrainer", "divebattle", "inversebattle, custombattlemusic, hiddenabilitychance"}),
|
r(New ScriptCommand("battle", "setvar", {New ScriptArgument("varName", ScriptArgument.ArgumentTypes.Str, {"canrun", "cancatch", "canblackout", "canreceiveexp", "canuseitems", "frontiertrainer", "divebattle", "inversebattle, custombattlemusic, hiddenabilitychance"}),
|
||||||
New ScriptArgument("varValue", ScriptArgument.ArgumentTypes.Str)}.ToList(), "Sets a battle value."))
|
New ScriptArgument("varValue", ScriptArgument.ArgumentTypes.Str)}.ToList(), "Sets a battle value."))
|
||||||
' Constructs:
|
' Constructs:
|
||||||
@ -818,6 +819,8 @@ Namespace ScriptVersion2
|
|||||||
r(New ScriptCommand("pokemon", "id", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the ID of a Pokémon in the player's party.", ",", True))
|
r(New ScriptCommand("pokemon", "id", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the ID of a Pokémon in the player's party.", ",", True))
|
||||||
r(New ScriptCommand("pokemon", "number", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the ID of a Pokémon in the player's party.", ",", True))
|
r(New ScriptCommand("pokemon", "number", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the ID of a Pokémon in the player's party.", ",", True))
|
||||||
r(New ScriptCommand("pokemon", "data", "pokemonData", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the save data for a Pokémon in the player's party.", ",", True))
|
r(New ScriptCommand("pokemon", "data", "pokemonData", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the save data for a Pokémon in the player's party.", ",", True))
|
||||||
|
r(New ScriptCommand("pokemon", "gender", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the gender for a Pokémon in the player's party.", ",", True))
|
||||||
|
r(New ScriptCommand("pokemon", "genderchance", "int", {New ScriptArgument("pokemonID", ScriptArgument.ArgumentTypes.Str)}.ToList(), "Returns the Male/Female chance (1-100) of a Pokémon as defined by its Data file.", ",", True))
|
||||||
r(New ScriptCommand("pokemon", "level", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the level of a Pokémon in the player's party.", ",", True))
|
r(New ScriptCommand("pokemon", "level", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the level of a Pokémon in the player's party.", ",", True))
|
||||||
r(New ScriptCommand("pokemon", "hasfullhp", "bool", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns if a Pokémon in the player's party has a full Hit Point count.", ",", True))
|
r(New ScriptCommand("pokemon", "hasfullhp", "bool", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns if a Pokémon in the player's party has a full Hit Point count.", ",", True))
|
||||||
r(New ScriptCommand("pokemon", "hp", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the Hit Points of a Pokémon in the player's party.", ",", True))
|
r(New ScriptCommand("pokemon", "hp", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the Hit Points of a Pokémon in the player's party.", ",", True))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user