Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 6 Vote(s) - 3 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script causing game to randomly crash (No FATAL ERROR)
RawkBandMan Offline
Posting Freak

Posts: 1,146
Threads: 35
Joined: Nov 2010
Reputation: 5
#91
RE: extra_english now is working, but I need help with a different script :)

Bump :3 Please help me!

I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
07-22-2011, 05:44 PM
Find
Obliviator27 Offline
Posting Freak

Posts: 792
Threads: 10
Joined: Jul 2011
Reputation: 66
#92
RE: extra_english now is working, but I need help with a different script :)

Can't say that I see a problem with your scripts. All I can think of to suggest is to doublecheck your in-game names.
07-23-2011, 03:32 AM
Find
RawkBandMan Offline
Posting Freak

Posts: 1,146
Threads: 35
Joined: Nov 2010
Reputation: 5
#93
RE: extra_english now is working, but I need help with a different script :)

Never Mind got it. I just need to work on my map. Will post other problems I have!

I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
(This post was last modified: 07-24-2011, 10:38 PM by RawkBandMan.)
07-24-2011, 10:04 PM
Find
RawkBandMan Offline
Posting Freak

Posts: 1,146
Threads: 35
Joined: Nov 2010
Reputation: 5
#94
RE: extra_english now is working, but I need help with a different script :)

DUN DUN DUN!!!!!!

My extra_english.lang is now, once again, not working.


extra_english.lang
Spoiler below!

<LANGUAGE>
<CATEGORY Name="CustomStoryMain">
<Entry Name="Description"You are a man named Robert Lightwood. You are having personal problems, such as depression, for an unknown reason. Your wife, Maryse Lightwood, goes on a trip to somewhere in the desert, and she dies along the way. She gives you most the things she owns in her will, including a strange artifact she found in the desert. You keep it, and strange things start happening. Such as voices telling you to "Throw it away," or "Give it to me." You ignore them, and keep living, or trying to. You are then taking a nice stroll down an abandoned road when you hear something in the bushes. You get weak from fear and fall to the floor. The world goes dark and something slaps you on the head. You wake in a cell and the story begins.
</Entry>
</CATEGORY>
<CATEGORY Name="Inventory">
<Entry Name="ItemName_CellKey">Cell #801</Entry>
<Entry Name="ItemDesc_CellKey">On the side there are words scratched in. They say "Cell #801".</Entry>
<Entry Name="ItemName_CellsDoor">Specialty Threat Cells Corridor</Entry>
<Entry Name="ItemDesc_CellsDoor">A key for a locked door in the cells where they kept me.</Entry>
<Entry Name="ItemName_SouthCells">Southern Cells</Entry>
<Entry Name="ItemName_SouthCells">The key for the Southern Cells.</Entry>
<Entry Name="ItemName_AwesomeKey">Back Hall Corridor</Entry>
<Entry Name="ItemDesc_AwesomeKey">This must be for a door in the Hallway of the Back Hall.</Entry>
</CATEGORY>
<CATEGORY Name="Ending">
<Entry Name="StartCredits">
Escape Hell Beta[br]
Made By: XxRoCkBaNdMaNxX[br]
Thanks to [br]XxWestKillzXx and [FuG]wolfofdestruction for beta testing and motivation![br][br]
Following People from Frictional Games Forums: [br]Roenlond, Mofo, Kyle, Greven, Phoroneus,
Frictional Games for this awesome piece of work
Everyone in the community for playing.[br] Stay tuned for the full custom!..... [br][br][br][br]and for Chapter 2
</Entry>
</CATEGORY>
<CATEGORY Name="Levels">
<Entry Name="level_dungeon_1">Water Works</Entry>
<Entry Name="level_dungeon_2">Outer Cells</Entry>
<Entry Name="level_wood_1">Specialty Threats Cells</Entry>
<Entry Name="level_celler_1">Southern Cells</Entry>
<Entry Name="level_celler_2">Northern Cells</Entry>
</CATEGORY>
</LANGUAGE>


Nothing in it is working, not the inventory, description, names, or levels. Havent checked credits, but Im sure thats not working aswell!!

I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
08-18-2011, 09:06 PM
Find
GreyFox Offline
Member

Posts: 162
Threads: 23
Joined: Jul 2011
Reputation: 2
#95
RE: extra_english no longer working, once again!!!

The world goes dark and something slaps you on the head. You wake in a cell and the story begins.
</Entry>

