helloworld2817
Junior Member
Posts: 3
Threads: 1
Joined: May 2012
Reputation:
0
|
RE: Unexpected EOF Error
Ahhh thank you very much! +rep (07-03-2012, 03:51 AM)andyrockin123 Wrote: I have found your problem:
You're not supposed to put float (decimal number) values inside of quotation ("") marks. Float and Integer values are only numbers; only string need to be inside quotation marks. Here is the revised script:
// Run first time starting map
void OnStart()
{
PreloadSound("male_terrified_5.snt");
SetEntityPlayerInteractCallback("scaryhall", "HallScare", true);
}
void HallScare(string &in asEntity)
{
StartScreenShake(0.3f, 5.5f, 1.0f, 1.0f);
PlaySoundAtEntity("", "male_terrified_5.snt", "ScaryHall", 0.0f, false);
}
////////////////////////////
// Run when entering map
void OnEnter()
{
if(ScriptDebugOn())
{
GiveItemFromFile("lantern", "lantern.ent");
SetPlayerLampOil(100.0f);
}
}
////////////////////////////
// Run when leaving map
void OnLeave()
{
}
To answer your second question, screen shake has no effect on objects in games, it's simply another camera effect (like blur, fov, sepia, etc). The function you're looking for to knock the painting off the wall is addpropforce:
AddPropForce(string& asName, float afX, float afY, float afZ, string& asCoordSystem);
Hope that helped!
|
|
07-03-2012, 04:12 AM |
|