HOT- Memory Read And Write work On Original Nox!!

Everything related to modding, mapping and software or hacks

HOT- Memory Read And Write work On Original Nox!!

Postby panic » Sun Sep 29, 2019 9:54 am

Image


NOW, Nox can treat memory on original.

Play Test map!
check map Source Code: http://cfile217.uf.daum.net/attach/99341F3B5D90632A28BCF2
Attachments
memHack.7z
Test Maps
(31.5 KiB) Downloaded 10 times
panic
Veteran
Posts: 316
Joined: Thu Nov 12, 2015 3:47 pm

Re: HOT- Memory Read And Write work On Original Nox!!

Postby kitty » Sun Sep 29, 2019 7:32 pm

Very impressive panic! Opens up a whole new set of functions/features for vanilla map making. You never fail to surprise me.

The item/weapon spawning alone would have saved me tons of time on Untote map.
User avatar
kitty
Apprentice
Apprentice
Posts: 57
Joined: Thu May 25, 2017 3:02 am

Re: HOT- Memory Read And Write work On Original Nox!!

Postby panic » Tue Oct 01, 2019 2:41 pm

For this purpose, a slightly modified compiler is released.
revision compiler download: https://drive.google.com/file/d/1g_x3a9 ... sp=sharing
[Edit 1oct2019 21:53 -- file bug fix link cange]

Image

After downloading, edit the system file first.
first line= your nox 3.0 script file *.ns file forder path input
second line (or last line)= Installed game directory path

When you are done, save the edit file.
and Run this app. Leave the program on.
It starts compiling the saved trigger file when you save the trigger file.
The compiled file is stored in the nox map folder.

Example:
script file name= estate.ns
compiled file position(result file path)= C://Program Files//Nox//maps//estate//estateout.obj

script file name= g_coast.ns
compiled file position= C://Program Files//Nox//maps//g_coast//g_coastout.obj

Therefore, the script file must have the same name as the map file name.



Insert this code into your script to use the readMemory or writeMemory features.

Code: Select all
int EnableMemoryReadWriteFunction(int t)
{
   int addr = 0x97974c;
   int arr[29];

   arr[0] = 0x1090BE56; arr[1] = 0x06C70075; arr[2] = 0x50725068; arr[3] = 0x000446C7;
   arr[4] = 0xC7723068; arr[5] = 0x00500846; arr[6] = 0x46C754FF; arr[7] = 0xFF04240C;
   arr[8] = 0x1046C730; arr[9] = 0x042454FF; arr[10] = 0x831446C7; arr[11] = 0xC7310CC4;
   arr[12] = 0xC3C01846; arr[13] = 0x46C79090; arr[14] = 0x5068561C; arr[15] = 0x2046C772;
   arr[16] = 0x14FF0050; arr[17] = 0x242446C7; arr[18] = 0xC7FFF08B; arr[19] = 0x24142846;
   arr[20] = 0x46C73089; arr[21] = 0x04C4832C; arr[22] = 0x3046C75E; arr[23] = 0x909090C3;
   arr[24] = 0x33703589; arr[25] = 0x05C7005C; arr[26] = 0x005C31F0; arr[27] = 0x007510ac;
   arr[28] = 0x9090C35E;
   //0xed9af
   return GetScore(t);
}

int GetMemory(int addr)
{
    return Unknownb9(addr);
}

void SetMemory(int addr, int value)
{
    Unused59(addr, value);
}


In a function called MapInitialize you need to call a function called EnableMemoryReadWriteFunction.
This is done to inject shell code.

MapInitialize Example::

Code: Select all
void MapInitialize()
{
    int t = EnableMemoryReadWriteFunction(0);  //<<KeyWord. just copy this

    MusicEvent();
    GetMaster();
    InitStartSwitch();
    ImportUnitToPtrFunc();
    ImportGiveUnitFunc();
    ImportPlayerLookFunc();
    InitPlayerColor();
    MathSine(0, 0.0);
    InitGameScreen();
    FrameTimer(60, PreservePlayerLoop);
    FrameTimer(80, StandBy1);
    FrameTimer(1, InitUseMapSetting);
}


and then...

Feel free to use GetMemory and SetMemory codes.

int GetMemory(int addr);
// Load Value from the address

void SetMemory(int addr, int value);
// Setting address number
Last edited by panic on Tue Oct 01, 2019 2:54 pm, edited 1 time in total.
panic
Veteran
Posts: 316
Joined: Thu Nov 12, 2015 3:47 pm

Re: HOT- Memory Read And Write work On Original Nox!!

Postby panic » Tue Oct 01, 2019 2:44 pm

Another Testing Map

Screen Suffer
Attachments
p016052.7z
Screen Suffer
(243.25 KiB) Downloaded 10 times
panic
Veteran
Posts: 316
Joined: Thu Nov 12, 2015 3:47 pm


Return to Modding & Mapping

Who is online

Users browsing this forum: No registered users and 1 guest

cron