you pressed enter and the </Entry> is not lined up with your first paragraph, could this be the problem?

-Grey Fox

Current Project
Forgotten
08-18-2011, 09:12 PM
Find
RawkBandMan Offline
Posting Freak

Posts: 1,146
Threads: 35
Joined: Nov 2010
Reputation: 5
#96
RE: extra_english no longer working, once again!!!

(08-18-2011, 09:12 PM)GreyFox Wrote: The world goes dark and something slaps you on the head. You wake in a cell and the story begins.
</Entry>

you pressed enter and the </Entry> is not lined up with your first paragraph, could this be the problem?

-Grey Fox

Nope still getting the problem. Sad

Welp.

extra_english.lang
Spoiler below!

<LANGUAGE>
<CATEGORY Name="CustomStoryMain">
<Entry Name="Description"You are a man named Robert Lightwood. You are having personal problems, such as depression, for an unknown reason. Your wife, Maryse Lightwood, goes on a trip to somewhere in the desert, and she dies along the way. She gives you most the things she owns in her will, including a strange artifact she found in the desert. You keep it, and strange things start happening. Such as voices telling you to "Throw it away," or "Give it to me." You ignore them, and keep living, or trying to. You are then taking a nice stroll down an abandoned road when you hear something in the bushes. You get weak from fear and fall to the floor. The world goes dark and something slaps you on the head. You wake in a cell and the story begins.</Entry>
</CATEGORY>
<CATEGORY Name="Inventory">
<Entry Name="ItemName_CellKey">Cell #801</Entry>
<Entry Name="ItemDesc_CellKey">On the side there are words scratched in. They say "Cell #801".</Entry>
<Entry Name="ItemName_CellsDoor">Specialty Threat Cells Corridor</Entry>
<Entry Name="ItemDesc_CellsDoor">A key for a locked door in the cells area where they kept me.</Entry>
<Entry Name="ItemName_SouthCells">Southern Cells</Entry>
<Entry Name="ItemName_SouthCells">The key for the Southern Cells.</Entry>
<Entry Name="ItemName_AwesomeKey">Back Hall Corridor</Entry>
<Entry Name="ItemDesc_AwesomeKey">This must be for a door in the Hallway of the Back Hall.</Entry>
</CATEGORY>
<CATEGORY Name="Ending">
<Entry Name="StartCredits">
Escape Hell Beta[br]
Made By: XxRoCkBaNdMaNxX[br]
Thanks to [br]XxWestKillzXx and [FuG]wolfofdestruction for beta testing and motivation![br][br]
Following People from Frictional Games Forums: [br]Roenlond, Mofo, Kyle, Greven, Phoroneus,
Frictional Games for this awesome piece of work
Everyone in the community for playing.[br] Stay tuned for the full custom!..... [br][br][br][br]and for Chapter 2
</Entry>
</CATEGORY>
<CATEGORY Name="Levels">
<Entry Name="level_dungeon_1">Water Works</Entry>
<Entry Name="level_dungeon_2">Outer Cells</Entry>
<Entry Name="SpecialCells">Specialty Threats Cells</Entry>
<Entry Name="SouthernCells">Southern Cells</Entry>
<Entry Name="NorthernCells">Northern Cells</Entry>
</CATEGORY>
</LANGUAGE>


I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
08-24-2011, 07:32 PM
Find
graykin Offline
Senior Member

Posts: 317
Threads: 12
Joined: Oct 2008
Reputation: 4
#97
RE: extra_english no longer working, once again!!!

You have to close off your <Entry Name="Description" in the beginning. It should be:

<Entry Name="Description">

08-24-2011, 07:39 PM
Find
RawkBandMan Offline
Posting Freak

Posts: 1,146
Threads: 35
Joined: Nov 2010
Reputation: 5
#98
RE: extra_english no longer working, once again!!!

(08-24-2011, 07:39 PM)graykin Wrote: You have to close off your <Entry Name="Description" in the beginning. It should be:

<Entry Name="Description">

Well, the description is working, but when I enter the game, it crashes and says
(83,1) Unexpected end of file
Or something like that...

.hps
Spoiler below!

