Raised This Month: $29 Target: $400
 7% 

[TF2] Custom Weapons 3 (Beta 2)


Post New Thread Reply   
 
Thread Tools Display Modes
xSquared
Junior Member
Join Date: Jan 2019
Old 07-31-2019 , 23:49   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #211

Is there a tutorial out there for creating custom attributes? I've tried to look at written sourcepawn tutorials, and I've tried looking at Orion and others' attribute plugins, but I can't seem to figure out how they work. Any help is appreciated, thanks!
xSquared is offline
trbz_
Junior Member
Join Date: May 2018
Old 08-03-2019 , 22:51   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #212

It imports functions and sourcemod event detection from other .inc files in the "include" folder. Most of an attribute plugin just consists of technical stuff, you've really gotta read through the entire thing to see how it's working.

I've gotten far enough where I can understand most of what orion.sp is doing, but I've been unable to create anything because it's giving me compiling errors even without any changes to the original file.

Code:
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\include\cw3-attributes.inc(144) : error 017: undefined symbol "GetClientSlot"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\include\cw3-attributes.inc(190) : error 017: undefined symbol "GetClientSlot"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\include\cw3-attributes.inc(236) : error 017: undefined symbol "GetClientSlot"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(1293) : error 017: undefined symbol "IfDoNextTime2"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(2907) : error 017: undefined symbol "TF_DMG_PREVENT_PHYSICS_FORCE"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(3334) : error 017: undefined symbol "TF_DMG_PREVENT_PHYSICS_FORCE"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(3510) : error 017: undefined symbol "TF_DMG_PREVENT_PHYSICS_FORCE"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(3883) : error 017: undefined symbol "TF_DMG_PREVENT_PHYSICS_FORCE"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(3893) : error 017: undefined symbol "TF_DMG_PREVENT_PHYSICS_FORCE"
// C:\Users\Ethan\Desktop\steamcmd\tf2\tf\addons\sourcemod\scripting\orion.sp(3941) : error 017: undefined symbol "TF_DMG_PREVENT_PHYSICS_FORCE"
I have every #include required, I'm not sure why it's giving me undefined symbol errors.

Last edited by trbz_; 08-03-2019 at 22:53.
trbz_ is offline
xSquared
Junior Member
Join Date: Jan 2019
Old 08-04-2019 , 16:25   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #213

Damn.
xSquared is offline
xSquared
Junior Member
Join Date: Jan 2019
Old 08-13-2019 , 16:01   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #214

Getting back to you on the CW3 plugins, basic-attributes(the one linked here) has comments telling you what certain things do.
xSquared is offline
xSquared
Junior Member
Join Date: Jan 2019
Old 08-14-2019 , 02:53   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #215

Update on the custom attributes: I made a plugin and I have some custom attributes set up! it was modeled on the "basic-attributes" plugin. Let me know if you want me to release it!
xSquared is offline
xSquared
Junior Member
Join Date: Jan 2019
Old 08-15-2019 , 15:37   Silver's Custom Attributes
Reply With Quote #216

Current Version: 1.3

Changelog:
Version 1.0-
First Attributes
Version 1.1-
Added "addcond on damage dealt"
The above attribute is sketchy, and may not work after a few weapon switches
Version 1.2-
Added extra argument for "addcond on damage dealt"
Version 1.21
Fixed a bug where <duration> for "addcond on damage dealt" was always multiplied by the <max charges> amount, due to the charges always being set to 0 upon a taunt
Version 1.22
Fixed a bug where attributes other than "addcond on damage dealt" wouldn't work correctly
Version 1.23
Fixed a bug where users with "addcond on damage dealt" would keep their charges after dying
Version 1.3
Added several new attributes(look at .sp file for the details)
IMPORTANT: In order for some of my attributes to work, it is required that you download my .inc
file and put it in the correct directory.


So after fumbling around with code for a while, I finally made a working attributes plugin!

WARNING: This attribute plugin uses the Custom Weapons 2 format, and therefore will require you to use "attributes" in stead of "cw3_attributes" when applying any attributes. This does not disallow use of Custom Weapons 3, it just means that you have to define this plugin's attributes separately from Custom Weapons 3 attributes.

One last thing: This plugin is a modified version of "basic-attributes," so every bit of coding I did was modeled after it.

Attribute list can be found in the .sp file.

Heres' an example of an attribute's code on one of the weapons:
Code:
		"damage builds"
		{
			"plugin"	"silver"
			"value"		"0.05 170"
		}
This plugin might get updates in the future, depends on how things work out
Attached Files
File Type: sp Get Plugin or Get Source (silver.sp - 144 views - 61.3 KB)
File Type: smx silver.smx (23.4 KB, 130 views)
File Type: inc silver.inc (140 Bytes, 126 views)

Last edited by xSquared; 09-10-2019 at 05:09. Reason: Version 1.3
xSquared is offline
spikeof2010
Junior Member
Join Date: Aug 2012
Old 08-28-2019 , 15:49   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #217

Hey, I just recently installed this plugin on my server and I was wondering is there any documentation to what attributes I can use that are in cw3-attributes and aw2attrib? I'm aware of the tf2attributes, but I've been scouring the internet with no avail.

Cheers!
spikeof2010 is offline
trbz_
Junior Member
Join Date: May 2018
Old 08-31-2019 , 13:24   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #218

Quote:
Originally Posted by spikeof2010 View Post
Hey, I just recently installed this plugin on my server and I was wondering is there any documentation to what attributes I can use that are in cw3-attributes and aw2attrib? I'm aware of the tf2attributes, but I've been scouring the internet with no avail.

Cheers!
Yes, the attribute plugins' information can be found throughout the comments of the Custom Weapons 2 and Custom Weapons 3 main threads. Here's a list of all the attribute plugins I dug out of the threads.
trbz_ is offline
spikeof2010
Junior Member
Join Date: Aug 2012
Old 09-01-2019 , 01:22   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #219

Thanks for the help- just wanted to ask- is there any native fix for using attribute 280 aka the projectile override? I've seen the official custom weapon servers use them like with the Shotgun Bridge, but I've not find any good way of utilizing it because the velocity is always set to zero.
spikeof2010 is offline
spikeof2010
Junior Member
Join Date: Aug 2012
Old 09-12-2019 , 12:00   Re: [TF2] Custom Weapons 3 (Beta 2)
Reply With Quote #220

Is there anyway that engineer's don't destroy buildings when switching on every spawn? Or is this a bug exclusive to when the engineer has a gunslinger?
spikeof2010 is offline
Reply


Thread Tools
Display Modes

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 05:50.


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