101 lines
2.6 KiB
Markdown
101 lines
2.6 KiB
Markdown
---
|
|
title: Documentation des Plugins Hytale
|
|
layout: hextra-home
|
|
---
|
|
|
|
{{< hextra/hero-badge >}}
|
|
<span>API Serveur Hytale</span>
|
|
{{< /hextra/hero-badge >}}
|
|
|
|
<div class="hx-mt-6 hx-mb-6">
|
|
{{< hextra/hero-headline >}}
|
|
Créez des Plugins pour Hytale
|
|
{{< /hextra/hero-headline >}}
|
|
</div>
|
|
|
|
<div class="hx-mb-12">
|
|
{{< hextra/hero-subtitle >}}
|
|
Documentation complète pour la création de plugins serveur Hytale. <br class="sm:hx-block hx-hidden" />De votre premier plugin aux fonctionnalités avancées.
|
|
{{< /hextra/hero-subtitle >}}
|
|
</div>
|
|
|
|
<div class="hx-mt-6 hx-mb-12"> </div>
|
|
|
|
<div class="hx-mt-12">
|
|
{{< hextra/hero-button text="Rejoindre Discord" link="https://discord.gg/4UPCz84Nst" icon="discord" >}}
|
|
</div>
|
|
|
|
<div class="hx-mt-6 hx-mb-12"> </div>
|
|
|
|
## Explorer la Documentation
|
|
|
|
<div class="hx-mt-6 hx-mb-12"> </div>
|
|
|
|
{{< hextra/feature-grid >}}
|
|
{{< hextra/feature-card
|
|
title="Premiers Pas"
|
|
subtitle="Configurez votre environnement et créez votre premier plugin"
|
|
link="getting-started"
|
|
icon="play"
|
|
>}}
|
|
{{< hextra/feature-card
|
|
title="Concepts de Base"
|
|
subtitle="Registres, assets, codecs, commandes, événements et tâches"
|
|
link="core-concepts"
|
|
icon="cube"
|
|
>}}
|
|
{{< hextra/feature-card
|
|
title="Systèmes de Gameplay"
|
|
subtitle="Farming, boutiques, réputation, mémoires et objectifs"
|
|
link="gameplay-systems"
|
|
icon="puzzle"
|
|
>}}
|
|
{{< hextra/feature-card
|
|
title="Monde"
|
|
subtitle="Univers, chunks, blocs, entités, worldgen et portails"
|
|
link="world"
|
|
icon="globe"
|
|
>}}
|
|
{{< hextra/feature-card
|
|
title="Systèmes UI"
|
|
subtitle="HUD, pages personnalisées, fenêtres, inventaire et permissions"
|
|
link="ui-systems"
|
|
icon="desktop-computer"
|
|
>}}
|
|
{{< hextra/feature-card
|
|
title="Avancé"
|
|
subtitle="Réseau, effets, particules et lumières dynamiques"
|
|
link="advanced"
|
|
icon="lightning-bolt"
|
|
>}}
|
|
{{< hextra/feature-card
|
|
title="Référence"
|
|
subtitle="Référence API, schéma du manifest et registres"
|
|
link="reference"
|
|
icon="book-open"
|
|
>}}
|
|
{{< /hextra/feature-grid >}}
|
|
|
|
<div class="hx-mt-6"> </div>
|
|
|
|
## Exemple Rapide
|
|
|
|
Voici un plugin simple qui affiche un message quand un joueur rejoint :
|
|
|
|
```java
|
|
public class MyPlugin extends JavaPlugin {
|
|
@Override
|
|
public void start() {
|
|
getEventRegistry().register(PlayerConnectEvent.class, event -> {
|
|
PlayerRef playerRef = event.getPlayerRef();
|
|
getLogger().at(Level.INFO).log("Joueur en connexion : " + playerRef.getUsername());
|
|
});
|
|
}
|
|
|
|
@Override
|
|
public void shutdown() {
|
|
getLogger().at(Level.INFO).log("Le plugin s'arrête !");
|
|
}
|
|
}
|
|
```
|