Error message

Started by dbuske, Mon 28/02/2011 17:14:58

Previous topic - Next topic

dbuske

The game is set to start in room -1 which does not exist

I have the main character set to start in room 3.  When I try to run the game, I get the game starting on room 3 instead of room 1.
If I set the main character to start in room 1, I get the above error message.
room 1 is named room1.crm.
What is the problem?
What if your blessings come through raindrops
What if your healing comes through tears...

Matti

I can't think of a reason for that error, but you could change the number of room 1..

xxx.xxx.xxx

Ya I just tried the '' tutorial '' on making a room with hotspots and all, then i had to
make a script wich on ( hHotspot1_look) and type a message.
I did all that pressed F5 and when my mouse moves over the hotspot area, the
gameroom crashes with the following

Error: prepare_script: error -18 (no such function in script) trying to run 'Hotspot1'  room 1


''properties''

Look at Hotspot:                          hHotspot1_Look
Mouse moves over Hotspot:        hHotspot1_MouseMove


// room1 script file

function hHotspot1_Look()
{
Display("what is that");
}

function hHotspot2_Look()
{
Display("SOME PEOPLE");
}

Running it a second time seems to give no love, there is still no message popping up
when i move the mouse over the area but it seems the crash has stopped.
I also seem to move right through the hotspot area, so if i don't want my character
to do this what should i do ? set curves or edges ?
Any help would be appreciated, thanks

Khris

You're mixing up a few things, and you're hijacking dbuske's thread... :)

dbuske: Make sure the character you set to start in room 1 is actually the player character.
Also make sure there's a "1" entry in the room list, not just a room1.crm file.
This is most definitely a user error, please double check what you did.

xxx:
You have assigned the function "hHotspot1_MouseMove" to an event but the function isn't in the room script (provided what you posted is all of it). That's why you get the error.

The "Look at hotspot" event is triggered by clicking the hotspot with the eye/look cursor.

You seem to want to add cursor text to your game; this is done globally, not on a per Hotspot basis.
One way is to enter "@OVERHOTSPOT@" as a label's text and put that label on a transparent GUI that follows the mouse position. How this can be done is asked by about 40% of all newbies and there's a load of threads dealing with this already. Just search for "cursor text".

To prevent the player from walking somewhere, remove part of the walkable area. If a foreground object (that may disappear later on) is supposed to block the player, use an Object and make it Solid.

dbuske

Thanks for the reply.  It was user error.  I didn't have the main character marked as not in room 1 and 2.  He starts in room 3.
What if your blessings come through raindrops
What if your healing comes through tears...

xxx.xxx.xxx

Ahum, pardon me for highjacking the tread, thank you for the awnsers though,  i can't keep my attention focused on the whole programming, maybe some other time  ;D

SMF spam blocked by CleanTalk