Aller au contenu
Morceaux d'émeute

Morceaux d'émeute

  • Maison
  • Nouvelles
  • Guides
  • Guides vidéo
  • Notes de mise à jour
  • Signaler un abus
  • Basculer le formulaire de recherche
Ficterra

Ficterra – Code API Reference Guide

Posté sur 12/05/2021 Par northernamusements Aucun commentaire sur Ficterra – Code API Reference Guide
  • Titre: Ficterra
  • Date de sortie:
  • Promoteur:
  • Éditeur:
Information about Ficterra is still incomplete. S'il vous plaît, aidez-nous à remplir les détails du jeu en utilisant ceci formulaire de contact.

Lists the functions, événements, variables etc. you can utilize when coding mods for Ficterra in Miniscript.

Événements

Event Functions

lier(événement, func) – Binds a function (func) to be called when an event triggers. The Event should be from the list below (Event.x), the function should be a function you have created. Use @myFunction to reference a function.

Event List

Event.OnBiomeEntered – Triggers when your player enters a biome
identifiant – the id of the Biome
nom – the name of the biome

Event.OnItemEquipped – Triggers when your player equips an Item
identifiant – the id of the Item
nom – the name of the Item

Event.OnItemUnEquipped – Triggers when your player unequips an Item
identifiant – the id of the Item
nom – the name of the Item

Event.OnKilledMonster – Triggers when you players kills a monster
identifiant – the id of the Monster (item id of the monster)
nom – the name of the Monster
totalKilled – number of monsters with the same id this player has killed

Event.OnGainedItem – Triggers when your player gains an Item
identifiant – the id of the Item
nom – the name of the Item
totalAmount – the amount of the item your player now has

Event.OnRemovedItem – Triggers when your player loses an Item
identifiant – the id of the Item
nom – the name of the Item
totalAmount – the amount of the item your player now has

Event.OnFinishedCrafting – Triggers when your player finishes crafting
identifiant – the id of the Crafting Plan
nom – the name of the Crafting Plan

Event.OnFinishedResearch – Triggers when your player finished research
identifiant – the id of the Research
nom – the name of the Research

Event.OnCompletedQuest – Triggers when your player completes a Quest
identifiant – the id of the Quest

Event.OnPlayerMoved – Trigger when your player has moved
playerId – net id of the player

Item Events

Item Event Functions

bindToItem(itemEvent, func, itemId) – Binds a function (func) to be called when an item event triggers for a specific type of item. The Item Event should be from the list below (ItemEvent.x), the function should be a function you have created, and the itemId is the id of the item this applies to. Use @myFunction to reference a function.

bindItemUpdate(func, itemId, setupFunc) – Binds a function (func) to be called in an item’s update loop. The itemId is the id of the item this applies to, func is the function that is called when the item updates (every tick), and setupFunc is a function that runs once to setup values or whatever you might need for the loop. Use @myFunction to reference a function.

Item Event List

ItemEvent.OnTriggerEntered – Triggers when an object enters this objects trigger area (is it has one)
objectId – the unique instance id of the object
itemId – the item id of the object
playerEnteredId – id of the entering player (if entered by a player)
objectEnteredId – id of the entering object (if entered by an object)

ItemEvent.OnTriggerExited – Triggers when an object exits this objects trigger area (is it has one)
objectId – the unique instance id of the object
itemId – the item id of the object
playerEnteredId – id of the entering player (if exited by a player)
objectEnteredId – id of the entering object (if exited by an object)

ItemEvent.OnInteract – Triggers when a player interacts with an object
objectId – the unique instance id of the object
itemId – the item id of the object
playerId – net id of the interacting player

ItemEvent.OnPlaceableCreated – Triggers when an object is created in the world
objectId – the unique instance id of the object
itemId – the item id of the object

Item Data

ItemData.Strength – Strength of a Cube
ItemData.MoveSpeed – Speed bonus while on the Cube
ItemData.Metallic – Metallic look of the Cube (depuis 0 à 1)
ItemData.Smoothness – Smoothness look of a Cube (depuis 0 à 1)

