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

[TF2] Cosmetic Leveling Mod (v0.1.2)


Post New Thread Reply   
 
Thread Tools Display Modes
noodleboy347
AlliedModders Donor
Join Date: Mar 2009
Old 02-21-2010 , 14:47   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #11

Quote:
  • Version 1.0.1 - [2/20/10]
    -Fixed plugin version in myinfo
    -Fixed KillTimer errors
    -Various bugfixes
noodleboy347 is offline
Thrawn2
Veteran Member
Join Date: Apr 2009
Old 02-21-2010 , 16:26   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #12

Nice.
Some ideas: include some natives and forwards, so other plugins could use this as a backend. You would need natives like GetClientLevel(iClient);, GetClientXP(iClient); and a single forward OnClientLevelUp(iClient, iLevel);
With these one could easily extend the functionality of your plugin, allowing real benefits from leveling up.
If you add SetClientLevel(iClient, iLevel); and SetClientXP(iClient, iXP); one could also create a (sub)plugin which saves the xp levels.
Small additions, large effects =D
edit: oh, i just saw you had that already on your to-do list.

Last edited by Thrawn2; 02-21-2010 at 16:30.
Thrawn2 is offline
noodleboy347
AlliedModders Donor
Join Date: Mar 2009
Old 02-21-2010 , 17:50   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #13

I just included the zip that Thrawn sent me, it includes the include files and a basic interface. When I have the time I'll make the edits I want.
noodleboy347 is offline
CnB|Omega
Junior Member
Join Date: Feb 2009
Old 02-21-2010 , 23:38   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #14

I know you said the plugin is designed to reset on mapchange and/or reconnect, but would you consider making it optional to save the players level and experience? Cant be that difficult to do, through clientprefs. Possibly seperate by class as well.

I know that, given the time, i could make the necessary changes myself, but it probably be best if you made them, as I dont want to hijack your plugin.
__________________

Last edited by CnB|Omega; 02-21-2010 at 23:42.
CnB|Omega is offline
noodleboy347
AlliedModders Donor
Join Date: Mar 2009
Old 02-22-2010 , 00:04   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #15

Quote:
Originally Posted by CnB|Omega View Post
I know you said the plugin is designed to reset on mapchange and/or reconnect, but would you consider making it optional to save the players level and experience? Cant be that difficult to do, through clientprefs. Possibly seperate by class as well.

I know that, given the time, i could make the necessary changes myself, but it probably be best if you made them, as I dont want to hijack your plugin.
When I learn teh databases
noodleboy347 is offline
CnB|Omega
Junior Member
Join Date: Feb 2009
Old 02-22-2010 , 00:53   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #16

Quote:
Originally Posted by noodleboy347 View Post
When I learn teh databases
Damizean's older TF2 Equipment Manager is a good example of using clientprefs to save client data.
http://forums.alliedmods.net/showthread.php?p=883146

It stored and loaded what the client had saved for hats and other equipment on reconnect. Its how I learned to use cookies. Then again, I learn by example.

Only downside is this only works on a single server, so you couldnt share level between multiple servers. That would require using the SQL database, and even I'm still inexperienced at that.
__________________
CnB|Omega is offline
CnB|Omega
Junior Member
Join Date: Feb 2009
Old 02-22-2010 , 01:39   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #17

Jumping subjects, addressing your issues with medics, you could hook some of the following events:
player_extinguished
medic_death - get the amount of healing they did in the life. Could also award points to killer if they had a full uber?
player_chargedeployed OR
player_invulned - Probably player_chargedeployed though.

Just suggestions.
__________________

Last edited by CnB|Omega; 02-22-2010 at 03:23.
CnB|Omega is offline
Thrawn2
Veteran Member
Join Date: Apr 2009
Old 02-22-2010 , 01:42   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #18

fixed interface_example.sp
minor bugs in client checking
Attached Files
File Type: sp Get Plugin or Get Source (interface_example.sp - 239 views - 997 Bytes)
Thrawn2 is offline
CnB|Omega
Junior Member
Join Date: Feb 2009
Old 02-22-2010 , 03:19   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #19

Quote:
Originally Posted by noodleboy347 View Post

  • Add a multiplier cvar for EXP on damage. Currently +EXP on hit is 10% of the damage done.
I jumped the gun and did this on my own for our servers. I get inspired and have a bad habit of hijacking plugins. If you like it, keep it. If not, no skin off my back. No need to give credit or anything either.

Adds convar "clm_exp_percent" - (0.10) Percent multiplier for EXP on damage.

Added lines 30, 64, 146. Editted lines 147-156. Also rounded the value to be sure to avoid floats. Probably not neccssary.

Edit - Forgot to include a minimum value for the convar. Dont want negatives. Uploaded corrected version.
Attached Files
File Type: sp Get Plugin or Get Source (levelmod.sp - 230 views - 6.9 KB)
__________________

Last edited by CnB|Omega; 02-22-2010 at 03:35.
CnB|Omega is offline
noodleboy347
AlliedModders Donor
Join Date: Mar 2009
Old 02-22-2010 , 09:46   Re: [TF2] Cosmetic Leveling Mod (v0.1b)
Reply With Quote #20

Thanks for helping me with stuff guys. I'll add the edits from the above version and fix the interface example when I get home today.
noodleboy347 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 15:59.


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