BigPlayer. Posted May 28, 2021 Posted May 28, 2021 Hey. I've been recently working on a business system but I'm having a problem. I have inserted in the commands params the player and the int ID so the the script will receive the business' ID to be updated in the SQL. But everytime I use the command it asks me for the business' ID which I don't want. How can I solve this problem? Thanks.
TheOnlyDroid Posted June 25, 2021 Posted June 25, 2021 [Command("command")] public void BLAHBLAHBLAH(Player p, string id) { if (!Regex.IsMatch(vehicle, @"^\d+$")) { // Not an INT return; } int id = int.Parse(id); } Add them in the function itself; You can change the Argument Parsing from string to what ever you want in the "Command" attribute.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now