少年修仙传客户端基础资源
hch
2024-04-01 d01413b00ef631ac20347716b23818b0b811f65f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#include "w32mutex.h"
#include "Mutex-c-api.h"
 
void
mono_w32mutex_init (void)
{
}
 
gpointer
ves_icall_System_Threading_Mutex_CreateMutex_internal (MonoBoolean owned, MonoStringHandle name, MonoBoolean *created, MonoError *error)
{
    UnityPalMutex* mutex = NULL;
 
    *created = TRUE;
 
    if (!name) {
        mutex = UnityPalMutexNew (owned);
    } else {
        g_assertion_message ("Named mutexes are not supported by the Unity platform.");
    }
 
    return UnityPalMutexHandleNew(mutex);
}
 
MonoBoolean
ves_icall_System_Threading_Mutex_ReleaseMutex_internal (gpointer handle)
{
    UnityPalMutexUnlock(UnityPalMutexHandleGet(handle));
    return TRUE;
}
 
gpointer
ves_icall_System_Threading_Mutex_OpenMutex_internal (MonoStringHandle name, gint32 rights, gint32 *err, MonoError *error)
{
    g_assertion_message ("Named mutexes are not supported by the Unity platform.");
    return NULL;
}
 
MonoW32HandleNamespace*
mono_w32mutex_get_namespace (MonoW32HandleNamedMutex *mutex)
{
    g_assertion_message ("Named mutexes are not supported by the Unity platform.");
    return NULL;
}
 
void
mono_w32mutex_abandon (void)
{
}