![]() |
![]() |
#1 |
... aka Amix73
Join Date: Jan 2009
Location: Austria
Posts: 87
|
![]()
Maybe it is very stupid question - and one can find the answer in every basic assembler book. I have to ask it anyway since I have obviously not the right book
![]() I have resourced a loader of a game to added some patches since I debugged the game to change some features of the game (at least that was fun). Anyway the loader is horribly written and it loads its game (the main part) to an absolute address - namely $100000 which is the start of the mirrored chip afaik. So my question is how to relocate the loader in a meaningful way that it will not interfere with the loaded program? I mean is there another way than using an ugly "org $50000" statement - don't want to be forced by the loader to be nasty... Well to be honest up until now it did not interfere - but who knows when I try on different machines with different ram configurations? Shall I "AllocAbs" and copy the loader out of range of the loaded game to ensure it is not overwritten after loading the second part? I think I have to stay in chip mem since I can not hope that there will be fast ram. Any hint is highly appreciated. |
![]() |
![]() |
#2 |
move.l #$c0ff33,throat
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
|
Check which memory area the game needs (most games set up their memory very early) and then find some space for your loader. Then just simply copy it to that very location and you're done. The loader needs to be 100% pc relative for this to work or otherwise you'll have to relocate all absolute address accesses. Which is (depends on the code of curse) not too trivial (but fun).
|
![]() |
![]() |
#3 | |
... aka Amix73
Join Date: Jan 2009
Location: Austria
Posts: 87
|
Quote:
![]() As I "feared", so I have to do it the "hard" way ![]() Initially I thought there would be something like "Move the crap after the following address-boundary"-HUNK ![]() In a way I am glad it does not exist - wouldn't be the same fun. Anyway the loader code is ugly and I think I will learn quite a bit... at the moment I am happy that I could make it work and load the game after I resourced and re-assembled it. Hope to have something for the release-section, soon. ![]() |
|
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
"Lincs Amiga User Group aka "LAG" Meeting Confirmed for Sat 2nd of March" | rockape | News | 2 | 21 February 2013 22:46 |
"Reminder "Lincs Amiga User Group aka "LAG" Meet Sat 5th of January 2013" | rockape | News | 4 | 30 January 2013 00:06 |
CD32 Image-Name-Bug: "...(bla)[!].zip" -> "...(bla)[" / "...[test].zip" -> "...[tes" | cfTrio | support.WinUAE | 8 | 18 December 2012 16:31 |
Cli program to "execute" .info files | olesio | support.Apps | 4 | 05 September 2010 19:19 |
Problems with "Thespywholovedme", "Flood", "Shinobi" | sareks | support.Games | 12 | 03 May 2006 14:52 |
|
|