Damage Type

This is a list of all Damage Type values

  • DamageType.Sharp
  • DamageType.Blunt
  • DamageType.Piercing
  • DamageType.Fire
  • DamageType.Ice
  • DamageType.Electric
  • DamageType.Poison
  • DamageType.Metal
  • DamageType.Wood
  • DamageType.Stone
  • DamageType.Sonic
  • DamageType.Water
  • DamageType.Martial
  • DamageType.Radiation
  • DamageType.Acid
  • DamageType.Jade

Stat

This is a list of all Stat types

  • Stat.Health
  • Stat.Stamina
  • Stat.Speed
  • Stat.Carry_Limit
  • Stat.Armor
  • Stat.Woodworking
  • Stat.Masonry
  • Stat.Blacksmithing
  • Stat.Damage
  • Stat.Attack_Speed
  • Stat.Cooldown_Reduction
  • Stat.Body_Type
  • Stat.Elemental_Power
  • Stat.Resting_Heal
  • Stat.Crit_Chance
  • Stat.Penetration
  • Stat.Mastery
  • Stat.Dodge
  • Stat.Block
  • Stat.Battle_Regen
  • Stat.Life_Steal
  • Stat.Mend_Wounds

Global Variables and Functions

  • vecteur(x,oui,z) – Creates a 3D Vector with x,oui,z as coordinates (x is right, y is up, z is forward)
  • couleur(r,g,b,un) – Creates an RGBA Color
  • r – red value (0-1)
  • g – green value (0-1)
  • b – blue value (0-1)
  • un – alpha value (0-1, 0 is entirely transparent, 1 is opaque)
  • addVector(v1, v2) – Adds two vectors, v1 and v2 and returns the resulting vector
  • saveWorldStorage() – Saves your custom data associated with the world or game
  • loadWorldStorage() – Loads your custom data associated with the world or game
  • savePlayerStorage() – Saves your custom data associated with players
  • loadPlayerStorage() – Loads your custom data associated with players
  • getItemId(itemName, [modIdentifier]) – Gets an item id from an item’s name and optional mod identifier
  • getQuestId(questName, [modIdentifier]) – Gets an quest id from an quest’s name and optional
  • mod identifier
  • getResearchId(researchName, [modIdentifier]) – Gets an research id from an research’s name and optional mod identifier
  • getCubeId(cubeName, [modIdentifier]) – Gets an cube id from an cube’s name and optional mod identifier
  • hasQuest(questId) – Returns 1 if you have the quest, 0 sinon
  • deltaTime() – Returns the time elapsed since the last update
  • getPlayer(playerId) – Gets an player object from its id
  • getLocalPlayer() – Gets the player object for your playergetPlace
  • able(placeableId) – Gets a placeable object from its unique id
  • giveItem(itemId, [montant],[playerId]) – Gives an ‘montant’ of item of itemId to player with id playerId. Amount is default 1 and playerId is by default your player’s id
  • takeItem(itemId, [montant],[playerId]) – Takes an ‘montant’ of item of itemId to player with id playerId. Amount is default 1 and playerId is by default your player’s id
  • giveQuest(questId, [ignorePrereq]) – Gives a quest of ‘questId’ to your player. Pass in 1 to ignorePrereq if you want to skip checking the prerequisites for the quest
  • playMusic(musicName) – Plays music with a given name
  • playSfx(sfxName) – Plays a sound effect with a given name
  • playSfxAtPoint(sfxName, position) – Plays a sound effect with a given name at a certain position. Position is a vector
  • takeDamage(cible, dommage, damageTypeId) – Causes target to take damage equal to ‘dommage’ of the type ‘damageTypeId’. Target can be either a playerId or an object Id.
  • DamageTypeId is from DamageType.X
  • guérir(cible, montant) – Causes target to heal equal to amount. Target can be either a playerId or an object Id.
  • runCommand(commande) – Runs a console command. This is any of the commands that can be typed into the console ingame
  • moveTo(objectId,position,vitesse) – Moves an object to a position travelling at speed given
  • rotateTo(objectId,rotation,vitesse) – Rotates an object to a rotation with a angular velocity of speed. The Rotation is in euler angles
  • announce(texte) – Shows text on the screen
  • getPlayerCount() – Returns the number of players in the game
  • createPlaceable(itemId,position) – Creates a new placeable object of the item with itemId at a position. Returns the unique instance id of the placeable object
  • setItemData(clé,valeur,itemId) – Sets a value of all items of itemId. The key is from the ItemData.X.
  • getItemData(clé,itemId) – Returns a value of all items of itemId. The key is from the ItemData.X.

