MonitoringMinecraft MonitoringMinecraft
MineLauncher
Датапак Datapack

SpeechTools

[Java 1.21.5+] Create smooth custom speech with just one command!

38 скачиваний 2 подписчика

SpeechTools

Create smooth, custom speech with just one command!

Features Include:

  • Full control over typing speed, transformation, shake, and much more

  • Events system allowing you to run commands and change arguments at any point

All it takes is one command!

How to use SpeechTools

This page is viewable in game by using the command /function speechtools:help

To create a speech entity, use the command: /function speechtools:create {args:{},events:[]}

ARGUMENTS

  • text: Raw string, no json elements. e.g: args:{text:"Hi there!"} To use quotation marks or apostrophes, you have to type \\\" or \\\' (for versions 1.1.1 and below: apostrophe:\\' quotation marks:\\'\\')
  • extra: Any json elements to be attached to the text (color, font, bold etc). e.g: args:{extra:' "bold":true,"color":"green" '}
  • duration: Integer duration of the speech before disappearing. Default: 100
  • wait: Integer duration of ticks before the speech starts, or as a pause in events. Used for instances with multiple speech entities which start at different times. Default: 0
  • fade_in: Duration of how long the text scales up from 0 when spawned. Set to 0 for no interpolation. Default: 3
  • fade_out: Duration of how long the text scales down to 0 when ending. Set to 0 for no interpolation. Default: 3
  • typed: true | false || Text is typed out over time instead of instantly appearing. Default: true
  • typed_delay: Delay between typed letters, in ticks. Default: 2
  • punctuation_delay: Additional tick delay when punctuation is typed (.!?:;,) Commas use half this delay. Defaults to typed_delay value.
  • shake: Text shaking effect, higher number, more shake. Experiment with teleport_duration to adjust effect. Max of 50. Default: 0
  • teleport_offset: String set of coordinates to teleport to. Used with teleport_duration to create a sliding effect. e.g. args:{teleport_offset:"~ ~2 ~"}
  • transformation: Same format as a display entities transformation.
  • Other NBT You can also put any other text_display nbt in args{}, e.g. billboard:, background:, text_opacity: etc.

EVENTS

To add events to your speech entity, you can use the events[] field like so: function speechtools:create {args:{},events:[ {on:40,command:"say test"} ]}

on: Required for every event, specified with the following:

  • on:<number> Executes the event on the specified tick, e.g. on:40 would run on the 40th tick.
  • on:start Executes the event when the entity spawns.
  • on:end Executes the event when the entity's duration expires.
  • on:type (when typed:true) Executes the event for every character typed, ignoring spaces. Intended for Undertale/Animal Crossing style voices.
  • on:tick Executes the event every tick.

  • command: String. Runs a command of the players choosing from the speech entity. e.g. {on:100,command:"function your:function/here"}
  • modify_args: Same format as the 'args' field, can be used to change transformation, change typing speed, etc. e.g. {on:150,modify_args:{typed_delay:10}}
  • pause_on_tick: Integer. If an on:tick event is set, pause it for this many ticks.

Using Multiple Events

Simply add to the events array like so: [{on:start,command:"say hi"},{on:25,modify_args: {shake:10}},{on:50,modify_args:{shake:0}}]
If you want to add multiple events to one on: condition, do this: [{on:25,command:"say hi",pause_on_tick:5,modify_args: {typed_delay:10}}]

Limitations

  • As of right now, you can only have single element text, meaning you can't have one section of text in italic:true and the rest in italic:false . Instead you have to use multiple speech entities to achieve this effect.
  • If fade_in: is activated, the transformation will take place on tick 3 of the entity, due to inconsistencies when ran on earlier ticks.

Any feedback/tips are appreciated!

Смотри также

Похожие подборки датапаки — по версиям Майнкрафта, загрузчикам и жанрам.

MineLauncher
Лаунчер Майнкрафт без лицензии — все версии
Бесплатный лаунчер для ПК — все версии 26.1.2, 1.21.11, 1.16.5, 1.21.4. Fabric, NeoForge, Forge, шейдеры и моды в один клик.
Без лицензии Fabric, NeoForge, Forge Шейдеры и моды Все версии Майнкрафта Для слабых ПК Сервера в лаунчере
Скачать бесплатно
Windows · Бесплатно · Без лицензии