Skip to content

Instantly share code, notes, and snippets.

View native-m's full-sized avatar

Muhammad Gusti Nurfathin (Native-M) native-m

View GitHub Profile
function newLevel() {
// masuk ke level
clientMessage("MMPEI, Minecraft/ Minecraft PE Indonesia");
clientMessage("Farhan Abdullah Spensaka");
if(1-2>=0||3<4) clientMessage("1 dikurang 2 itu lebih besar dari 0, 3 itu lebih kecil daripada 4");
if(3!=2==4+5) {
clientMessage("3 nggak bisa di jumlah ke 2, dan 4 di tambah 5 sama dengan 9");
}
}
function newLevel() {
setPosition(getPlayerEnt(), Player.getX(), Player.getY()+1, Player.getZ());
}
#include <iostream>
#include <fstream>
using namespace std;
int main() {
ofstream fileTXT;
fileTXT.open("filecontoh.txt");
fileTXT << "Teks disini\n";
fileTXT.close();
#include <iostream>
// Tanda ini berarti komentar atau tanda teks yg diabaikan
/* Ini juga sama kayak yg tadi */
using namespace std; // kita mempergunakan namespace utk tidak memakai tanda "::"
int main() {
cout << "MMPEI, Minecraft/ Minecraft Pocket Edition Indonesia" << endl; // ini akan menampilkan tulisan
cout << "Farhan Abdullah Spensaka" << endl;
return 0;
}
#include <iostream>
#include <jni.h>
#include <dlfcn.h>
#include <string.h>
#include <string>
#include "mcpelauncher.h"
using namespace std;
string (*VersiAsli)(void* gusti);
// ModPE Indo API
function buatPesanClient(isiPesan) {
clientMessage(isiPesan);
}
function terapkanPosisi(idEnt,posX,posY,posZ) {
setPosition(idEnt,posX,posY,posZ);
}
function memperolehWujudPemain() {
@native-m
native-m / tiny_hook.cpp
Last active February 19, 2016 07:19 — forked from byteandahalf/tiny_hook.cpp
Ini utk hook 8 byte fungsi
// byteandahalf tiny hook
// ini bukan buatan gw
#include "sys/mman.h"
void tiny_hook(uint32_t* addr, uint32_t hook) {
bool thumb = (uint32_t)addr & 1;
if(thumb)
addr = (uint32_t*) ((uint32_t) addr - 1);
mprotect(addr, 9, PROT_READ | PROT_WRITE);
*addr = (uint32_t) (thumb)? 0xF000F8DF : 0xE51FF008; // LDR PC, [PC] di Thumb trus LDR PC, [PC, #-8] di ARM.
@native-m
native-m / Vector.h
Created February 25, 2016 10:22
Vector math
class Vector2D
{
public:
float x;
float y;
Vector2D() {}
Vector2D(float r, float s)
@native-m
native-m / Vector.h
Last active May 30, 2016 08:46
Simple 3d vector code: Muhammad Gusti Nurfathin :)
// This code is licensed with: GPL or LGPL
#include <cmath>
#include <iostream>
template <class T>
class Vector3
{
public:
T x, y, z;
@native-m
native-m / Transculent.h
Last active October 29, 2017 07:25
Transculent Blur Behind
#pragma once
#include <Windows.h>
const DWORD WCA_ACCENT_POLICY = 19;
enum ACCENT_STATE
{
ACCENT_DISABLED = 0,
ACCENT_ENABLE_GRADIENT = 1,