this is caused by the new update please wait till garry fixes it![]()
every time i try to change a value, i get this error:
RunConsoleCommand: Command has invalid characters! (wire_value_value1 ('1'))
The first parameter of this function should contain only the command, the second parameter should contain arguments.
and then it wont let me change the value still, it shows on the tool menu, but doesnt actually change...
Any help here?
this is caused by the new update please wait till garry fixes it![]()
guess some wire things are broken till its fixed :/
I found a way around this,
Go to console type wire_value_value1 "Value you want"
Or wire_value_value2 "value you want"
You can do that all the way to 12.
It's a quick way to do it till a fix comes along.
Another good work-around is to set a button's ON and OFF values both to the constant value you need, and use buttons instead of wired const-values until the issue's resolved.
I have it fixxed on my server within 2 minutes in fact all my wire works thats the befits of having a coder as an admin. If anyone wants the lua files to fix it pm me.
go into your addons\wire\lua\entities\gmod_wire_value\ folder and open init.lua and delete everything and copy and paste in this code and save and try it out.
all this was done by Mr.Coder of Free Ventrilo Channels on our server! he's the best period and deserves all the credit for this fix please give credit were credit is due.
We'd also appreciate if you took the time to join are wiremod based server 194.50.80.40:27026 Wiremod Innovations 2 as a thank you for are help.
Wolfhound & Mr.Coder
AddCSLuaFile( "cl_init.lua" )
AddCSLuaFile( "shared.lua" )
include('shared.lua')
ENT.WireDebugName = "Value"
ENT.OverlayDelay = 0
function ENT:Initialize()
self.Entity:PhysicsInit( SOLID_VPHYSICS )
self.Entity:SetMoveType( MOVETYPE_VPHYSICS )
self.Entity:SetSolid( SOLID_VPHYSICS )
self.Outputs = Wire_CreateOutputs(self.Entity, { "Out" })
end
function ENT:Setup(value)
if type(value) != "table" then
local v = value
value = {}
value[1] = tostring(v)
end
local adjoutputs = {}
for k,v in pairs(value) do
adjoutputs[k] = "Value"..tostring(k)
end
self.value = value
//this is where storing the values as strings comes in
Wire_AdjustOutputs(self.Entity, adjoutputs, value)
local txt = ""
for k,v in pairs(value) do
//line break after 4 values
//if (k == 5) or (k == 9) then txt = txt.."\n" end
txt = txt .. k .. ": " .. v
if (k < #value) then txt = txt .. "\n" end
Wire_TriggerOutput(self.Entity, adjoutputs[k], tonumber(v))
end
self:SetOverlayText(txt)
end
function ENT:ReadCell( Address )
if (Address >= 0) && (Address < table.Count(self.value)) then
return self.value[Address+1]
else
return nil
end
end
function ENT:WriteCell( Address, value )
if (Address >= 0) && (Address < table.Count(self.value)) then
return true
else
return false
end
end
sorry forgot to say this is server side only I dont think it works cleintside.
Bookmarks