Skip to content

Commit de738ad

Browse files
committed
Language Bug fix.
1 parent 5c40e9d commit de738ad

File tree

31 files changed

+66
-60
lines changed

31 files changed

+66
-60
lines changed

nutscript/gamemode/derma/cl_system.lua

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ function PANEL:Init()
4040
key = line.index,
4141
var = castedVar
4242
};
43-
netstream.Start(AdvNut.util.CreateIdentifier("GetServerConfigs", SERVER), {key = line.index, var = castedVar});
43+
netstream.Start(AdvNut.util.CreateIdentifier("SetServerConfigs", SERVER), {key = line.index, var = castedVar});
4444
self.noticePanel:SetType(4)
4545
self.noticePanel:SetText(nut.lang.Get("system_tip"));
4646

@@ -51,7 +51,6 @@ function PANEL:Init()
5151
end;
5252
end);
5353
end;
54-
5554
self:Build();
5655
end
5756

nutscript/gamemode/kernel/netstreams/sv_netstreams.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ netstream.Hook(AdvNut.util.CreateIdentifier("GetServerConfigs", SERVER), functio
7474
netstream.Start(client, AdvNut.util.CreateIdentifier("GetServerConfigs", CLIENT), configs);
7575
end);
7676

77-
netstream.Hook(AdvNut.util.CreateIdentifier("GetServerConfigs", SERVER), function(client, data)
77+
netstream.Hook(AdvNut.util.CreateIdentifier("SetServerConfigs", SERVER), function(client, data)
7878
local key = data.key;
7979
local var = data.var
8080

nutscript/gamemode/language/sh_english.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,7 @@ nut.lang.Add("syntax_customclass", "<커스텀클래스>", language);
315315
nut.lang.Add("syntax_itemID", "<아이템 코드>", language);
316316
nut.lang.Add("syntax_password", "<비밀번호>", language);
317317

318-
nut.lang.Add("syntax_bool", "[부울값]")
318+
nut.lang.Add("syntax_bool", "[부울값]", language);
319319
nut.lang.Add("syntax_toaimpos", "[(0|1)/바라보는 곳으로]", language);
320320
nut.lang.Add("syntax_amount", "[값]", language);
321321
nut.lang.Add("syntax_area_showtime", "[시간 표시 여부]", language);

nutscript/gamemode/language/sh_korean.lua

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,9 @@ nut.lang.Add("attribute_tip2", "신체 능력치는 특정 행동을 통하여
147147
// 신체 능력, 능력치
148148
nut.lang.Add("acrobatics", "곡예", language);
149149
nut.lang.Add("strength", "", language);
150-
nut.lang.Add("cook", "요리", language);
151150

152151
nut.lang.Add("acrobatics_desc", "이 수치가 높을수록 점프할 수 있는 높이가 더욱 높아집니다.", language);
153152
nut.lang.Add("strength_desc", "이 수치가 높을수록 캐릭터의 힘이 강해집니다.", language);
154-
nut.lang.Add("cooking_desc", "요리한 음식의 결과물을 결정합니다.", language);
155153

156154
// 메뉴, 인벤토리
157155
nut.lang.Add("inventory", "인벤토리", language);
@@ -230,7 +228,6 @@ nut.lang.Add("item_take", "줍기", language);
230228
nut.lang.Add("notexist", "%s (정의되지 않음)", language);
231229

232230
// 아이템, 버튼
233-
nut.lang.Add("cooking", "요리하기", language);
234231
nut.lang.Add("free", "무료", language);
235232
nut.lang.Add("eat", "먹기", language);
236233
nut.lang.Add("open", "열기", language);
@@ -316,7 +313,7 @@ nut.lang.Add("syntax_itemID", "<아이템 코드>", language);
316313
nut.lang.Add("syntax_password", "<비밀번호>", language);
317314

318315
//,인자 선언 (넘버);
319-
nut.lang.Add("syntax_bool", "[부울값]")
316+
nut.lang.Add("syntax_bool", "[부울값]", language);
320317
nut.lang.Add("syntax_toaimpos", "[(0|1)/바라보는 곳으로]", language);
321318
nut.lang.Add("syntax_amount", "[값]", language);
322319
nut.lang.Add("syntax_area_showtime", "[시간 표시 여부]", language);

nutscript/gamemode/libs/sh_plugin.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ function nut.plugin.Load(directory)
143143
return nut.util.ReadTable(v, ignoreMap, forceRefresh)
144144
end
145145

146-
function PLUGIN:CreatePluginIdentifier(key, caller)
146+
function PLUGIN:GetPluginIdentifier(key, caller)
147147
return AdvNut.util.CreateIdentifier("", caller).."Plugin."..self.uniqueID.."."..key;
148148
end;
149149

nutscript/gamemode/sh_translations.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ if (!nut.lang) then
1616
include("libs/sh_lang.lua")
1717
end
1818

19-
nut.util.IncludeDir("language")
19+
nut.util.IncludeDir("language", true);
2020

2121
-- Start off with English.
2222
local language = "english"

nutscript/gamemode/shared.lua

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ DeriveGamemode("sandbox")
1111
-- Gamemode variables.
1212
nut.Name = "Adv_Nutscript"
1313
nut.Author = "Tensa"
14+
NSFolderName = AdvNut.FolderName;
1415

1516
-- Include and send needed utility functions.
1617
include("sh_util.lua");
@@ -46,18 +47,19 @@ nut.util.Include("sh_translations.lua");
4647

4748
-- Other core directories. The second argument is true since they're in the framework.
4849
-- If they werne't, it'd try to include them from the schema!
50+
nut.util.IncludeDir("utils", true);
4951
nut.util.IncludeDir("libs", true);
5052

5153
nut.util.IncludeDir("kernel/netstreams", true);
5254
nut.util.IncludeDir("kernel", true);
5355

5456
nut.util.IncludeDir("derma", true);
55-
nut.util.IncludeDir("utils", true);
5657

5758
// Load Cached Configs. //
5859
AdvNut.util.LoadCachedConfigs();
5960

60-
local function AdvNut.hook.Frame(hookIdentifier, doFunction)
61+
AdvNut.hook = AdvNut.hook or {};
62+
function AdvNut.hook.Frame(hookIdentifier, doFunction)
6163
if (CLIENT) then
6264
doFunction(AdvNut.util.CreateIdentifier(hookIdentifier, CLIENT));
6365
elseif (SERVER) then
@@ -86,8 +88,6 @@ end;
8688
-- Include commands.
8789
nut.util.Include("sh_commands.lua");
8890

89-
NSFolderName = AdvNut.FolderName
90-
9191
if (!SERVER and game.IsDedicated()) then
9292
concommand.Remove("gm_save")
9393

nutscript/gamemode/utils/sh_advutil.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ function AdvNut.util.GetPlayerTraceEntity(client)
1313
end;
1414

1515
function AdvNut.util.CreateIdentifier(subIdentifier, caller)
16-
if (Caller) then
17-
if (Caller == CLIENT) then
16+
if (caller != nil) then
17+
if (caller == CLIENT) then
1818
return "AdvNut.Client."..subIdentifier;
19-
elseif (Caller = SERVER) then
19+
elseif (caller == SERVER) then
2020
return "AdvNut.Server."..subIdentifier;
2121
else
2222
error("Wrong Caller.");

nutscript/plugins/3dpanel/sh_commands.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ local PLUGIN = PLUGIN or { };
22

33
nut.command.Register({
44
adminOnly = true,
5-
syntax = nut.lang.Get("syntax_url")..nut.lang.Get"syntax_width")..nut.lang.Get("syntax_height")..nut.lang.Get("syntax_scale"),
5+
syntax = nut.lang.Get("syntax_url")..nut.lang.Get("syntax_width")..nut.lang.Get("syntax_height")..nut.lang.Get("syntax_scale"),
66
onRun = function(client, arguments)
77
if (!arguments[1] or #arguments[1] < 1) then
88
nut.util.Notify(nut.lang.Get("missing_arg", 1), client)
@@ -16,7 +16,7 @@ nut.command.Register({
1616

1717
nut.command.Register({
1818
adminOnly = true,
19-
syntax = PLUGIN:GetPluginLanguage("syntax_radius"),
19+
syntax = nut.lang.Get("syntax_radius"),
2020
onRun = function(client, arguments)
2121
local radius = tonumber(arguments[1]) or 256
2222
local count = PLUGIN:Remove(client:GetShootPos(), radius)

nutscript/plugins/3dpanel/sh_plugin.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ PLUGIN.panels = PLUGIN.panels or {}
77
AdvNut.util.Include("language", PLUGIN.uniqueID, true);
88

99
nut.util.Include("sv_plugin.lua");
10-
nut.util.Inlcude("cl_plugin.lua");
10+
nut.util.Include("cl_plugin.lua");
1111
nut.util.Include("sh_commands.lua");

0 commit comments

Comments
 (0)