ShowColorShard

From GT-MP
Jump to: navigation, search
ShowColorShard
Client-Side Function
System-users.png Client-Side Javascript.png JavaScript

Creates an image overlay which displays text. Allows you to adjust the color, background color, and a timeout.

Dialog-warning.png API.showColorShard() will be removed in version 0.1.7, see Deprecated.

Syntax

API.showColorShard(string title, string description, int bgColor, int titleColor, int timeout);

Required Arguments

  • title: parameter input should be in string type.
  • description: parameter input should be in string type.
  • bgColor: parameter input should be in int type. Colors the background of the shard. See HudColorList.
  • titleColor: parameter input should be in int type. Colors the text of the shard. See HudColorList.
  • timeout: how long the shard is shown for in milliseconds. int type.

Usage example(s)

API.showColorShard("Mission Failed", "Good luck on the next one.", 2, 10, 3000);

A color shard that shows "Mission Complete"

References