Hello there!
First time on the form and using AGS. I'm helping a friend by building a small C++ engine plugin for him. I need to pass a string from the C++ plugin to the AGS script.
In the script I have a simple button click event on a close GUI button :
Code: agc
In the C++ plugin I have this code:
Code: c++
Note that these are only tests to see if I can return the string.
But when I run the game and click the button. I get this error:
I followed a previous post on this topic, but only resulted in this.
Any help is welcome.
Thanks!
First time on the form and using AGS. I'm helping a friend by building a small C++ engine plugin for him. I need to pass a string from the C++ plugin to the AGS script.
In the script I have a simple button click event on a close GUI button :
String content = getBookContent();
String title = getBookTitle();
In the C++ plugin I have this code:
// get title of book with id
const char *getBookTitle(){
return engine->CreateScriptString("hello world");
}
// get content of book and page with id
const char *getBookContent(){
return engine->CreateScriptString("hello world content");
}
Note that these are only tests to see if I can return the string.
But when I run the game and click the button. I get this error:
Quote
---------------------------
Illegal exception
---------------------------
An exception 0xE06D7363 occurred in ACWIN.EXE at EIP = 0x75B4B727 ; program pointer is +6, ACI version 3.21.1115, gtags (5,5)
AGS cannot continue, this exception was fatal. Please note down the numbers above, remember what you were doing at the time and post the details on the AGS Technical Forum.
in "GlobalScript.asc", line 121
from "GlobalScript.asc", line 476
Most versions of Windows allow you to press Ctrl+C now to copy this entire message to the clipboard for easy reporting.
An error file CrashInfo.dmp has been created. You may be asked to upload this file when reporting this problem on the AGS Forums. (code 0)
---------------------------
OK
---------------------------
I followed a previous post on this topic, but only resulted in this.
Any help is welcome.
Thanks!