Raised This Month: $ Target: $400
 0% 

Methodmaps?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
nergal
Veteran Member
Join Date: Apr 2012
Old 09-12-2014 , 15:20   Methodmaps?
Reply With Quote #1

I figured that since Sourcemod is transitioning to a newer API+Syntax, I figured I should learn the new syntax as fast as possible in order to survive

But I'm having some (by some I mean alot) of trouble understanding how methodmaps work and are used.

I looked at the alliedmodders example in the wiki but it doesn't explain everything very well...
__________________

Last edited by nergal; 09-12-2014 at 15:23.
nergal is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 09-12-2014 , 16:04   Re: Methodmaps?
Reply With Quote #2

Did you look through the New API and Syntax thread?
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
nergal
Veteran Member
Join Date: Apr 2012
Old 09-12-2014 , 17:50   Re: Methodmaps?
Reply With Quote #3

Quote:
Originally Posted by Powerlord View Post
Did you look through the New API and Syntax thread?
Yessir, I did. I still did not quite understand it, can someone give me a detailed rundown of it?
__________________
nergal is offline
Nanochip
Senior Member
Join Date: Jan 2014
Old 03-31-2015 , 18:45   Re: Methodmaps?
Reply With Quote #4

Trying to wrap my mind around the whole thing as well. I understand it, however, I don't particularly understand the point of using it. Feels like more work than it's worth. Maybe it's just for preference?

For those who're just starting to learn the new syntax like myself:
Be sure to read the new transitional syntax wiki: https://wiki.alliedmods.net/SourcePa...tax#Methodmaps
__________________

Last edited by Nanochip; 03-31-2015 at 18:48.
Nanochip is offline
Dr. Greg House
Professional Troll,
Part-Time Asshole
Join Date: Jun 2010
Old 03-31-2015 , 18:52   Re: Methodmaps?
Reply With Quote #5

It makes it easier to write clean and maintainable code, it also introduces typesafety(?)
__________________
Santa or Satan?

Watch out when you're paying people for private requests! Most stuff already exists and you can hardly assess the quality of what you'll get, and if it's worth the money.
Dr. Greg House is offline
WildCard65
Veteran Member
Join Date: Aug 2013
Location: Canada
Old 03-31-2015 , 20:01   Re: Methodmaps?
Reply With Quote #6

Take a look at: https://github.com/WildCard65/Versus...saxtonhale.inc <--Contains only getter properties.
__________________

Last edited by WildCard65; 03-31-2015 at 20:01.
WildCard65 is offline
nergal
Veteran Member
Join Date: Apr 2012
Old 03-31-2015 , 20:24   Re: Methodmaps?
Reply With Quote #7

Quote:
Originally Posted by WildCard65 View Post
Take a look at: https://github.com/WildCard65/Versus...saxtonhale.inc <--Contains only getter properties.
will the VSH plugin itself use a methodmap for Bosses? It would be ALOT simpler to create a methodmap/class for Bosses and then branch out for each individual boss.

Maybe something like

PHP Code:
methodmap VSHBossBase

methodmap VSHHale 
VSHBossBase 
__________________
nergal is offline
WildCard65
Veteran Member
Join Date: Aug 2013
Location: Canada
Old 04-01-2015 , 06:55   Re: Methodmaps?
Reply With Quote #8

Quote:
Originally Posted by nergal View Post
will the VSH plugin itself use a methodmap for Bosses? It would be ALOT simpler to create a methodmap/class for Bosses and then branch out for each individual boss.

Maybe something like

PHP Code:
methodmap VSHBossBase

methodmap VSHHale 
VSHBossBase 
PRs are always welcome
__________________
WildCard65 is offline
nergal
Veteran Member
Join Date: Apr 2012
Old 04-01-2015 , 12:02   Re: Methodmaps?
Reply With Quote #9

Quote:
Originally Posted by WildCard65 View Post
PRs are always welcome
wtf is a PR?
__________________
nergal is offline
TnTSCS
AlliedModders Donor
Join Date: Oct 2010
Location: Undisclosed...
Old 04-01-2015 , 12:40   Re: Methodmaps?
Reply With Quote #10

Pull Requests
__________________
View my Plugins | Donate
TnTSCS is offline
Reply



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 06:37.


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