| This page is under a major revamp. With this change, the syntax of the template is much cleaner and friendly.
The info have been rearranged in such a way that it will not confuse you too much.
Please allow sometime about a minimum of a week for the upgrade to be done. If you are dependent on this documentation, I sincerely apologize for the inconvenience caused.
If you need in-depth info, you can always approach me @jianmingyong in the P3D forum.
|
|
Version 2 scripts were started in version 0.32. Any script in Version 2 must have "version=2" as the first line of the script.
Commands are written as @command.subcommand and are no longer case sensitive. All commands require a subcommand.
Constructs are written as <construct.subconstruct> and can be used basically everywhere.
A General Note to all GameMode Scripters ( Must Read )
- This list is currently updated as of v0.52.1 Script Library found in game.
- This list is the same as what you can see when typing @help(command).
- If you are a GameMode Scripter or trying to be one, you are recommended to download Notepad++ with our special syntax highlighter for checking typo mistake.
- If you find that any command you found here doesn't work the way you want it to be, it might be a bug. Try report it over here.
Make sure that your title include the game version and state clearly what you are trying to do.
- The line number shown in the crash logs starts counting after version=2. Empty lines are ignored hence only each line contains words are taken into consideration.
Important info / definition of certain things before we get started.
By Default, the Argument Types are:
- Str ( Str are define as letters or symbols )
- Int ( Int are define as Integer numbers )
- Sng ( Sng are define as Real numbers )
- ItemCollection ( ItemCollection are define as {itemID|amount|price} )
- Bool ( Bool are define as words such as True, False )
- IntArr ( IntArr are define as an array of Integer numbers )
- StrArr ( StrArr are define as an array of letters or symbols )
- SngArr ( SngArr are define as an array of Real numbers )
- BoolArr ( BoolArr are define as an array of words such as True, False )
- PokemonData ( PokemonData are define as Pokemon Code )
- Arr ( Arr are define as an array of something. )
For any Optional Argument, it will be underlined and in red colour for example "Str1,Str2,Str3,..."
For any Array Argument, it will be surrounded by a grouped square bracket for example "[Str1,Int2,Int3,Int4,Int5],Int6..."
Commands
Commands are scripts that tells the game what to do. It comes with @ and usually used with switches.
The table below is split into sections by Command.
You may use the sort feature to make it list according to alphanumeric order.
@Battle
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Battle.starttrainer(Str1)
|
Initializes a trainer interaction and checks if the player has already beaten that trainer.
|
Str1 = trainerFile The relative file path of the Trainer File without extension. (Pokemon\Scripts\trainer\xxx)
|
| @Battle.trainer(Str1)
|
Initializes a trainer battle.
|
Str1 = trainerFile The relative file path of the Trainer File without extension. (Pokemon\Scripts\trainer\xxx)
|
@Battle.wild(PokemonData1,Str1) @Battle.wild(Int1,Int2,Int3,Str1,Int4)
|
Initializes the battle with a wild Pokémon.
|
PokemonData1 = pokemonData The Pokémon Code. Str1 = musicloop The file name of the Music File without extension. (Pokemon\Content\Songs\xxx)
Int1 = pokemonID The Pokémon national dex number. Int2 = level The Pokémon Level. Int3 = shiny -1 = Random, 0 = Not shiny, 1 = Always shiny. [Default value: -1] Str1 = musicloop The file name of the Music File without extension. (Pokemon\Content\Songs\xxx) Int4 = introtype 0 = Black Checker Boxes, 1 = Black Horizontal Lines, 2 = Black Vertical Lines, 3 = Black Box Expand out, 4 = Black Box Expand in, 5 = White Checker Boxes, 6 = White Horizontal Lines, 7 = White Vertical Lines, 8 = White Box Expand out, 9 = White Box Expand in, 10-11 = Not useable, 12 = Blur Zoom in effect [Default value: 0-10]
|
| @Battle.setvar(Str1,Str2)
|
Sets a battle value.
|
Str1 = varName The variables are canrun, cancatch, canblackout, canreceiveexp, canuseitems, frontiertrainer, divebattle, inversebattle, custombattlemusic and hiddenabilitychance. Str2 = varValue The value for the variable. Usually it is a Boolean. custombattlemusic is string, frontiertrainer and hiddenabilitychance is integer.
|
| @Battle.resetvars
|
Reset all battle value.
|
|
|
@Camera
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Camera.set(Sng1,Sng2,Sng3,Sng4,Sng5)
|
Sets the given properties of the camera.
|
Sng1 = x x coordinate of the object. ~ for player position. Sng2 = y y coordinate of the object. ~ for player position. Sng3 = z z coordinate of the object. ~ for player position. Sng4 = yaw The direction of the object in terms of left and right. Sng5 = pitch The direction of the object in terms of up and down. For pitch in terms of sound, refer this for more detail
|
| @Camera.reset
|
Resets the camera to the default setting.
|
|
| @Camera.setyaw(Sng1)
|
Sets the Yaw property of the camera.
|
Sng1 = yaw The direction of the object in terms of left and right.
|
| @Camera.setpitch(Sng1)
|
Sets the Pitch property of the camera.
|
Sng1 = pitch The direction of the object in terms of up and down. For pitch in terms of sound, refer this for more detail
|
| @Camera.setposition(Sng1,Sng2,Sng3)
|
Sets the Position property of the camera.
|
Sng1 = x x coordinate of the object. ~ for player position. Sng2 = y y coordinate of the object. ~ for player position. Sng3 = z z coordinate of the object. ~ for player position.
|
| @Camera.setx(Sng1)
|
Sets the X Position property of the camera.
|
Sng1 = x x coordinate of the object. ~ for player position.
|
| @Camera.sety(Sng1)
|
Sets the Y Position property of the camera.
|
Sng1 = y y coordinate of the object. ~ for player position.
|
| @Camera.setz(Sng1)
|
Sets the Z Position property of the camera.
|
Sng1 = z z coordinate of the object. ~ for player position.
|
| @Camera.togglethirdperson
|
Toggles the third person camera.
|
|
| @Camera.activatethirdperson
|
Activates the third person camera.
|
|
| @Camera.deactivatethirdperson
|
Deactivates the third person camera.
|
|
| @Camera.fix
|
Fixes the camera to the current position.
|
|
| @Camera.defix
|
Defixes the camera so that it clips behind the player again.
|
|
| @Camera.togglefix
|
Sets the fix state of the camera to the opposite of the current state.
|
|
|
@Chat
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Chat.clear
|
Clears the chat.
|
|
|
@Daycare
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Daycare.takeegg(Int1)
|
Removes the egg from the daycare and adds it to the player's party.
|
Int1 = daycareID ID of the Daycare you are referring to.
|
| @Daycare.takepokemon(Int1,Int2)
|
Takes a Pokémon from the daycare to the player's party.
|
Int1 = daycareID ID of the Daycare you are referring to. Int2 = pokemonIndex The index of the Pokémon. First Pokémon start from zero.
|
| @Daycare.leavepokemon(Int1,Int2,Int3)
|
Removes a Pokémon from the player's party and fills the given PokemonDaycareIndex with that Pokémon.
|
Int1 = daycareID ID of the Daycare you are referring to. Int2 = PokemonDaycareIndex Daycare slot for Pokémon to be stored in. Int3 = pokemonIndex The index of the Pokémon. First Pokémon start from zero.
|
| @Daycare.removeegg(Int1)
|
Removes the egg from the daycare.
|
Int1 = daycareID ID of the Daycare you are referring to.
|
| @Daycare.clean(Int1)
|
Cleans all data for the given daycare. This doesn't remove the data, just rearranges it.
|
Int1 = daycareID ID of the Daycare you are referring to.
|
| @Daycare.call(Int1)
|
Initializes a call with the daycare. This checks if the daycare is registered in the Pokégear.
|
Int1 = daycareID ID of the Daycare you are referring to.
|
| @Daycare.cleardata(Int1)
|
Clears all the data for one daycare. That includes the Pokémon stored there and a potetial egg.
|
Int1 = daycareID ID of the Daycare you are referring to.
|
|
@Entity
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Entity.showmessagebulb(Int1|Sng1|Sng2|Sng3)
|
Displays a message bulb in the world.
|
Int1 = bulbID ID of the message Bulb. ( 0 = Waiting, 1= Exclamation, 2 = Shouting, 3 = Question, 4 = Note, 5 = Heart, 6 = Unhappy, 7 = Happy, 8 = Friendly, 9 = Poisoned, 10 = Battle, 11 = Wink, 12 = AFK, 13 = Angry, 14 = CatFace, 15 = Unsure ) Sng1 = x x coordinate of the object. ~ for player position. Sng2 = y y coordinate of the object. ~ for player position. Sng3 = z z coordinate of the object. ~ for player position.
|
| @Entity.warp(Int1,Sng1,Sng2,Sng3)
|
Warps the entity to a new location on the map.
|
Int1 = entityID ID of the Entity you are referring to. Sng1 = x x coordinate of the object. ~ for player position. Sng2 = y y coordinate of the object. ~ for player position. Sng3 = z z coordinate of the object. ~ for player position.
|
| @Entity.scale
|
|
|
| @Entity.remove
|
|
|
| @Entity.setid
|
|
|
| @Entity.setopacity
|
|
|
| @Entity.setvisible
|
|
|
| @Entity.setadditionalvalue
|
|
|
| @Entity.setcollision
|
|
|
| @Entity.settetxure
|
|
|
| @Entity.addtoposition
|
|
|
|
@Environment
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Environment.setweather
|
|
|
| @Environment.setregionweather
|
|
|
| @Environment.setcanfly
|
|
|
| @Environment.setcandig
|
|
|
| @Environment.setcanteleport
|
|
|
| @Environment.setwildpokemongrass
|
|
|
| @Environment.setwildpokemonwater
|
|
|
| @Environment.setwildpokemoneverywhere
|
|
|
| @Environment.setisdark
|
|
|
| @Environment.setrenderdistance
|
|
|
| @Environment.toggledarkness
|
|
|
|
@Item
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Item.give
|
|
|
| @Item.remove
|
|
|
| @Item.clearitem
|
|
|
| @Item.messagegive
|
|
|
| @Item.repel
|
|
|
|
@Level
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Level.wait
|
|
|
| @Level.update
|
|
|
| @Level.waitforevents
|
|
|
| @Level.waitforsave
|
|
|
| @Level.reload
|
|
|
| @Level.setsafari
|
|
|
|
@Music
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Music.play
|
|
|
| @Music.setmusicloop
|
|
|
| @Music.stop
|
|
|
| @Music.pause
|
|
|
| @Music.resume
|
|
|
|
@NPC
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @NPC.remove
|
|
|
| @NPC.position
|
|
|
| @NPC.warp
|
|
|
| @NPC.addtoposition
|
|
|
| @NPC.register
|
|
|
| @NPC.unregister
|
|
|
| @NPC.wearskin
|
|
|
| @NPC.move
|
|
|
| @NPC.setMoveY
|
|
|
| @NPC.moveasync
|
|
|
| @NPC.turn
|
|
|
| @NPC.spawn
|
|
|
| @NPC.setspeed
|
|
|
|
@Options
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Options.show
|
|
|
| @Options.setcancelindex
|
|
|
|
@Player
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Player.receivepokedex
|
|
|
| @Player.receivepokegear
|
|
|
| @Player.renamerivel
|
|
|
| @Player.wearskin
|
|
|
| @Player.setonlineskin
|
|
|
| @Player.move
|
|
|
| @Player.moveasync
|
|
|
| @Player.turn
|
|
|
| @Player.turnasync
|
|
|
| @Player.turnto
|
|
|
| @Player.turntoasync
|
|
|
| @Player.warp
|
|
|
| @Player.stopmovement
|
|
|
| @Player.addmoney
|
|
|
| @Player.money
|
|
|
| @Player.setmovement
|
|
|
| @Player.resetmovement
|
|
|
| @Player.getbadge
|
|
|
| @Player.achieveemblem
|
|
|
| @Player.addbp
|
|
|
| @Player.showrod
|
|
|
| @Player.hiderod
|
|
|
| @Player.showpokemonfollow
|
|
|
| @Player.hidepokemonfollow
|
|
|
| @Player.togglepokemonfollow
|
|
|
| @Player.save
|
|
|
| @Player.setrivalname
|
|
|
|
@Pokedex
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Pokedex.setautodetect
|
|
|
|
@Pokemon
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @pokemon.cry
|
|
|
| @pokemon.remove
|
|
|
| @pokemon.add
|
|
|
| @pokemon.add
|
|
|
| @pokemon.setadditionalvalue
|
|
|
| @pokemon.setadditionaldata
|
|
|
| @pokemon.setnickname
|
|
|
| @pokemon.setstat
|
|
|
| @pokemon.clear
|
|
|
| @pokemon.removeattack
|
|
|
| @pokemon.clearattacks
|
|
|
| @pokemon.addattack
|
|
|
| @pokemon.setshiny
|
|
|
| @pokemon.changelevel
|
|
|
| @pokemon.gainexp
|
|
|
| @pokemon.setnature
|
|
|
| @pokemon.npcTrade
|
|
genderID: 0-2
|
|
@Radio
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Radio.allowchannel
|
|
|
| @Radio.blockchannel
|
|
|
|
@Register
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Register.register
|
|
|
| @Register.unregister
|
|
|
| @Register.registertime
|
|
|
|
@Screen
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Screen.storagesystem
|
|
|
| @Screen.apricornkurt
|
|
|
| @Screen.trade
|
|
|
| @Screen.townmap
|
|
|
| @Screen.donation
|
|
|
| @Screen.blackout
|
|
|
| @Screen.fadein
|
|
|
| @Screen.fadeout
|
|
|
| @Screen.credits
|
|
|
| @Screen.halloffame
|
|
|
| @Screen.teachmoves
|
|
|
| @Screen.mailsystem
|
|
|
| @Screen.pvp
|
|
|
| @Screen.input
|
|
|
| @Screen.mysteryevent
|
|
|
| @Screen.showPokemon
|
|
|
|
@Script
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Script.start
|
|
|
| @Script.text
|
|
|
| @Script.run
|
|
|
|
@Sound
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Sound.play
|
|
|
| @Sound.playadvanced
|
|
|
|
@Storage
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Storage.set
|
|
|
| @Storage.clear
|
|
|
| @Storage.update
|
|
|
|
@Text
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Text.show
|
|
|
| @Text.setfont
|
|
|
| @Text.debug
|
|
|
| @Text.log
|
|
|
|
@Title
| Command [@Command.Subcommand(Argument Types)]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Title.add
|
|
|
| @Title.clear
|
|
|
|
Constructs
Constructs are script that return a specific values in game. It is used with commands or switches.
They can even be used in trainer files. Constructs always have a subconstruct. All combinations will be listed below.
Constructs that return numbers such as <Pokemon.level(int)> may be used in mathematical functions including:
+: Addition
-: Subtraction
/: Division
*: Multiplication
^: Exponent
%: Percent
=: Equals
>: Greater Than
<: Less Than
m: Mod (ex. 25m4=1)
r: Root(ex. 27r3=3)
The table is split into sections by Construct.
Battle
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| <Battle.defeatmessage(Str1)>
|
Returns the defeat message of the trainer loaded from the given "trainerFile".
|
Str1 = trainerFile The relative file path of the Trainer File without extension. (Pokemon\Scripts\trainer\xxx)
|
| <Battle.intromessage(Str1)>
|
Returns the intro message of the trainer loaded from the given "trainerFile".
|
Str1 = trainerFile The relative file path of the Trainer File without extension. (Pokemon\Scripts\trainer\xxx)
|
| <Battle.outromessage(Str1)>
|
Returns the outro message of the trainer loaded from the given "trainerFile".
|
Str1 = trainerFile The relative file path of the Trainer File without extension. (Pokemon\Scripts\trainer\xxx)
|
| <Battle.won>
|
Returns "true" if the player won the last battle. Returns "false" otherwise.
|
|
|
Camera
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| <Camera.isfixed>
|
Returns if the camera is fixed to a specific position.
|
|
| <Camera.x>
|
Returns the current X position of the camera.
|
|
| <Camera.y>
|
Returns the current Y position of the camera.
|
|
| <Camera.z>
|
Returns the current Z position of the camera.
|
|
|
Daycare
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| <Daycare.pokemonID(Int1,Int2)>
|
Returns the Pokémon ID of a Pokémon in the daycare.
|
Int1 = daycareID ID of the Daycare you are referring to. Int2 = pokemonIndex The index of the Pokémon. First Pokémon start from zero.
|
| <Daycare.pokemonName(Int1,Int2)>
|
Returns the name of a Pokémon in the daycare.
|
Int1 = daycareID ID of the Daycare you are referring to. Int2 = pokemonIndex The index of the Pokémon. First Pokémon start from zero.
|
| <Daycare.pokemonSprite(Int1,Int2)>
|
Returns the sprite of a Pokémon in the daycare.
|
Int1 = daycareID ID of the Daycare you are referring to. Int2 = pokemonIndex The index of the Pokémon. First Pokémon start from zero.
|
| @Daycare.shinyIndicator
|
|
|
| @Daycare.countpokemon
|
|
|
| @Daycare.haspokemon
|
|
|
| @Daycare.canswim
|
|
|
| @Daycare.hasegg
|
|
|
| @Daycare.grownlevels
|
|
|
| @Daycare.currentlevel
|
|
|
| @Daycare.canbreed
|
|
|
|
Entity
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Entity.visible
|
|
|
| @Entity.opacity
|
|
|
| @Entity.position
|
|
|
| @Entity.positionx
|
|
|
| @Entity.positiony
|
|
|
| @Entity.positionz
|
|
|
| @Entity.scale
|
|
|
| @Entity.additionalvalue
|
|
|
| @Entity.collision
|
|
|
|
Environment
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @environment.daytime
|
|
|
| @environment.daytimeID
|
|
|
| @environment.season
|
|
|
| @environment.seasonID
|
|
|
| @environment.day
|
|
|
| @environment.dayofyear
|
|
|
| @environment.dayinformation
|
|
|
| @environment.week
|
|
|
| @environment.year
|
|
|
| @environment.weather
|
|
|
| @environment.mapweather
|
|
|
| @environment.currentmapweather
|
|
|
| @environment.weatherid
|
|
|
| @environment.mapweatherid
|
|
|
| @environment.currentmapweatherid
|
|
|
| @environment.regionweather
|
|
|
| @environment.regionweatherid
|
|
|
| @environment.canfly
|
|
|
| @environment.candig
|
|
|
| @environment.canteleport
|
|
|
| @environment.wildpokemongrass
|
|
|
| @environment.wildpokemonwater
|
|
|
| @environment.wildpokemoneverywhere
|
|
|
| @environment.isdark
|
|
|
|
Inventory
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @inventory.countitem
|
|
|
| @inventory.countitems
|
|
|
| @inventory.name
|
|
|
| @inventory.ID
|
|
|
|
Level
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @level.mapfile
|
|
|
| @level.levelfile
|
|
|
| @level.filename
|
|
|
| @level.riding
|
|
|
| @level.surfing
|
|
|
|
Math
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @math.int
|
|
|
| @math.sng
|
|
|
| @math.abs
|
|
|
| @math.ceiling
|
|
|
| @math.floor
|
|
|
| @math.isint
|
|
|
| @math.issng
|
|
|
|
NPC
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @npc.position
|
|
|
| @npc.exists
|
|
|
| @npc.ismoving
|
|
|
| @npc.moved
|
|
|
| @npc.skin
|
|
|
| @npc.facing
|
|
|
| @npc.ID
|
|
|
| @npc.name
|
|
|
| @npc.action
|
|
|
| @npc.additionalvalue
|
|
|
| @npc.movement
|
|
|
| @npc.hasmoverectangles
|
|
|
| @npc.trainertexture
|
|
|
|
Phone
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @phone.callflag
|
|
|
| @phone.got
|
|
|
|
Player
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @player.position
|
|
|
| @player.hasbadge
|
|
|
| @player.skin
|
|
|
| @player.velocity
|
|
|
| @player.ismoving
|
|
|
| @player.facing
|
|
|
| @player.compass
|
|
|
| @player.money
|
|
|
| @player.name
|
|
|
| @player.gender
|
|
|
| @player.bp
|
|
|
| @player.badges
|
|
|
| @player.thirdperson
|
|
|
| @player.rival
|
|
|
| @player.rivalname
|
|
|
| @player.ot
|
|
|
| @player.gamejoltid
|
|
|
|
Pokedex
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @pokedex.caught
|
|
|
| @pokedex.seen
|
|
|
| @pokedex.shiny
|
|
|
|
Pokemon
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @pokemon.id
|
|
|
| @pokemon.number
|
|
|
| @pokemon.data
|
|
|
| @pokemon.level
|
|
|
| @pokemon.hasfullhp
|
|
|
| @pokemon.hp
|
|
|
| @pokemon.atk
|
|
|
| @pokemon.def
|
|
|
| @pokemon.spatk
|
|
|
| @pokemon.spdef
|
|
|
| @pokemon.speed
|
|
|
| @pokemon.maxhp
|
|
|
| @pokemon.isegg
|
|
|
| @pokemon.additionaldata
|
|
|
| @pokemon.nickname
|
|
|
| @pokemon.name
|
|
|
| @pokemon.ot
|
|
|
| @pokemon.trainer
|
|
|
| @pokemon.itemid
|
|
|
| @pokemon.friendship
|
|
|
| @pokemon.itemname
|
|
|
| @pokemon.catchball
|
|
|
| @pokemon.catchmethod
|
|
|
| @pokemon.catchlocation
|
|
|
| @pokemon.hasattack
|
|
|
| @pokemon.countattacks
|
|
|
| @pokemon.attackname
|
|
|
| @pokemon.isShiny
|
|
|
| @pokemon.nature
|
|
|
| @pokemon.ownpokemon
|
|
|
| @pokemon.islegendary
|
|
|
| @pokemon.freeplaceinparty
|
|
|
| @pokemon.nopokemon
|
|
|
| @pokemon.count
|
|
|
| @pokemon.countbattle
|
|
|
| @pokemon.has
|
|
|
| @pokemon.selected
|
|
|
| @pokemon.selectedmove
|
|
|
| @pokemon.hasegg
|
|
|
| @pokemon.maxpartylevel
|
|
|
| @pokemon.evhp
|
|
|
| @pokemon.evatk
|
|
|
| @pokemon.evdef
|
|
|
| @pokemon.evspatk
|
|
|
| @pokemon.evspdef
|
|
|
| @pokemon.evspeed
|
|
|
| @pokemon.ivhp
|
|
|
| @pokemon.ivatk
|
|
|
| @pokemon.ivdef
|
|
|
| @pokemon.ivspatk
|
|
|
| @pokemon.ivspdef
|
|
|
| @pokemon.spawnwild
|
|
|
| @pokemon.itemdata
|
|
|
| @pokemon.countHallofFame
|
|
|
| @pokemon.learnedTutorMove
|
|
|
| @pokemon.totalexp
|
|
|
| @pokemon.needexp
|
|
|
| @pokemon.currentexp
|
|
|
| @pokemon.generateFrontier
|
|
|
| @pokemon.spawnwild
|
|
|
| @pokemon.spawn
|
|
|
| @pokemon.OTmatch
|
|
|
| @pokemon.randomOT
|
|
|
| @pokemon.status
|
|
|
| @pokemon.canevolve
|
|
|
| @pokemon.type1
|
|
|
| @pokemon.type2
|
|
|
| @pokemon.istype
|
|
|
|
Radio
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @radio.currentchannel
|
|
|
|
Register
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @register.registered
|
|
|
| @register.count
|
|
|
| @register.type
|
|
|
| @register.value
|
|
|
|
Rival
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @Rival.name
|
|
|
|
Storage
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @storage.get
|
|
|
| @storage.count
|
|
|
|
System
| Construct [<Construct.SubConstruct(Argument Types)>]
|
Description
|
Inputs [Argument Types = Argument Name]
|
| @system.random
|
|
|
| @system.unixtimestamp
|
|
|
| @system.dayofyear
|
|
|
| @system.year
|
|
|
| @system.booltoint
|
|
|
| @system.calcint
|
|
|
| @system.int
|
|
|
| @system.calcsng
|
|
|
| @system.sng
|
|
|
| @system.sort
|
|
|
| @system.isinsightscript
|
|
|
| @system.lastinput
|
|
|
| @system.return
|
|
|
| @system.isint
|
|
|
| @system.issng
|
|
|
| @system.chrw
|
|
|
|
Switches
Switches do a comparison between a given parameter and a construct.
:if:
If you want to make the script run by certain condition, :if: will do the job.
Typical Usage:
:if:Conditions
@Command.Subcommand(Argument Types)
:endif
:if:Conditions
@Command.Subcommand(Argument Types)
:else
@Command.Subcommand(Argument Types)
:endif
Conditions
There are some valid condition that you can use.
The script will run if a value that returns from the constructs match the value given.
<Construct.SubConstruct(Argument Types)>=value
<Construct.SubConstruct(Argument Types)>>value
<Construct.SubConstruct(Argument Types)><value
The script will run if a value that returns from the constructs does not match the value given.
<not><Construct.SubConstruct(Argument Types)>=value
<not><Construct.SubConstruct(Argument Types)>>value
<not><Construct.SubConstruct(Argument Types)><value
The script will run if two or more value that returns from the constructs match the value given.
<Construct.SubConstruct(Argument Types)>=value <and> <Construct.SubConstruct(Argument Types)>>value <and> <Construct.SubConstruct(Argument Types)><value
The script will run if at least one value that returns from the constructs match the value given.
<Construct.SubConstruct(Argument Types)>=value <or> <Construct.SubConstruct(Argument Types)>>value <or> <Construct.SubConstruct(Argument Types)><value
FAQ:
1. Can I use <and> and <or> at the same line? (E.g: <Construct.SubConstruct(Argument Types)>=value <or> <Construct.SubConstruct(Argument Types)>=value <and> <Construct.SubConstruct(Argument Types)>=value )
Ans: No. This is because the script does not support it. Also, the script will not understand what condition you are trying to say so I recommend to start a new :if: switches so that it will work the way you want it to be.
2. Can I use <not> with <and> or <or> at the same line? (E.g: <not><Construct.SubConstruct(Argument Types)>=value <or> <Construct.SubConstruct(Argument Types)>=value )
Ans: Yes. The script will be able to handle this.
3. Why it didn't work? Why it skip the condition defined?
Ans: This is probably your own typo mistake. If you are sure that it isn't report the bug.
:select:
If you want to make the script run by selecting certain condition, :select: will do the job.
Typical Usage:
:select:<Construct.SubConstruct(Argument Types)>
:when:Value
@Command.Subcommand(Argument Types)
:endwhen
Value
This field is to define the possible value that the construct given so that the script will run when condition is met.
Define the possible values that the construct will return.
:when:value1
...
:when:value2
...
:when:valuei
If you want to have multiple value as you intended to let them do the same thing, you can use " ; "
:when:value1;value2;value3...;valuei
...
:when:value1;value2;value3...;valuei
After you define the values in each condition, use " :endwhen " to properly close the :select: switches.
FAQ:
1. Why it didn't work? Why it skip the condition defined?
Ans: This is probably your own typo mistake. If you are sure that it isn't, report the bug.
@options.show()
If you want to let player choose a certain options to choose from, @Options.show() will do the job.
Typical Usage:
@options.show(option1,option2,optioni)
:when:Option1
@Command.Subcommand(Argument Types)
:endwhen
Option
This field is to define the possible option that you define in @options.show() so that the script will run when player choose the options.
Define the possible option that you define in @options.show().
:when:option1
...
:when:option2
...
:when:optioni
If you want to have multiple value as you intended to let them do the same thing, you can use " ; "
:when:option1;option2;optioni
After you define all the options in each condition, use " :endwhen " to properly close the @options.show() switches.
FAQ:
1. Why it didn't work? Why it skip the condition defined?
Ans: This is probably your own typo mistake. If you are sure that it isn't, report the bug.
:while:
If you want to loop a certain command until it met the condition, this will do the job.
Typical Usage:
:while:Conditions
@Command.Subcommand(Argument Types)
...
@Command.Subcommand(Argument Types)
:endwhile
FAQ:
1. How to manually stop the loop when you know that the condition will never be met?
Ans: Insert without quotation marks " :exitwhile " before :endwhile to stop the loop prematurely.
2. How come it didn't loop? How come it stop prematurely despite :exitwhile is not used?
Ans: This is a bug. Unfortunately, if this happens, please ensure that your script is correct before filling a bug report.
3. Can I stack :while: switches?
Ans: No. Nilllzz officially said it is not possible.
:endscript
If you want to stop all script prematurely, this shall do the job.
Typical Usage:
@Command.Subcommand(Argument Types)
...
...
:endscript
FAQ:
1. How come it didn't work?
Ans: Unfortunately, even I myself do not know what is intended for it to work. You might need to ask Nilllzz by creating a new thread in the community support thread.
:return:
More of a script function that return a value.
Typical Usage:
:return:True
:end
Once you use <System.return>, it will return True.
To add some comments in your script like what programmer does, you can use " # " a hash at the start of the line.
Typical Usage:
# This is a comment that says nothing
@Command.Subcommand(Argument Types) # <= Unfortunately, hash at here do not work.
# @Command.Subcommand(Argument Types) <= It will not run this script at all :D
FAQ:
1. Can it support multiple line without keep using # all the time?
Ans: Unfortunately, no.
:end
To end the current running script, this will do ithe job
Typical Usage:
@Command.Subcommand(Argument Types)
:end
Reserved Registers
Reserved Registers are registers that are reserved in the P3D engine and cannot be replaced by other events.
pokegear_card_radio
# Give Player PokéGear Radio
pokegear_card_GTS
# Give Player GTS Card
phone_contact_###
# Add Phone Contact ID ###
pokegear_card_minimap
# Give PokéNav MiniMap Card
pokegear_card_frontier
# Give PokéNav Frontier Emblem Card