C
C#2mo ago
shades

DiscordPresence Issue

Severity Code Description Project File Line Suppression State
Error (active) CS0246 The type or namespace name 'DiscordPresence' could not be found (are you missing a using directive or an assembly reference?) Loader 12

private DiscordPresence discordPresence; // Declare the DiscordPresence instance
Severity Code Description Project File Line Suppression State
Error (active) CS0246 The type or namespace name 'DiscordPresence' could not be found (are you missing a using directive or an assembly reference?) Loader 12

private DiscordPresence discordPresence; // Declare the DiscordPresence instance
Severity Code Description Project File Line Suppression State
Error (active) CS0246 The type or namespace name 'DiscordPresence' could not be found (are you missing a using directive or an assembly reference?) Loader 16

private void InitializeDiscordPresence()
{
discordPresence = new DiscordPresence(); // Create a new DiscordPresence instance
}
Severity Code Description Project File Line Suppression State
Error (active) CS0246 The type or namespace name 'DiscordPresence' could not be found (are you missing a using directive or an assembly reference?) Loader 16

private void InitializeDiscordPresence()
{
discordPresence = new DiscordPresence(); // Create a new DiscordPresence instance
}
If anyone could help it would be amazing I have added the game sdk and used same namespaces etc nothing seems to be solving...
No description
21 Replies
TheBoxyBear
TheBoxyBear2mo ago
Are you including the package's namespace with using?
shades
shadesOP2mo ago
Yeah, Ill send over what Ive currently got.
shades
shadesOP2mo ago
No description
TheBoxyBear
TheBoxyBear2mo ago
Also the package name for reference
shades
shadesOP2mo ago
No description
shades
shadesOP2mo ago
Sent over the screenshots what ive currently got.
TheBoxyBear
TheBoxyBear2mo ago
What package are you using? Discord is a very generic namespace
shades
shadesOP2mo ago
DiscordPrescence.CS
using Discord;
using System;

namespace KeyAuth
{
public class DiscordPresence
{
private Discord.Discord _discord;
private Activity _activity;

public DiscordPresence()
{
_discord = new Discord.Discord(YourApplicationId, (UInt64)CreateFlags.Default);
_activity = new Activity
{
State = "Using KeyAuth",
Details = "Logging in",
Timestamps = new Timestamps
{
Start = DateTimeOffset.UtcNow.ToUnixTimeSeconds()
},
Assets = new Assets
{
LargeImage = "large_image_key", // Replace with your large image key
LargeText = "KeyAuth App",
}
};
UpdatePresence();
}

public void UpdatePresence()
{
_discord.ActivityManager.UpdateActivity(ref _activity, null);
}

public void Dispose()
{
_discord.Dispose();
}

public void RunCallbacks()
{
_discord.RunCallbacks();
}
}
}
using Discord;
using System;

namespace KeyAuth
{
public class DiscordPresence
{
private Discord.Discord _discord;
private Activity _activity;

public DiscordPresence()
{
_discord = new Discord.Discord(YourApplicationId, (UInt64)CreateFlags.Default);
_activity = new Activity
{
State = "Using KeyAuth",
Details = "Logging in",
Timestamps = new Timestamps
{
Start = DateTimeOffset.UtcNow.ToUnixTimeSeconds()
},
Assets = new Assets
{
LargeImage = "large_image_key", // Replace with your large image key
LargeText = "KeyAuth App",
}
};
UpdatePresence();
}

public void UpdatePresence()
{
_discord.ActivityManager.UpdateActivity(ref _activity, null);
}

public void Dispose()
{
_discord.Dispose();
}

public void RunCallbacks()
{
_discord.RunCallbacks();
}
}
}
TheBoxyBear
TheBoxyBear2mo ago
Oh so it's your own type
shades
shadesOP2mo ago
Login.CS
shades
shadesOP2mo ago
Thats what ive currently got everything releated with the discord presence. Any idea what can be the issue?
TheBoxyBear
TheBoxyBear2mo ago
The errors seem to be in file Loader
shades
shadesOP2mo ago
Yeah, Ive been trying to solve it for a while lol :thumbsdown:
TheBoxyBear
TheBoxyBear2mo ago
What's Discord.Discord? Judging from the syntax highlighting it seems to not be recornizing that type either
Buddy
Buddy2mo ago
What are you making?
shades
shadesOP2mo ago
Multi-Loader, Stores multiple loaders then all can be run through one loader. But just trying to add discord rpc as a little extra.
Buddy
Buddy2mo ago
Loaders? What's that
shades
shadesOP2mo ago
At what place are you finding this. .exe files storing UIs etc.
Buddy
Buddy2mo ago
Huh? How can you store UI?
shades
shadesOP2mo ago
Build as a .exe Then when multi-loader is run it shows examples of work etc.
Scratch
Scratch2mo ago
!ban @shades shadey. Selling game cheats
Want results from more Discord servers?
Add your server