Most of plugin not working

Doctor

New Member
Member
Jul 28, 2014
16
10
1
Turkey
i've changed my all plugins setting ( Magma. to Fougerite. ) but most of my plugins not working.

And in chat it says "Config does not exist"
 

DreTaX

Probably knows the answer...
Administrator
Jun 29, 2014
4,093
4,784
113
At your house.
github.com
i've changed my all plugins setting ( Magma. to Fougerite. ) but most of my plugins not working.

And in chat it says "Config does not exist"
Are you using the pre version?

If you are using 1.0.3 Did you create the Fougerite in the Server's root folder, and put the Fougerite.cfg there?
 

mikec

Master Of All That I Survey
Retired Staff
Trusted Member
Jul 12, 2014
296
152
28
Los Angeles, California, USA
i've changed my all plugins setting ( Magma. to Fougerite. ) but most of my plugins not working.
Do you mean you added a comment "// fougerite" to the first line of the script?
That's only for scripts that have been adapted not to need Magma compatibility fixes. Leave it out if you are running scripts written for Magma.
 

Doctor

New Member
Member
Jul 28, 2014
16
10
1
Turkey
Do you mean you added a comment "// fougerite" to the first line of the script?
That's only for scripts that have been adapted not to need Magma compatibility fixes. Leave it out if you are running scripts written for Magma.
I just did this

WARNING: If you are using Magma plugins you must rename all calls to class "Magma" to "Fougerite":

Code (javascript):
var player = Magma.Player.FindBySteamID(id);
var player = Fougerite.Player.FindBySteamID(id);

but nothing working example

JavaScript:
function On_Command(Player, cmd, args)
{
    if(cmd == "b" || cmd == "broadcast")
    {
        if(!Player.Admin)
        {
            Player.Message("You are not allowed to use this command!");
        }
        else if(args.Length < 1)
        {
            Player.Message("Command Usage: /broadcast message");
        }
        else
        {
            var text = argsToText(args);
            Server.BroadcastNotice(text, 5);
        }
    }
}

function argsToText(args)
{
    var text = "";
    if (args.Length == 1)
    {
        text = args[0];
    }else{
        for (var l = 0; l < args.Length; l++)
        {
            if (l == args.Length - 1)
            {
                text += args[l];
            }else{
                text += args[l] + " ";
            }
        }
   }
   return text;
}
this plugin not working
 
Last edited by a moderator:

Doctor

New Member
Member
Jul 28, 2014
16
10
1
Turkey
Ok, this doesn't apply to your plugin.

If you are running a 1.0.4 pre-release, change all .Length to lower-case .length.
i'm trying it now by the way Modules/RustPP/ is not working properly we can't use /tpa command
 

mikec

Master Of All That I Survey
Retired Staff
Trusted Member
Jul 12, 2014
296
152
28
Los Angeles, California, USA
Rust++ commands have been fixed in the latest commit. There are also now 2 Javascript modules, one for legacy Magma plugins and another for the new Javascript engine. I also fixed the Magma bug that made quotes in chat come out as \"quoted words\".
 

Jakkee

Retired Staff
Retired Staff
Plugin Developer
Jul 28, 2014
1,465
932
113
Australia
I had this problem before,
Have the folder name the same as the .js script and have the config file name the same as the .js script as well.
That worked for me.
EXAMPLE:
 

Attachments