mirror of
https://github.com/Suiranoil/SkinRestorer.git
synced 2026-01-16 04:42:12 +00:00
rename skin_name parameter to username
This commit is contained in:
@@ -18,11 +18,11 @@ offline/insecure mode.
|
||||
### Set Mojang Skin
|
||||
|
||||
```
|
||||
/skin set mojang <skin_name> [<targets>]
|
||||
/skin set mojang <username> [<targets>]
|
||||
```
|
||||
|
||||
- **Parameters:**
|
||||
- `<skin_name>`: Minecraft account name to fetch the skin from.
|
||||
- `<username>`: Minecraft account name to fetch the skin from.
|
||||
- `[<targets>]`: (Optional, server operators only) Player(s) to apply the skin to.
|
||||
|
||||
### Set Web Skin
|
||||
|
||||
@@ -19,7 +19,7 @@ public class MojangSkinProvider implements SkinProvider {
|
||||
|
||||
@Override
|
||||
public String getArgumentName() {
|
||||
return "skin_name";
|
||||
return "username";
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -28,9 +28,9 @@ public class MojangSkinProvider implements SkinProvider {
|
||||
}
|
||||
|
||||
@Override
|
||||
public SkinResult getSkin(String name, SkinVariant variant) {
|
||||
public SkinResult getSkin(String username, SkinVariant variant) {
|
||||
try {
|
||||
UUID uuid = getUUID(name);
|
||||
UUID uuid = getUUID(username);
|
||||
JsonObject texture = JsonUtils.parseJson(WebUtils.GETRequest(new URL(SESSION_SERVER + uuid + "?unsigned=false")))
|
||||
.getAsJsonArray("properties").get(0).getAsJsonObject();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user