MCResourceLocation
Link to mcresourcelocation
Importing the class
Link to importing-the-class
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.
ZenScript Copyimport crafttweaker.api.util.MCResourceLocation;
Implemented Interfaces
Link to implemented-interfaces
MCResourceLocation implements the following interfaces. That means all methods defined in these interfaces are also available in MCResourceLocation
- Comparable<MCResourceLocation>
Constructors
Link to constructors
ZenScript Copynew MCResourceLocation(namespace as string, path as string) as MCResourceLocation
Parameter | Type | Description |
---|---|---|
Parameter 名前空間 | Type string | Description Usually a ModId |
Parameter path | Type string | Description May only contain lower-cased alphanumeric values, as well as / and _ |
Casters
Link to casters
Result type | Is Implicit |
---|---|
Result type IData | Is Implicit true |
Result type string | Is Implicit true |
Methods
Link to methods
Name: asData
Return Type: IData
ZenScript Copy// MCResourceLocation.asData() as IData
myMCResourceLocation.asData();
Name: compareTo
Return Type: int
ZenScript CopyMCResourceLocation.compareTo(other as MCResourceLocation) as int
Parameter | Type | Description |
---|---|---|
Parameter other | Type MCResourceLocation | Description No Description Provided |
Name: equals
Return Type: boolean
ZenScript CopyMCResourceLocation.equals(other as Object) as boolean
Parameter | Type | Description |
---|---|---|
Parameter other | Type Object | Description No Description Provided |
Name: getNamespace
Return Type: string
ZenScript Copy// MCResourceLocation.getNamespace() as string
myMCResourceLocation.getNamespace();
Name: getPath
Return Type: string
ZenScript Copy// MCResourceLocation.getPath() as string
myMCResourceLocation.getPath();
Name: hashCode
Return Type: int
ZenScript Copy// MCResourceLocation.hashCode() as int
myMCResourceLocation.hashCode();
Name: toString
Return Type: string
ZenScript Copy// MCResourceLocation.toString() as string
myMCResourceLocation.toString();
Properties
Link to properties
名称 | Type | Has Getter | Has Setter | Description |
---|---|---|---|---|
名称 commandString | Type string | Has Getter true | Has Setter false | Description No Description Provided |
名称 名前空間 | Type string | Has Getter true | Has Setter false | Description No Description Provided |
名称 path | Type string | Has Getter true | Has Setter false | Description No Description Provided |