Table of Contents

Class LocalizerExtensions

Namespace
CounterStrikeSharp.API.Core.Translations
Assembly
CounterStrikeSharp.API.dll
public static class LocalizerExtensions
Inheritance
LocalizerExtensions

Methods

ForPlayer(IStringLocalizer, CCSPlayerController?, string)

Returns a localized string using the locale of the specified player. Defaults to the server language if the player is invalid.

public static string ForPlayer(this IStringLocalizer localizer, CCSPlayerController? player, string key)

Parameters

localizer IStringLocalizer
player CCSPlayerController
key string

Returns

string

ForPlayer(IStringLocalizer, CCSPlayerController?, string, params object[])

Returns a localized string using the locale of the specified player. Defaults to the server language if the player is invalid.

public static string ForPlayer(this IStringLocalizer localizer, CCSPlayerController? player, string key, params object[] args)

Parameters

localizer IStringLocalizer
player CCSPlayerController
key string
args object[]

Returns

string