Jump to content
RAGE Multiplayer Community

Type "Player" not found


Recommended Posts

Hi, i just wanna try to do a simple gamemode bust allready failed in the first lines..

This is my code:
 

using System;
using GTANetworkAPI;

namespace ClassLibrary1
{
    public class Main : Script
    {
        [ServerEvent(Event.ResourceStart)]
        public void OnResourceStart()
        {
            NAPI.Util.ConsoleOutput("Working.");
        }
        [ServerEvent(Event.PlayerConnected)]
        public void OnPlayerConnected(Player player)
        {
            NAPI.Util.ConsoleOutput($"{player.Name} joined.");
        }

    }
}

 

The error is in line 14: "public void OnPlayerConnected(Player player)"

Edited by Jumpin
Link to post
Share on other sites
  • Jumpin changed the title to Type "Player" not found
  • 2 weeks later...

Are you using RageMP 1.1 or 0.3.7?
In 1.1 you have to load as an assembly/reference boostrapper.dll what you can find on this location: \your-servers-folder\dotnet\runtime\Bootstrapper.dll

Edited by WarstekHUN
Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...