© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•3y ago•
7 replies
Akex

❔ Which types should I use for this dictionary

I am making a command interpreter from a game, which the players can use via /command <parameters>, each command can have different parameters, and different types for each parameter.

@Command(name="help",permission=Permission.User)
public void help(CommandContext context, Player player) {...}
@Command(name="help",permission=Permission.User)
public void help(CommandContext context, Player player) {...}


The only necessary parameter is context, player can be any other type, for example a string.
So now I wanted to create a dictionary like { Player=PlayerConverter, Foo=FooConverter } which takes parameter type of the method, and converts it with the converter class from string to x.

So the issue is that I do not know which types I need in the dictionary
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

✅ Which Technologies should I use?
C#CC# / help
3y ago
❔ Should dictionary values be value types (struct)
C#CC# / help
4y ago
❔ Which algorithm should I use, CP
C#CC# / help
4y ago
Should i use C# for this idea??
C#CC# / help
3y ago