Frictional Games Forum (read-only)

Full Version: Phonograph reset
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
In my CS I have a certain function where the Phonograph playing spawns a monster. Everything works fine there, however if the monster kills you I want the phonograph to reset back to its non-woundup state to be played again. (The monster has to spawn to break down a locked door). I thought the ResetProp("phonograph_1"); command would do the trick. The game detects no coding error yet this does not work. You cannot wind up the phonograph anymore. Is there a specific certain code for those props?

Code:
void Restart(string &in asParent, string &in asChild, int alState)
{
    CheckPoint ("checkpoint1", "PlayerStartArea_4", "Urstuff", "DeathCategory", "Deathtext1");
}

void Urstuff (string &in asName, int alCount)
{
    SetEntityConnectionStateChangeCallback("phonograph_1", "play_radio");

    ResetProp("phonograph_1");
}
nothing??
I did script back in Amnesia before, but I no longer know the scripts all too well, but I think ResetProp might not work in your case. I'm not sure, though, I didn't script in Amnesia since 2 years, I believe.
Phonograph is a wheel type entity if i am not mistaken, so something like:
Code:
SetWheelAngle("phonograph_1",-180,false);
should do the trick.
Thank you. It worked out fine. Smile