View Single Post
xSquared
Junior Member
Join Date: Jan 2019
Old 08-15-2019 , 15:37   Silver's Custom Attributes
Reply With Quote #221

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 - 307 views - 61.3 KB)
File Type: smx silver.smx (23.4 KB, 232 views)
File Type: inc silver.inc (140 Bytes, 226 views)

Last edited by xSquared; 09-10-2019 at 05:09. Reason: Version 1.3
xSquared is offline