Table of Contents

Memory Namespace

The memory namespace contains functions that interact with the game clients memory.

You can access these functions via:

ashita.memory.


ashita.memory.get_baseaddr

ashita.memory.get_base

Obtains the base address of a module.

number ashita.memory.get_base(name);


ashita.memory.get_modulesize

ashita.memory.get_size

Obtains the size of a module.

number ashita.memory.get_size(name);


ashita.memory.unprotect_memory

ashita.memory.unprotect

Unprotects an area of memory, setting its page access to 'PAGE_EXECUTE_READWRITE'.

bool ashita.memory.unprotect(addr, size);


ashita.memory.allocate_memory

ashita.memory.allocate

ashita.memory.alloc

Allocates an area of memory.

number ashita.memory.alloc(size);


ashita.memory.deallocate_memory

ashita.memory.deallocate

ashita.memory.dealloc

Deallocates an area of memory.

bool ashita.memory.dealloc(addr, size);


ashita.memory.findpattern

ashita.memory.find

Scans memory for a given pattern.

number ashita.memory.find(baseAddress, size, pattern, offset, usage);

number ashita.memory.find(moduleName, size, pattern, offset, usage);


ashita.memory.read_uint8

Reads a value from memory at the given address.

number ashita.memory.read_uint8(addr);


ashita.memory.read_uint16

Reads a value from memory at the given address.

number ashita.memory.read_uint16(addr);


ashita.memory.read_uint32

Reads a value from memory at the given address.

number ashita.memory.read_uint32(addr);


ashita.memory.read_uint64

Reads a value from memory at the given address.

number ashita.memory.read_uint64(addr);


ashita.memory.read_int8

Reads a value from memory at the given address.

number ashita.memory.read_int8(addr);


ashita.memory.read_int16

Reads a value from memory at the given address.

number ashita.memory.read_int16(addr);


ashita.memory.read_int32

Reads a value from memory at the given address.

number ashita.memory.read_int32(addr);


ashita.memory.read_int64

Reads a value from memory at the given address.

number ashita.memory.read_int64(addr);


ashita.memory.read_float

Reads a value from memory at the given address.

number ashita.memory.read_float(addr);


ashita.memory.read_double

Reads a value from memory at the given address.

number ashita.memory.read_double(addr);


ashita.memory.read_array

Reads a value from memory at the given address.

number ashita.memory.read_array(addr, size);


ashita.memory.read_string

Reads a value from memory at the given address.

number ashita.memory.read_string(addr, size);


ashita.memory.write_uint8

Writes a value to memory at the given address.

void ashita.memory.write_uint8(addr, value);


ashita.memory.write_uint16

Writes a value to memory at the given address.

void ashita.memory.write_uint16(addr, value);


ashita.memory.write_uint32

Writes a value to memory at the given address.

void ashita.memory.write_uint32(addr, value);


ashita.memory.write_uint64

Writes a value to memory at the given address.

void ashita.memory.write_uint64(addr, value);


ashita.memory.write_int8

Writes a value to memory at the given address.

void ashita.memory.write_int8(addr, value);


ashita.memory.write_int16

Writes a value to memory at the given address.

void ashita.memory.write_int16(addr, value);


ashita.memory.write_int32

Writes a value to memory at the given address.

void ashita.memory.write_int32(addr, value);


ashita.memory.write_int64

Writes a value to memory at the given address.

void ashita.memory.write_int64(addr, value);


ashita.memory.write_float

Writes a value to memory at the given address.

void ashita.memory.write_float(addr, value);


ashita.memory.write_double

Writes a value to memory at the given address.

void ashita.memory.write_double(addr, value);


ashita.memory.write_array

Writes a value to memory at the given address.

void ashita.memory.write_array(addr, value);


ashita.memory.write_string

Writes a value to memory at the given address.

void ashita.memory.write_string(addr, value);