介绍
Type Control
Get more control over your data in minecraft!
Note about how types are named in this
str A standard string
char A standard string, with length 1
func A standard string, represents a function
object A map like / JSON object
array An array
ANY Can be anything
null nothing
bool either an int of value 1 or 0, or true or false (depends on context)
Functions
Strings
Loop
Loops through each character in a string
Returns null
Parameters
string: str | The string to loop throughfunction: func | the function to be runargs: object | Any additional parameters to be passed to the function
The function that is run on each charachter in the string is passed the following parameters:
char: char | The current charachter of the stringARGS: ANY | Any arguments passed in through theargsparameter, unpacked into direct arguments
Split
Splits a string into a list by a specified character
Returns array | outputs to a storage
Parameters
string: str | The string to be splitchar: char | The character to split the string atnamespace: str | The namespace of the storage to output topath: str | The path of the storage to output to
Concatenate
concatenates 2 strings
Returns str | outputs to a storage
Parameters
string1: str | The string to be concatenated ontostring2: str | The string to be concatenated to the end ofstring1namespace: str | The namespace of the storage to output topath: str | The path of the storage to output to
Compare
Compares 2 strings
Returns bool | direct return
Parameters
string1: str | The first string to be comparedstring2: str | The second string to be compared
Arrays
Loop
Loops through each element in an array
Returns null
Parameters
array: array | The array to loop throughfunction: func | the function to be runargs: object | Any additional parameters to be passed to the function
The function that is run on each charachter in the string is passed the following parameters:
element: ANY | The current element of the arrayARGS: ANY | Any arguments passed in through theargsparameter, unpacked into direct arguments
Concatenate
Concatenates an array into a string
Returns str | outputs to a storage
Parameters
array: array | The array to be concatenatednamespace: str | The namespace of the storage to output topath: str | The path of the storage to output to
常见问题
Type Control 支持哪些 Minecraft 版本?
Type Control 支持 Minecraft Java 版 1.21.6–1.21.8,共 3 个版本。下载时注意选择和你游戏版本一致的文件。
Type Control 怎么安装?
新建世界时在「数据包」里把下载的 .zip 拖进去;已有的存档,把文件放进存档目录下的 datapacks 文件夹,进游戏输入 /reload 即可生效。服务器同样放在世界目录的 datapacks 里。
SmoothTurtle872 的其他作品
查看全部 →
Maths
Adds some mathematical functions to minecraft
Waystones Datapack
A vannila waystones system
Bossbar Lib
A simple bossbar library allowing for per entity bossbars
Armorstand Commands
Add Commands To Armorsatnds!
评论
登录后评论和评分