1111
This commit is contained in:
@@ -13,6 +13,16 @@ class Memory {
|
||||
function allocUtf8String(Str) {
|
||||
return NativePointer(Str_Ptr(Str));
|
||||
}
|
||||
|
||||
function copy(P1, P2, Size) {
|
||||
local WriteArr = Sq_ReadByteArr(P2.C_Object, Size);
|
||||
P1.writeByteArray(WriteArr);
|
||||
}
|
||||
|
||||
function reset(P1, Size) {
|
||||
local WriteArr = array(Size, 0);
|
||||
P1.writeByteArray(WriteArr);
|
||||
}
|
||||
}
|
||||
|
||||
class NativePointer extends Base_C_Object {
|
||||
@@ -41,13 +51,11 @@ class NativePointer extends Base_C_Object {
|
||||
}
|
||||
|
||||
function add(intoffset) {
|
||||
this.C_Object = Sq_PointerOperation(this.C_Object, intoffset, "+");
|
||||
return this;
|
||||
return NativePointer(Sq_PointerOperation(this.C_Object, intoffset, "+"));
|
||||
}
|
||||
|
||||
function sub(intoffset) {
|
||||
this.C_Object = Sq_PointerOperation(this.C_Object, intoffset, "-");
|
||||
return this;
|
||||
return NativePointer(Sq_PointerOperation(this.C_Object, intoffset, "-"));
|
||||
}
|
||||
|
||||
function writeByteArray(arr) {
|
||||
|
||||
Reference in New Issue
Block a user