3D Speech Bubbles
CreatiCode last edited by
You can use speech bubbles to attach some text to an object or avatar. This can be used for many different purposes, such as a chat message.
You can use the following block under “3D Action” to attach a speech bubble to the currently selected sprite object.
Many input options are available for you to fully customize the speech bubble:
The first input is the text you want to show. Similar to the 2D “say” block, if the input text is empty, then the existing speech bubble will be removed.
Note that you can use emojis in the text input, such as “”.
You can control where to place the speech bubble relative to the origin point of the sprite object.
For example, if you would like the bubble to appear directly above an avatar, then the offset x and offset y will be 0, and offset z will be a number greater than the height of the avatar. If the avatar’s height is 100, and offset z is 110, then there will be a gap of 10 units between the bubble and the avatar’s top.
The width of the speech bubble will be automatically adjusted based on the text content. However, if the text is too long, then it will be wrapped into multiple lines, and each line’s width limit is controlled by this input.
For example, suppose the max width is 100, then whenever the text is longer than 100 units, it will be split into multiple lines:
These 4 inputs control the look of the text and bubble. Note that if you would like to show some text without the bubble, you can simply set the background color to 100% transparent.
You can set the speech bubble to disappear after some number of seconds using this input. If this input is empty, then the bubble will be displayed forever, until you run this block again.
If “yes”, then the bubble will always rotate to face the camera. This way it is easy to see the text written on the speech bubble. If you set this input to “no”, then the bubble will face the same direction as the sprite object, so you won’t be able to read it from behind:
The ID is used to attach more than one speech bubble to the sprite object.
You can attach up to 4 speech bubbles to any object. By default, the ID is 1. If we run this block 2 times, both with the ID of “1”, then the second bubble will cause the first bubble to be removed.
However, if the second time you specify the ID of “2”, then both speech bubbles will be displayed.
In this program, we use 3 speech bubbles for different purposes. The name of the avatar is shown in front of him. A second bubble is used to show “+1” for adding a point for the player. A third bubble is shown over his head for a chat message for 3 seconds.
Here is the result: