From 022e9b9af3050631aa5dff81127b6115b1d74c9e Mon Sep 17 00:00:00 2001 From: otta8634 Date: Fri, 20 Dec 2024 16:28:53 +0800 Subject: [PATCH] Use the translatable strings for some default classes The "Monster", "Buff", and "Vehicle" transifex strings already existed but weren't used here for some reason. This is unrelated to the guide but I saw it as a good opportunity to fix this. --- qcsrc/common/monsters/monster.qh | 4 +++- qcsrc/common/mutators/mutator/buffs/buffs.qh | 2 +- qcsrc/common/vehicles/vehicle.qh | 4 +++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/qcsrc/common/monsters/monster.qh b/qcsrc/common/monsters/monster.qh index 490a05d20..87b89216a 100644 --- a/qcsrc/common/monsters/monster.qh +++ b/qcsrc/common/monsters/monster.qh @@ -33,9 +33,11 @@ CLASS(Monster, Object) /** attributes */ ATTRIB(Monster, spawnflags, int, 0); /** human readable name */ - ATTRIB(Monster, monster_name, string, "Monster"); + ATTRIB(Monster, monster_name, string, _("Monster")); /** short name */ ATTRIB(Monster, netname, string, ""); + /** color */ + ATTRIB(Monster, m_color, vector, '1 1 1'); /** model */ ATTRIB(Monster, m_model, entity); /** hitbox size */ diff --git a/qcsrc/common/mutators/mutator/buffs/buffs.qh b/qcsrc/common/mutators/mutator/buffs/buffs.qh index f9ccddd9c..0f571931b 100644 --- a/qcsrc/common/mutators/mutator/buffs/buffs.qh +++ b/qcsrc/common/mutators/mutator/buffs/buffs.qh @@ -18,7 +18,7 @@ CLASS(Buff, StatusEffects) ATTRIB(Buff, netname, string, "buff"); ATTRIB(Buff, m_icon, string, "buff"); ATTRIB(Buff, m_color, vector, '1 1 1'); - ATTRIB(Buff, m_name, string, "Buff"); + ATTRIB(Buff, m_name, string, _("Buff")); ATTRIB(Buff, m_skin, int, 0); ATTRIB(Buff, m_lifetime, float, 60); ATTRIB(Buff, m_sprite, string, ""); diff --git a/qcsrc/common/vehicles/vehicle.qh b/qcsrc/common/vehicles/vehicle.qh index 6ccbc32cc..337e56c39 100644 --- a/qcsrc/common/vehicles/vehicle.qh +++ b/qcsrc/common/vehicles/vehicle.qh @@ -7,7 +7,9 @@ CLASS(Vehicle, Object) /** short name */ ATTRIB(Vehicle, netname, string, ""); /** human readable name */ - ATTRIB(Vehicle, vehicle_name, string, "Vehicle"); + ATTRIB(Vehicle, vehicle_name, string, _("Vehicle")); + /** color */ + ATTRIB(Vehicle, m_color, vector, '1 1 1'); /** full name of model */ ATTRIB(Vehicle, model, string, ""); /** currently a copy of the model */ -- 2.39.2