[QUOTE=Lexic;22437570]Firstly your code is no prettier and isn't valid, and secondly self.Entity is old, redundant, depreciated and left in only to stop ancient scripts from breaking. It should never be used, and any script that does use it should be updated.[/QUOTE]
The code isn't valid 'cus I put it together in around a minute, and only edited it to fix a spelling error. What's wrong with it anyway?
It's less fugly because it isn't copypasta, which is what the other guy's code is.
Anyway, I'm new to lua, so what exactly is wrong with using self.Entity?
[editline]03:44PM[/editline]
[QUOTE=Proost;22438279]Well aside from all that could somebody help me fix the bugs in it which are:
You can pocket them.
You cannot gravity gun the seed.(Which is bugbait)
I think i might need to choose a new model for the seed.[/QUOTE]
Bugbait isn't grav-gunnable because it's flesh. Use a different model and you should be able to gravgun it.
[QUOTE=David_h102;22439986]
Anyway, I'm new to lua, so what exactly is wrong with using self.Entity?[/QUOTE]
print(self.Entity == self)
You'll see why its wrong.
[QUOTE=David_h102;22439986]The code isn't valid 'cus I put it together in around a minute, and only edited it to fix a spelling error. What's wrong with it anyway?
It's less fugly because it isn't copypasta, which is what the other guy's code is.
Anyway, I'm new to lua, so what exactly is wrong with using self.Entity?
[editline]03:44PM[/editline]
Bugbait isn't grav-gunnable because it's flesh. Use a different model and you should be able to gravgun it.[/QUOTE]
Would changing the material work?
[QUOTE=David_h102;22439986]
Anyway, I'm new to lua
[/QUOTE]
So you try to prove someone wrong, and then that...
/facepalm
[QUOTE=David_h102;22439986]Anyway, I'm new to lua, so what exactly is wrong with using self.Entity[/QUOTE]
Well if you're going to use it, you might as well use self.Entity.Entity, just to make sure.
Or
[lua]self.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity[/lua], in case you're not quite sure that self is the current entity.
[QUOTE=Kronophonix;22447597]So you try to prove someone wrong, and then that...
/facepalm[/QUOTE]
When did I say you were wrong?
I didn't. I said your copypasta method of coding is ugly.
I'm new to lua, but not new to programming in general.
Oh, I did say you were wrong on the set model, but that's cus I was using the old method (apparently..)
[editline]12:04PM[/editline]
[QUOTE=Lexic;22447958]Well if you're going to use it, you might as well use self.Entity.Entity, just to make sure.
Or
[lua]self.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity.Entity[/lua], in case you're not quite sure that self is the current entity.[/QUOTE]
Rofl, I see. Ok.
[editline]12:05PM[/editline]
[QUOTE=rnate;22447511]Would changing the material work?[/QUOTE]
If you mean the physical properties, then maybe. Try making it metal.
[QUOTE=David_h102;22436907]Jesus that code is fugly.
The least you could have done is put the model paths in a table, and only used one function.[/QUOTE]
Since when does lua have to look all pretty and stuff? i guess u want something like this
[IMG]http://www.cyborgscantcry.be/pretty.png[/IMG]
[QUOTE=Kronophonix;22447597]So you try to prove someone wrong, and then that...
/facepalm[/QUOTE]
Why dont you stop flaming and leave the guy alone. He obviously didn't steal your code just used the same idea, it's hardly original after all.
[QUOTE=sintwin;22469037]Why dont you stop flaming and leave the guy alone. He obviously didn't steal your code just used the same idea, it's hardly original after all.[/QUOTE]
Guna cry about it?
[url]http://www.youtube.com/watch?v=Z_ZiRT8Nwkk[/url]
[QUOTE=Axm;22468900]Since when does lua have to look all pretty and stuff? i guess u want something like this
[IMG]http://www.cyborgscantcry.be/pretty.png[/IMG][/QUOTE]
Too much lulz for me there.
[QUOTE=Kronophonix;22480084]Guna cry about it?
[url]http://www.youtube.com/watch?v=Z_ZiRT8Nwkk[/url][/QUOTE]
Are you like 5?
Anyway, Nice entity. Some people might take interest in this.
[QUOTE=Kronophonix;22480084]Guna cry about it?
[url]http://www.youtube.com/watch?v=Z_ZiRT8Nwkk[/url][/QUOTE]
What are you, twelve?. Wait, don't answer that.
Awesome
Kronophonix - you're an ass.
[QUOTE=Skull435;22497700]Kronophonix - you're an ass.[/QUOTE]
[IMG]http://www.facepunch.com/ads/rating/tick.png[/IMG] + 1
For some reason, the _planted.mdl model ALWAYS shows up as an error. I have it on my client, and it always renders as an error.
I've done everything correctly. Everything is placed where it should be. So why dont it work? missing something in the code perhaps?
Can you help me with this?
[QUOTE=Kronophonix;22368298]Never said I was better, I said that his was similar to mine. It is also funny how this kid comes out of nowhere knowing Lua and you all trust him over some other random guy.
Here is part of the init.lua
[lua]
function ENT:Initialize()
self:SetModel("models/nater/weedplant_pot.mdl")
timer.Simple(30, self.CreateGrowth, self)
end
function ENT:CreateGrowth()
self:SetModel("models/nater/weedplant_pot_dirt.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth1, self)
end
function ENT:CreateGrowth1()
self:SetModel("models/nater/weedplant_pot_planted.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth2, self)
end
function ENT:CreateGrowth2()
self:SetModel("models/nater/weedplant_pot_growing1.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth3, self)
end
function ENT:CreateGrowth3()
self:SetModel("models/nater/weedplant_pot_growing2.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth4, self)
end
function ENT:CreateGrowth4()
self:SetModel("models/nater/weedplant_pot_growing3.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth5, self)
end
function ENT:CreateGrowth5()
self:SetModel("models/nater/weedplant_pot_growing4.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth6, self)
end
function ENT:CreateGrowth6()
self:SetModel("models/nater/weedplant_pot_growing5.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth7, self)
end
function ENT:CreateGrowth7()
self:SetModel("models/nater/weedplant_pot_growing6.mdl")
timer.Simple(math.random(100, 350), self.CreateGrowth8, self)
end
function ENT:CreateGrowth8()
self:SetModel("models/nater/weedplant_pot_growing7.mdl")
end
[/lua]
Happy now?
EDIT: For all those wondering where the rest of the code is, I only showed the change model and initialize for the model and timer for the functions because it's all you need to know.[/QUOTE]
Good job you stupid titfuck. You come on here bragging and add 18 lines of code. Next time make sure your code isn't a odorous sack of shit before you put someone down for there code (which is superior to yours, even if it isn't the most efficient.) .
My favorite part is when he says "Never said I was better",
[quote]I even checked the code and the fucking guy cant code for shit. What I do care about is your piss poor attempt at using timer.create to change the models.[/quote]
EDIT: Bahhh just noticed this is 3 weeks old, I await my ban.
While I wait for my ban:
[QUOTE=Proost;22438279]Well aside from all that could somebody help me fix the bugs in it which are:
You can pocket them.
You cannot gravity gun the seed.(Which is bugbait)
I think i might need to choose a new model for the seed.[/QUOTE]
If you don't want them pocketed look at the pocket swep shared.lua, line 53 is your friend.
I think this is a great idea.
With the drugzmod beeing released, and your growing weed.
Why nog create plants wich you can harvest to get the entities from the drugzmod?
And a few lines of copied paste stuff doesn;t matter, you won't see any fps droppings of it.
Atleast, it shouldn't.
[editline]09:32AM[/editline]
Ow wait just read through the last post learning that this is an ancient topic, sry.
I've installed this onto my server and it works fine up until the point of harvesting.
When I press E, the plant just disappears and just the pot is left behind? No bag of weed?
Anyone know why?
[QUOTE=L1QuiD;23685824]I've installed this onto my server and it works fine up until the point of harvesting.
When I press E, the plant just disappears and just the pot is left behind? No bag of weed?
Anyone know why?[/QUOTE]
what is your server IP: id like to know what servers have this installed,
PS. Kronophonix really needs to grow up lol
[QUOTE=_axe_;23679239]I think this is a great idea.
With the drugzmod beeing released, and your growing weed.
Why nog create plants wich you can harvest to get the entities from the drugzmod?
And a few lines of copied paste stuff doesn;t matter, you won't see any fps droppings of it.
Atleast, it shouldn't.
[editline]09:32AM[/editline]
Ow wait just read through the last post learning that this is an ancient topic, sry.[/QUOTE]
It already does that.
Is there anyway of making this so that it drops money?
I'm sure there is but i've messed around with the code and can't seem to make it work.
Is there anyway someone could mod it?
How do i configure this to make it produce more than one bag of weed?
By not bumping year old topics.
That doesn't help, anyone else?
Does it even still work? oh shit! i bumped it! but wait! i typed this before posting it! then i wont post it
oh wait no MOUSE MOUSE WAIT STOP MOUSE NO NO NO NO NOOOOOO STO-
Sorry, you need to Log In to post a reply to this thread.