What do you need help with? JUNE


Like WayWo this was supposed to have a new thread every month. But it was never made. But alas, we have returned in June!

**General Faqs: http://www.facepunch.com/threads/868561-Need-help-READ-THIS-FIRST
HOW TO LUA?: http://wiki.garrysmod.com/?title=Lua_Tutorial_Series
(OLD) GLUA WIKI: http://wiki.garrysmod.com
LUA SEARCH: http://luasearch.remscar.com
Temp Lua Wiki: http://maurits.tv/data/garrysmod/wiki/wiki.garrysmod.com/index4875.html?title=Main_Page

How to clip texture like Max Payne or something?
Is there any command for this?

I am wondering if anyone can fix this code so that it only opens up one reason box when you right click. At the moment when you right click whilst looking at a player it opens 3 or 4 reason boxes when im looking for it to just open one. Here is the code.

[lua] function SWEP:SecondaryAttack()
self:SetNextSecondaryFire(CurTime() +1);
local trace = self.Owner:GetEyeTrace()
if trace.Entity:IsPlayer() then
Derma_StringRequest(“wanted reason”, “Enter the reason to arrest this player”, “”, function(Reason)
LocalPlayer():ConCommand("say /wanted “… trace.Entity:UserID()…” "… Reason)
end [/lua]

Post a reply here or add me on steam if you need more information. Steam = http://steamcommunity.com/profiles/76561198005643722/

Thanks Toby

This is different to my other post in last topic

Anyone know about this? Or even other ways around it.



**I **am in need of someone that has experience with OpenAura. We’re a upcoming community that will host Metro 2033 Serious roleplay.
We have pretty much everything, all the player models and props ported from the game, our own map finished, and some custom plugins.
But we’re still in need of some new plugins so if you’re intrested then add me.

If you would like to know more about our upcoming community, check out our steam group: http://steamcommunity.com/groups/avox-gaming

Regards, Tokiz

(Some old pics from our old server)

I have a hopefully quick question, what is the function of “render.CopyTexture(from, to)”?

I’ve tried playing around with it, to copy a renderer to a texture, but failed:

local from = GetRenderTarget("GModToolgunScreen", 256, 256)
local to = Material("ash47/mytexture"):GetMaterialTexture("$basetexture")

render.CopyTexture(from, to)

Obviously I’m doing something wrong, feel free to tell me what I’m missing…

I’m simply running this code as is, using lua_openscript_cl, perhaps it needs to be in a hook somewhere?

I am trying to make my own scripted chair/vehicle using Lua, and I cant seem to find any information on doing so…

Thread Here:

Anyone have any success getting traces to hit custom PhysicsInitBox’s?
I know you can create Physics from a Mesh table but not sure how to go about that. I have the physics that I want… just traces aren’t hitting it.

Did you try SOLID_BBOX and adding CONTENTS_HITBOX to the trace’s mask?

I was wondering if anyone could fix this so Admins+ can touch peoples props as well

[lua]function _R.Player:CanTouch( objEnt )
if( objEnt:IsPlayer( ) ) then return false; end
if( objEnt.CPPIControlled ) then
if( objEnt:CPPIGetOwner( ) ) then
local objOwner = player.GetByUniqueID( objEnt:CPPIGetOwner( ) );
return objOwner && objOwner:IsBuddy( self ) || false;
return false;

Sweet, that worked, thanks.

However now the physbeam freaks out on it =P Not that big of a deal but still annoying

This has happened once before, but… I forgot what I did to fix it.

why does this look like the exact same thing as my beta prop protection on the Steam workshop?

[editline]3rd June 2012[/editline]

as in,


Does anyone know how to do those little lightning balls?

How to make table, that is in an autorun, to visible any other entity? Because PrintTable gives results only in the lua that is in autorun folder.

I have this code here that i am using to make so you right click with an arrest baton to make the person your looking at wanted.

[lua]function SWEP:SecondaryAttack()
self:SetNextSecondaryFire(CurTime() +1);
local trace = self.Owner:GetEyeTrace()
if trace.Entity:IsPlayer() then
Derma_StringRequest(“wanted reason”, “Enter the reason to arrest this player”, “”, function(Reason)
self.Owner:ConCommand("say /wanted “… trace.Entity:UserID()…” "… Reason)
end [/lua]

It currently opens 2/3 reason boxes and also gives this error in console (thay may be connected, im unsure). Can anyone tell me how to fix this?

[gamemodes\darkrp\entities\weapons\arrest_stick\shared.lua:151] attempt to call
global ‘Derma_StringRequest’ (a nil value)

Thanks Toby

what the fuck am I hearing, whale mating?

[editline]3rd June 2012[/editline]

in all seriousness it looks like particle effects

[lua]function SWEP:SecondaryAttack()
self:SetNextSecondaryFire(CurTime() + 1);

if (CLIENT) then
	local trace = LocalPlayer():GetEyeTraceNoCursor();
	local entity = trace.Entity;

	if ( IsValid(entity) and entity:IsPlayer() ) then
			local function Callback(reason)
				LocalPlayer():ConCommand( "say /wanted "..entity:UserID().." "..tostring(reason) );

			Derma_StringRequest("wanted reason", "What is the reason?", "Reason", Callback);


1337th Post!

Found out, they are particle effects.

Is there a way to make them spin around me? And keep up if i walk or something.

local centr = Vector(0,0,100)
local em = ParticleEmitter(centr)
for i=1, 20 do
local part = em:Add(“sprites/orangecore1”,centr)
if part then
part:SetPos(LocalPlayer():GetPos() + Vector(0,0,math.sin(CurTime()*25)))


I’m using that code atm.