Skip to content

Commit

Permalink
Readme
Browse files Browse the repository at this point in the history
  • Loading branch information
xap3y committed Jun 7, 2024
1 parent b3fa723 commit 869800b
Showing 1 changed file with 76 additions and 0 deletions.
76 changes: 76 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# SkullCreator

## Fork of [SkullCreator](https://github.com/deanveloper/SkullCreator) with extra stuff

The only difference is that it is written in Kotlin, and allows you to get <br>
head from name or UUID online (using MojangAPI)

## Download

<details>
<summary>Maven</summary>

First, add JitPack to your repositories

```xml
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
```

Then add this as dependency

```xml
<dependency>
<groupId>com.github.xap3y</groupId>
<artifactId>SkullCreator</artifactId>
<version>b3fa7232c18f71b9d5e105aa68087f3b8efcbd50</version>
<scope>compile</scope>
</dependency>
```

</details>


<details>
<summary>Gradle</summary>

#### Soon!

</details>

## Usage

> [!NOTE]\
> Same as the original [SkullCreator](https://github.com/deanveloper/SkullCreator) only except the new stuff below

### By Name (Online)

`SkullCreator.itemFromNameOnline("XAP3Y")` returning `CompletableFuture<ItemStack>` <br>

#### Example (Kotlin)
```kotlin
SkullCreator.itemFromNameOnline("XAP3Y").whenComplete { item, _ ->
player.inventory.addItem(item)
}
```

### By UUID (Online)

The argument has to be UUID in string. It doesn't matter if you put the UUID with dashed or not <br>
`SkullCreator.itemFromUuidOnline("f1c3931e93d341258fdc9b1dc39bc4d6")` <br>
which also returns `CompletableFuture<ItemStack>`

#### Example (Kotlin)
```kotlin
SkullCreator.itemFromUuidOnline("f1c3931e93d341258fdc9b1dc39bc4d6").whenComplete { item, _ ->
player.inventory.addItem(item)
}
```





0 comments on commit 869800b

Please sign in to comment.