void OnStart()
{
if(ScriptDebugOn())
{
GiveItemFromFile("lantern", "lantern.ent");
for(int i=0;i<10;i++) GiveItemFromFile("tinderbox_"+i, "tinderbox.ent");
SetPlayerLampOil(100);
}
AddUseItemCallback("", "key_torture_chamber_1", "cells_door_1", "UsedKeyOnDoor", true);
AddUseItemCallback("", "key_study_1", "cellar_wood01_1", "KeyOnDoor", true);
AddUseItemCallback("", "key_study_2", "level_celler_1", "UseKey", true);
AddEntityCollideCallback("Player", "key_study_2", "GruntCells", true, 1);
AddEntityCollideCallback("servant_grunt_1", "monstergone_area", "MonsterGone", true, 1);
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_1", 3.0f, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_2", 0.5f, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_4", 0.5f, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_5", 0.5f, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_6", 0.5f, "");
AddEnemyPatrolNode("servant_grunt_1", "PathNodeArea_9", 0.5f, "");
AddEntityCollideCallback("Player", "GruntWalkBy", "ActivateGrunt", false, 1);
wakeUp();
}

void wakeUp () {
StartPlayerLookAt("servant_grunt_1", 11.0f, 11.0f, "");
FadeOut(0); // Instantly fades the screen out. (Good for starting the game)
FadeIn(10); // Amount of seconds the fade in takes
FadeImageTrailTo(2, 2);
FadeSepiaColorTo(100, 4);
SetPlayerActive(false);
FadePlayerRollTo(50, 220, 220); // "Tilts" the players head
FadeRadialBlurTo(0.15, 2);
SetPlayerCrouching(true); // Simulates being on the ground
AddTimer("trig1", 16.0f, "beginStory"); // Change '11.0f' to however long you want the 'unconciousness' to last
}

void beginStory(string &in asTimer){
ChangePlayerStateToNormal();
SetPlayerActive(true);
FadePlayerRollTo(0, 33, 33); // Change all settings to defaults
FadeRadialBlurTo(0.0, 1);
FadeSepiaColorTo(0, 4);
SetPlayerCrouching(false);
FadeImageTrailTo(0,1);
StopPlayerLookAt();
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("cells_door_1", false, true) ;
PlaySoundAtEntity("", "unlock_door", "cells_door_1", 0, false);
RemoveItem("key_torture_chamber_1");
}


void MonsterGone(string &in asParent, string &in asChild, int alState)
{
FadeEnemyToSmoke("servant_grunt_1", false);
}

void GruntCells(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_grunt_2", true);
AddEnemyPatrolNode("servant_grunt_2", "PathNodeArea_3", 0.5f, "");
AddEnemyPatrolNode("servant_grunt_2", "PathNodeArea_7", 0.5f, "");
AddEnemyPatrolNode("servant_grunt_2", "PathNodeArea_8", 5.0f, "");
AddEnemyPatrolNode("servant_grunt_2", "PathNodeArea_11", 2.0f, "");
AddEnemyPatrolNode("servant_grunt_2", "PathNodeArea_12", 0.5f, "");
}

void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("cellar_wood01_1", false, true);
PlaySoundAtEntity("", "unlock_door", "cellar_wood01_1", 0, false);
RemoveItem("key_study_1");
}

void UseKey(string &in asItem, string &in asEntity)
{
SetLevelDoorLocked("level_celler_1, false);
PlaySoundAtEntity("", "unlock_door", "level_celler_1", 0, false);
RemoveItem("key_study_2");
}


I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
08-24-2011, 08:34 PM
Find
Obliviator27 Offline
Posting Freak

Posts: 792
Threads: 10
Joined: Jul 2011
Reputation: 66
#99
RE: extra_english no longer working, once again!!!

SetLevelDoorLocked("level_celler_1", false);
At line 81. Forgot to put the closing quotation mark. Smile
08-24-2011, 09:14 PM
Find
RawkBandMan Offline
Posting Freak

Posts: 1,146
Threads: 35
Joined: Nov 2010
Reputation: 5
RE: extra_english no longer working, once again!!!

(08-24-2011, 09:14 PM)Obliviator27 Wrote: SetLevelDoorLocked("level_celler_1", false);
At line 81. Forgot to put the closing quotation mark. Smile

Thanks! Scripting is working, extra_english.lang is working!

The only thing not working is a script that I totally frigged up in the level editor with names and stuff -.-

For making a monster pop up when you pick up a key, its an AddEntityCollideCallback right?

I've come to learn to not fear the living, nor the dead... But the monsters that hide in closets.
(This post was last modified: 08-24-2011, 11:18 PM by RawkBandMan.)
08-24-2011, 11:17 PM
Find




Users browsing this thread: 1 Guest(s)