Aussi, the Inventory Object has 1 méthode:

  • hasItem(itemId, montant) – checks if the inventory has at least amount of an item given by itemId. Amount default is 1.

Joueur

These function are called on a Player object, ie player.func()

  • getPosition() – returns the position of the player
  • getRotation() – returns the rotation of the player (in euler angles)
  • getDirection() – returns the direction the player is facing
  • getCurrentStat(statistique) – gets the current value of a player’s statistique. Stat is from Stat.X
  • getMaxStat(statistique) – gets the maximum value of a player’s statistique. Stat is from Stat.X
  • setCurrentStat(statistique) – sets the current value of a player’s statistique. Stat is from Stat.X
  • setMaxStat(statistique) – sets the maximum value of a player’s statistique. Stat is from Stat.X
  • inventaire() – gets the player’s inventory object
  • giveItem(itemId,montant) – gives the player ‘montant’ of an item with itemId
  • takeItem(itemId,montant) – takes the player ‘montant’ of an item with itemId
  • respawn() – causes the player to respawn
  • ouvrir(researchName) – unlocks a research for this player
  • giveResearch(researchName) – gives a research as an option for this player to research

Placeable

These functions are for a Placeable object, ie placeable.function()

  • getPosition() – returns the placeable’position
  • getRotation() – returns the placeable’s rotation (in euler angles)
  • setPosition(position) – sets the placeable’position
  • setRotation(rotation) – sets the placeable’s rotation (in euler angles)
  • getDirection() – returns the placeable’s facing direction
  • inventaire() – returns the placeable’s facing direction
  • isAlive(identifiant) – static function to check if a placeable with id still exists
  • isBeingCarried() – retour 1 if currently being carried, sinon 0
  • getData(clé) – gets data saved on the placeable stored under key
  • setData(clé,valeur) – sets data saved on the placeable stored under key as value
  • saveData() – saves stored data on this placeable to file (bientôt)

C'est tout ce que nous partageons aujourd'hui pour cela Ficterra guide. Ce guide a été initialement créé et rédigé par northernamusements. Si nous ne parvenons pas à mettre à jour ce guide, vous pouvez trouver la dernière mise à jour en suivant ceci lien.

Si vous pensez que le contenu de ce site viole vos droits, y compris vos droits de propriété intellectuelle, veuillez nous contacter immédiatement en utilisant notre formulaire de contact.
Guides Mots clés:Ficterra

Navigation de l’article

Post précédent: Kari – Map of Vanaheim
Prochain article: Project MIKHAIL Combat and Gear Guide

Laisser un commentaire Annuler la réponse

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *

  • Titre: Ficterra
  • Date de sortie:
  • Promoteur:
  • Éditeur:
Information about Ficterra is still incomplete. S'il vous plaît, aidez-nous à remplir les détails du jeu en utilisant ceci formulaire de contact.

Clause de non-responsabilité

Tout le contenu cité est dérivé de leurs sources respectives. Si vous pensez que nous avons utilisé votre contenu sans autorisation, assurez-vous de nous joindre et nous le prendrons au sérieux.
  • À propos de nous
  • Contactez-nous
  • politique de confidentialité
  • Conditions d'utilisation

droits d'auteur © 2025 Morceaux d'émeute.

Alimenté par Actualité PressBook Thème WordPress