AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Creating .ini for mapchange plugin. (https://forums.alliedmods.net/showthread.php?t=324948)

supertrio17 06-01-2020 21:31

Creating .ini for mapchange plugin.
 
Hey, so I want to make simple mapchange plugin that will change current map when server has less than 15 players. I want to make .ini file where I can add maps that would be cycled.

Can anyone explain this to me?

fysiks 06-01-2020 23:32

Re: Creating .ini for mapchange plugin.
 
Explain what? Read the file like you read any other file. Without more details on what you actually want from us, that's about what you get.

OciXCrom 06-02-2020 07:32

Re: Creating .ini for mapchange plugin.
 
You can just change the "mapcyclefile" cvar and set the new file there. The rest will happen automatically.

supertrio17 06-02-2020 08:50

Re: Creating .ini for mapchange plugin.
 
Quote:

Originally Posted by fysiks (Post 2703596)
Explain what? Read the file like you read any other file. Without more details on what you actually want from us, that's about what you get.

Well, I wanted someone to explain me the whole concept of creating ini files, not like step by step, but I don't quite understand it.

supertrio17 06-02-2020 08:52

Re: Creating .ini for mapchange plugin.
 
Quote:

Originally Posted by OciXCrom (Post 2703637)
You can just change the "mapcyclefile" cvar and set the new file there. The rest will happen automatically.

And how do I do that, I can't find any function or anything that can change mapcycle.

OciXCrom 06-02-2020 09:57

Re: Creating .ini for mapchange plugin.
 
Code:
set_cvar_string("mapcyclefile", "your_file_here.txt")

fysiks 06-02-2020 23:53

Re: Creating .ini for mapchange plugin.
 
Quote:

Originally Posted by supertrio17 (Post 2703649)
Well, I wanted someone to explain me the whole concept of creating ini files, not like step by step, but I don't quite understand it.

There are hundreds of plugins that read and write to files and also tutorials. Look at those if you want to learn. If you run into issues, post your code and we'll help you out.


All times are GMT -4. The time now is 17:11.

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