15
« on: June 04, 2003, 12:27:02 PM »
Now i'm trying to but my first scene together, i ad the first object "Wallet" to the scene, and it works perfectly, when i take it, the icoon change and i can put it in the inventory, now the problem comes, i put an second object in the screen "handcuffs" the handcuffs works perfectly, but when i'm pick up the wallet i got an "script error" the wallet disapeers from the scenen, but the icoon won't change and it isn't placed in my inventory.
this is a copy of the log file :
13:12: ********** DEBUG LOG OPENED 04-06-2003 (Release Build) *****************
13:12: DEAD:CODE Games Framework ver 1.00 (Build 25), Compiled on Apr 21 2003, 16:54:22
13:12: Platform: Windows XP (Build 2600)
13:12: DirectX version: 9.0
13:12: BugslayerUtil.dll is bound
13:12:
13:12: Scanning packages...
13:12: Registered 0 files in 0 package(s)
13:12: Initializing scripting engine...
13:12: Script compiler 'dcscomp.dll' bound successfuly
13:12: Loading string table...
13:12: 0 strings loaded
13:12: Enumerating Direct3D devices...
13:12: Enumerating DirectDraw devices...
13:12: Enumerating DirectSound devices...
13:12: Available video devices:
13:12: ASUS V8200 Series v31.40H (accelerated)
13:12: ASUS V8200 Series v31.40H (non accelerated)
13:12: Available audio devices:
13:12: Primair geluidsstuurprogramma
13:12: SB Audigy Audio [FFE0]
13:12: [no sound]
13:12:
13:12: User selected:
13:12: Video: ASUS V8200 Series v31.40H (accelerated)
13:12: Windowed:no Colors:32bit T&L:no Multisample:0
13:12: Audio: Primair geluidsstuurprogramma
13:12: Maximum texture size: 4096x4096
13:12: Error opening file 'items\handcuffs.scrips'
13:12: CScEngine::GetCompiledScript - error opening script 'items\handcuffs.scrips'
13:12: Data initialized in 105 ms
13:12: Runtime error. Script 'scenes\drawer_sleepingroom\scr\wallet.script', line 19
13:12: Cannot add item 'wallet' to inventory
13:12:
13:12: Shutting down...
13:12: Shutting down scripting engine
13:12: ********** DEBUG LOG CLOSED ********************************************
this is a copy of the items.items :
ITEM
{
CURSOR_COMBINED = TRUE
CAPTION = "wallet"
NAME = "wallet"
IMAGE = "items\wallet_klein.bmp"
CURSOR = "items\wallet_klein.bmp"
CURSOR_HOVER = "items\wallet_klein.bmp"
SCRIPT = "items\wallet.script"
CURSOR_COMBINED = TRUE
CAPTION = "handcuffs"
NAME = "Handcuffs"
IMAGE = "items\handboeien_klein.bmp"
CURSOR = "items\handboeien_klein.bmp"
CURSOR_HOVER = "items\handboeien_invent.bmp"
SCRIPT = "items\handcuffs.scrips"
}
And this is a copy of wallet.script
#include "scripts\base.inc"
////////////////////////////////////////////////////////////////////////////////
on "LookAt"
{
GoToObject();
actor.Talk("It's my wallet, my police badge is in it.");
}
////////////////////////////////////////////////////////////////////////////////
on "Take"
{
GoToObject();
actor.Talk("Good idea, i need my badge to identify myself.");
// hide the wallet entity and place "wallet" item into the inventory
Game.TakeItem("wallet");
var Entwallet = Scene.GetNode("wallet");
Entwallet.Active = false;
Game.SelectedItem = "wallet";
}
////////////////////////////////////////////////////////////////////////////////
on "Talk"
{
GoToObject();
actor.Talk("That's a good idea, i'm going to talk to my wallet. Are you crazy ??!!");
}
////////////////////////////////////////////////////////////////////////////////
on "LeftClick"
{
GoToObject();
}
////////////////////////////////////////////////////////////////////////////////
function GoToObject()
{
actor.GoTo();
actor.TurnTo(DI_UP);
}
Can any one please help me, i'm trying the figure it out for 4 hours now, and i don't see where the problem is caused.