Hello Guys,
That is my Function on cl_intro.lua file
function InitMenu()
hook.Add("HUDPaint", "DrawPGBackground", mrp_drawIntroBackground)
animationStarted = false
backgroundAlpha = 255
cameraAnimation = false
HUDIntroScreenIntroScreen = nil
sliding = false
slidePos = nil
slidePosPrev = nil
slideTimer = 0
IntroMenuAlpha = 255
--Order Sensitive
shouldDrawBackground = true
CreateIntroFrame()
CreatePlayMenu()
CreateCreditsMenu()
CreateCharacterInfomationMenu()
CreateCharacterSelectionMenu()
startMenuCameraAnimations()
startMenuMusic()
end
My Error:
[ERROR] addons/intro_screen/lua/autorun/server/sv_intro.lua:5: attempt to index a string value with bad key ('SendLua' is not part of the string library)
1. error - [C]:-1
2. __index - lua/includes/extensions/string.lua:297
3. unknown - addons/intro_screen/lua/autorun/server/sv_intro.lua:5
4. unknown - lua/includes/modules/concommand.lua:54
The Editet Code:
concommand.Add("newcharacter", function(s, ply)
ply:SendLua("InitMenu()")
end)
The Old Code:
util.AddNetworkString("Thomas-StartOurGame")
util.AddNetworkString("Thomas.ClosedIntroScreen")
Thomas.Commands:Add("newcharacter", function(s, ply)
ply:SendLua("InitMenu()")
end, function() return true end)
I wish me Help why. Concommand is not so my Work!
I have used that Wiki and SendLua ist not correct
The parameter order in the concommand function is function(ply, cmd, args), not function(cmd, ply) like you have.
Sorry, you need to Log In to post a reply to this thread.