Raised This Month: $51 Target: $400
 12% 

TF2Items - Items with custom attributes.


Post New Thread Closed Thread   
 
Thread Tools Display Modes
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 12-21-2010 , 07:55   Re: TF2Items - Items with custom attributes.
#631

Quote:
Originally Posted by MEDIK View Post
error log is a bit big
http://pastebin.com/3fvejTSw
There is no mention of TF2Items in that log.
EDIT: I envision this going on for a while, click here to join the IRC channel where this can be done real-time.
__________________

Last edited by asherkin; 12-21-2010 at 07:58.
asherkin is offline
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 12-21-2010 , 12:07   Re: TF2Items - Items with custom attributes.
#632

Quote:
Originally Posted by MEDIK View Post
error log is a bit big
http://pastebin.com/3fvejTSw
oh hey look that's my plugin
... I should probably fix that error message f

but yeah, definitely not related to TF2Items
__________________
Mecha the Slag is offline
Thraka
AlliedModders Donor
Join Date: Aug 2005
Old 12-21-2010 , 14:32   Re: TF2Items - Items with custom attributes.
#633

Quote:
Originally Posted by asherkin View Post
No there isn't, set bonuses are applied completely differently from item attributes.

Maybe it's an idea for a new extension .
Ash that makes me think about the items extension itself. Is it possible to eventually make new items by making a new index and then some how giving that item to the player? Like a plugin would detect if they were using a rocket launcher then it would find all the items that were based on the rocket launcher and let them choose which one they wanted from the list..
Thraka is offline
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 12-22-2010 , 03:34   Re: TF2Items - Items with custom attributes.
#634

Quote:
Originally Posted by Thraka View Post
Ash that makes me think about the items extension itself. Is it possible to eventually make new items by making a new index and then some how giving that item to the player?
No, clients would crash when given a weapon that isn't defined client-side (in their items_game). Tried it already.
__________________
Mecha the Slag is offline
Pawn 3-pg
Senior Member
Join Date: Jul 2009
Old 12-22-2010 , 09:46   Re: TF2Items - Items with custom attributes.
#635

Quote:
Originally Posted by Mecha the Slag View Post
No, clients would crash when given a weapon that isn't defined client-side (in their items_game). Tried it already.
It made me very sad when Valve finally removed items 32-34 from items_game. They were perfect for creating new weapons.
Pawn 3-pg is offline
Matheus28
Senior Member
Join Date: Aug 2009
Old 12-26-2010 , 13:34   Re: TF2Items - Items with custom attributes.
#636

Actually it is possible to give a custom item to a player without an extension:
PHP Code:
new knife=GivePlayerItem(client"tf_weapon_knife");
SetEntProp(knifeProp_Send"m_iItemDefinitionIndex"4);
SetEntProp(knifeProp_Send"m_iEntityLevel"100);
SetEntProp(knifeProp_Send"m_iEntityQuality"10);
SetEntProp(knifeProp_Send"m_bInitialized"1);
EquipPlayerWeapon(clientknife); // This forces the player to switch to this weapon 
It gives a level 100 knife with quality 10 (customized).
Matheus28 is offline
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 12-26-2010 , 13:48   Re: TF2Items - Items with custom attributes.
#637

Quote:
Originally Posted by Matheus28 View Post
Actually it is possible to give a custom item to a player without an extension:
PHP Code:
new knife=GivePlayerItem(client"tf_weapon_knife");
SetEntProp(knifeProp_Send"m_iItemDefinitionIndex"4);
SetEntProp(knifeProp_Send"m_iEntityLevel"100);
SetEntProp(knifeProp_Send"m_iEntityQuality"10);
SetEntProp(knifeProp_Send"m_bInitialized"1);
EquipPlayerWeapon(clientknife); // This forces the player to switch to this weapon 
It gives a level 100 knife with quality 10 (customized).
  1. Only base weapons and a few others work with that version of GNI.
  2. You can't add attributes to the weapons.
__________________
asherkin is offline
Matheus28
Senior Member
Join Date: Aug 2009
Old 12-26-2010 , 13:56   Re: TF2Items - Items with custom attributes.
#638

Quote:
Originally Posted by asherkin View Post
  1. Only base weapons and a few others work with that version of GNI.
  2. You can't add attributes to the weapons.
It should work with any weapon that doesn't have attributes

Last edited by Matheus28; 12-26-2010 at 14:25.
Matheus28 is offline
jouva
Senior Member
Join Date: Jan 2010
Old 12-26-2010 , 15:22   Re: TF2Items - Items with custom attributes.
#639

Quote:
Originally Posted by FlaminSarge View Post
ohhh Mecha, with Windows and Filezilla, you have to stop the server first iirc.
Otherwise it refuses to overwrite.

idk, it makes it do it for me.
In general, stop the server or unload the extension no matter what platform you're on. Though Linux lets you overwrite it while it's in use, sometimes it re-references the file and the server will crash when it changes on the program.

Plugins can usually change since they're handled differently. But just to be sure, unload a plugin first as well.


Quote:
Originally Posted by Matheus28 View Post
It should work with any weapon that doesn't have attributes
Sure, but we're usually not here to change just the level or quality. We're here to do lots more things with attributes.

Last edited by jouva; 12-26-2010 at 15:27.
jouva is offline
Matheus28
Senior Member
Join Date: Aug 2009
Old 12-27-2010 , 07:32   Re: TF2Items - Items with custom attributes.
#640

Well, I use that to force the hidden to use vanilla weapons on my plugin
Matheus28 is offline
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:03.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode