Sitemap

Amicuk Programming Answers

Unable to read stack element of the CoD2 script engine in C

-0001-11-30   Views:0

Advertisement

Hi, I am trying to get extensions for Call of Duty 2 binary working for Arch Linux. I am running x86-64 arch (3.11.2-1-ARCH) and CoD2 is 32bit. That is why i am using the multilib. It gets preloaded with LD_PRELOAD. But on Arch it doesn't read the st

Hi,
I am trying to get extensions for Call of Duty 2 binary working for Arch Linux. I am running x86-64 arch (3.11.2-1-ARCH) and CoD2 is 32bit. That is why i am using the multilib. It gets preloaded with LD_PRELOAD.
But on Arch it doesn't read the stack element of the CoD2 script engine:
// My COD_VERSION is COD2_1_3
int getStack()
#if COD_VERSION == COD2_1_2
return 0x83D7A10; // diff to 1.3: 1080
#elif COD_VERSION == COD2_1_3
return 0x83D8A90;
#elif COD_VERSION == COD1_1_5
return 0x0830AE88;
#elif COD_VERSION == COD4_1_7
return 0x08c055b0;
#else
#warning int getStack() return NULL;
return NULL;
#endif
int stackGetParamInt(int param, int *value)
//printf("stackGetParamInt() start...");
aStackElement *scriptStack = *(aStackElement**)getStack();
aStackElement *arg = scriptStack - param;
printf("scriptengine> test value=%.8x scriptStack=%.8x arg=%.8x\n", value, scriptStack, arg);
if (arg->type != STACK_INT)
return 0;
*value = (int)arg->offsetData;
//printf("... end\n");
return 1;
It prints: scriptengine> test value=ff805778 scriptStack=00000000 arg=00000000
Source: https://github.com/kungfooman/libcod/
My thread on the support forum for these extensions for CoD2: http://killtube.org/showthread.php?1583 … Arch-Linux

The replay answer
Advertisement
Hi,
I am trying to get extensions for Call of Duty 2 binary working for Arch Linux. I am running x86-64 arch (3.11.2-1-ARCH) and CoD2 is 32bit. That is why i am using the multilib. It gets preloaded with LD_PRELOAD.
But on Arch it doesn't read the stack element of the CoD2 script engine:
// My COD_VERSION is COD2_1_3
int getStack()
#if COD_VERSION == COD2_1_2
return 0x83D7A10; // diff to 1.3: 1080
#elif COD_VERSION == COD2_1_3
return 0x83D8A90;
#elif COD_VERSION == COD1_1_5
return 0x0830AE88;
#elif COD_VERSION == COD4_1_7
return 0x08c055b0;
#else
#warning int getStack() return NULL;
return NULL;
#endif
int stackGetParamInt(int param, int *value)
//printf("stackGetParamInt() start...");
aStackElement *scriptStack = *(aStackElement**)getStack();
aStackElement *arg = scriptStack - param;
printf("scriptengine> test value=%.8x scriptStack=%.8x arg=%.8x\n", value, scriptStack, arg);
if (arg->type != STACK_INT)
return 0;
*value = (int)arg->offsetData;
//printf("... end\n");
return 1;
It prints: scriptengine> test value=ff805778 scriptStack=00000000 arg=00000000
Source: https://github.com/kungfooman/libcod/
My thread on the support forum for these extensions for CoD2: http://killtube.org/showthread.php?1583 … Arch-Linux

Go to See the other 14 answers

Unable to read stack element of the CoD2 script engine in C

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I am trying to get extensions for Call of Duty 2 binary working for Arch Linux. I am running x86-64 arch (3.11.2-1-ARCH) and CoD2 is 32bit. That is why i am using the multilib. It gets preloaded with LD_PRELOAD. But on Arch it doesn't read the st[More]

Unable to install photoshop elements 13 on new computer.  Error message is:  This installer does not support installation on a 64-Bit windows operating system.  Please download the 64-Bit version of photoshop elements.  How do I do this?

Category:DefaultRelease time:2015-10-11Views:130

Unable to install photoshop elements 13 on new computer (Windows 8.1 OS).  Error message is:  This installer does not support installation on a 64-Bit windows operating system.  Please download the 64-Bit version of photoshop elements.  How do I do t[More]

I am unable to email in elements 11.

Category:DefaultRelease time:2015-10-11Views:130

I am unable to email via Elements 11. I am shooting in both raw and jpeg. Also, when I prepare the email the final photo (that is never sent) looks blurry. Help!Alright. Please try this- Right click the PhotoshopElementsOrganizer.exe present at the l[More]

I have been unable to get Photoshop Elements 11 to show in my Open With Programs

Category:DefaultRelease time:2015-10-11Views:130

I have been unable to get Photoshop Elements 11 to show in my Open With Programs list. The program is installed but will not show in Open With programs.Hi, You don't say which operating system you are using so I'll assume Windows 7 for now - try this[More]

Unable to see my elements in balance window

Category:DefaultRelease time:-0001-11-30Views:130

Hi all I am unable to see my elements in balance window when i define balances(Clik on feeds Button ). what are the setup do i need to fallow .Hi u dont need to define the balance with the same element name.The UOM for the balance and element input v[More]

I am unable to download adobe elements 10 onto my MAC

Category:DefaultRelease time:-0001-11-30Views:130

I am unable to download adobe elements 10 onto my MACHi Dave, I'm sorry you are having issues. Maybe this will help. Installation rules will let you install the software on two computers. If you have only installed it once, you should be able to inst[More]

Unable to use Photoshop elements 8 fault code 150-30 displayed

Category:DefaultRelease time:-0001-11-30Views:130

Unable to use Photoshop Elements 8.  Code 150-30 displatedWhat operating system? And have you recently tried to move or restore PSE?Read other 4 answers[More]

After 30min of having FF open when I close a tab a msg pops up -Javascript application "Unable to clean current element: TypeError: can't access dead object"

Category:DefaultRelease time:-0001-11-30Views:130

After around 30min of having FF open when I close a tab a message pops up: Javascript application Unable to clean current element: TypeError: can't access dead object OK It randomly stops showing the message for periods of about 30 min.hello MichaelS[More]

I am unable to add Data element into existing Data Type

Category:DefaultRelease time:-0001-11-30Views:130

Hi Experts, I am unable to add Data element into existing Data Type, It shows disable mode, suggest me this.. ThanksYep got it... Edited by: Manoj on Aug 20, 2008 1:09 AMRead other 2 answers[More]

Unable to execute the substitution variable in calc scripts in essbase 11.1

Category:DefaultRelease time:2015-10-11Views:130

Unable to execute the substitution variable in calc scripts in essbase 11.1.3 FIX(&CURRVERSION,COLA) Unit=units*Listprice; dataexport "file" "," "E:\NEW.TXT"; ENDFIX Error: 1200471 Error parsing formula for FIX STATEMENT[More]

SAP Script - How to check a text element is empty in Script.

Category:DefaultRelease time:-0001-11-30Views:130

Hello Friends,               I like to display a text element when it is not empty, otherwise I like to display some other text. I know how to read text element in Script, but  How to check a text element is empty in Script Thank you for your time. S[More]

Hot
I am trying to connect my macbook air through my led tv using hdmi but it won't work. I could not find arrangement option on my system preference. how do i make it appear again on my system preference so i can mirror it through my tv. thanksHi jenett [More]
The last time I connected my iPod I had added a bunch of songs and went over capacity and iTunes automatically made one giant playlist replacing all the other playlists I had made. I wanted my original playlists back so I deleted a bunch of songs and [More]
Hello, happy new year to the community! I recently did a lot of research in this forum and for the most problems in my project i could find adequate solutions in PrE 11 which I treated myself to purchase at Xmas But there's still something left: I'd [More]
I´m looking for a good headset with microphone for my Lumia 920 ! It has to be waterproof, I mean when I´m running and biking ? Any suggestions from someone using one ? (not a salesman) Solved! Go to Solution.a quick search of Google, i couldn't find [More]
Background info: I have a field that could have two different types of input, one would be numeric (such as a PK) the other input to it would be text. To ensure the Automated Row Fetch always pulls the PK properly I am using a computation ON LOAD to [More]
In my servlet, I want to call another background programs (writeen in c) to do some tasks and gather the output of them as the output of my servlet. Is there any way to do so like Suexec in apache. Thankssorry I forgot mention that the c program requ [More]
i would like to ask if JAVA can open and display a text file by issuing a command from my application is it possible to do it without using a JEditorPane? something else too, how can i set the background for my application to be a .jpg image? i searc [More]
i am using apex 4.2 and in sample application i cant find the administration module through which i can add users. I dont think that facility is available in 4.2 kindly confirm pls Any information shall be appreciated Thanks Edited by: susf on Nov 26 [More]
Hi there, A bit of background: phone was thought stolen and declared to Police as such. Found it later and cancelled theft declaration. In meantime provider had blacklisted IMEI number. After IMEI number was rehabilitated, was instructed by provider [More]
My daughter's MacBook Air had water damage and hard drive was replaced. She has a full backup on time machine. She has already turned on the computer with the new hard drive on and clicked "later" when prompted to restore. What do we need to do [More]