Mail sender name and ot constructs

This commit is contained in:
JappaWakka 2023-07-25 14:11:41 +02:00
parent fdcbdfa62b
commit af2831673e
2 changed files with 20 additions and 0 deletions

View File

@ -246,6 +246,24 @@
data = Core.Player.Pokemons(index).Item.AdditionalData data = Core.Player.Pokemons(index).Item.AdditionalData
End If End If
Return data Return data
Case "mailsendername"
Dim index As Integer = int(argument)
Dim name As String = ""
If Not Core.Player.Pokemons(index).Item Is Nothing Then
If Core.Player.Pokemons(index).Item.IsMail Then
name = Core.Player.Pokemons(index).Item.AdditionalData.GetSplit(1, "\,")
End If
End If
Return name
Case "mailsenderot"
Dim index As Integer = int(argument)
Dim ot As String = ""
If Not Core.Player.Pokemons(index).Item Is Nothing Then
If Core.Player.Pokemons(index).Item.IsMail Then
ot = Core.Player.Pokemons(index).Item.AdditionalData.GetSplit(6, "\,")
End If
End If
Return ot
Case "counthalloffame" Case "counthalloffame"
Return HallOfFameScreen.GetHallOfFameCount() Return HallOfFameScreen.GetHallOfFameCount()
Case "learnedtutormove" Case "learnedtutormove"

View File

@ -823,6 +823,8 @@ Namespace ScriptVersion2
r(New ScriptCommand("pokemon", "maxhp", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the Maximum Hit Points of a Pokémon in the player's party.", ",", True)) r(New ScriptCommand("pokemon", "maxhp", "int", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the Maximum Hit Points of a Pokémon in the player's party.", ",", True))
r(New ScriptCommand("pokemon", "isegg", "bool", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the Pokémon in the players party is an Egg.", ",", True)) r(New ScriptCommand("pokemon", "isegg", "bool", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the Pokémon in the players party is an Egg.", ",", True))
r(New ScriptCommand("pokemon", "additionaldata", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the additional data for the Pokémon in the player's party.", ",", True)) r(New ScriptCommand("pokemon", "additionaldata", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the additional data for the Pokémon in the player's party.", ",", True))
r(New ScriptCommand("pokemon", "mailsendername", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the name of the sender of a mail if there's one on the Pokémon in the player's party.", ",", True))
r(New ScriptCommand("pokemon", "mailsenderot", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the OT of the sender of a mail if there's one on the Pokémon in the player's party.", ",", True))
r(New ScriptCommand("pokemon", "nickname", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the nickname of a Pokémon in the player's party.", ",", True)) r(New ScriptCommand("pokemon", "nickname", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the nickname of a Pokémon in the player's party.", ",", True))
r(New ScriptCommand("pokemon", "hasnickname", "bool", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns if a Pokémon in the player's party has a nickname.", ",", True)) r(New ScriptCommand("pokemon", "hasnickname", "bool", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns if a Pokémon in the player's party has a nickname.", ",", True))
r(New ScriptCommand("pokemon", "name", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the name of a Pokémon in the player's party.", ",", True)) r(New ScriptCommand("pokemon", "name", "str", {New ScriptArgument("pokemonIndex", ScriptArgument.ArgumentTypes.Int)}.ToList(), "Returns the name of a Pokémon in the player's party.", ",", True))