Difference between revisions of "User:AdminSR1/Scripting Protecting Plug-in Files"

Jump to navigation Jump to search
imported>CraftySentinel
(Created page with "Category:Scripting_Guides This script will allow you to only allow access to an esp plug-in file if requirements are met. ==Usage== There are many reasons why you may wan...")
 
imported>CraftySentinel
Line 21: Line 21:
The first part of the script uses the <u>Group Function</u>. This is used to group properties together and make a cleaner look to the script. Note that groups, like other functions have to be ended using EndGroup. Group Functions can be named which is what is after the word Group, the first group is named Reqiured_Properties. Group names can not have spaces so underscores will have to do. Once a group has been created, script properties can be put inside them. Using {} underneath either a group or a property will allow you to add a note so that you can refer back to it later.
The first part of the script uses the <u>Group Function</u>. This is used to group properties together and make a cleaner look to the script. Note that groups, like other functions have to be ended using EndGroup. Group Functions can be named which is what is after the word Group, the first group is named Reqiured_Properties. Group names can not have spaces so underscores will have to do. Once a group has been created, script properties can be put inside them. Using {} underneath either a group or a property will allow you to add a note so that you can refer back to it later.


The next part of the script after all properties have been declaired is the Requirements Section, which is where you can define what should be true, or even false in this case. We are using Game.GetPluginInstalled() to check if a plugin is installed and enabled in the players game. If so a message will be showed.
The next part of the script after all properties have been declaired is the Requirements Section, which is where you can define what should be true, or even false in this case. We are using Game.IsPluginInstalled() to check if a plugin is installed and enabled in the players game. If so a message will be showed.


The Self.Reset() and Self.Stop() Functions are part of the Quest scripting and stop and restart the quest so that the message will be displayed if the player go to the menu and loads the game again.
The Self.Reset() and Self.Stop() Functions are part of the Quest scripting and stop and restart the quest so that the message will be displayed if the player go to the menu and loads the game again.

Navigation menu