开机代码
注意需要为支持魔术包开机的主板才可用
"AC-9E-17-B9-C3-0D"是主板mac地址
#include <stdio.h> char s[] = "AC-9E-17-B9-C3-0D"; unsigned char b[6]; int v; int i; for (i = 0; i<6; i++) { sscanf(s + 3 * i, "%02x", &v); b[i] = (unsigned char)v; printf("%02X ", b[i]); }
关机代码
#include <iostream> system("shutdown -s -f -t 0");这些代码都可用于UE4