The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help Using MovePlayerForward Script
heyitsrobert97 Offline
Member

Posts: 68
Threads: 29
Joined: Jan 2012
Reputation: 0
#1
Using MovePlayerForward Script

Hey, I need to know How to Use This Script Code
MovePlayerForward(float afAmount)



“REQUIRES THE 1.2 PATCH: JUSTINE” Moves the player forward. It needs to be called in a timer that updates 60 times / second.

I entered it into one timer like this and it doesn't even move!

AddUseItemCallback("", "acidjar_1", "pathblock_1", "placeacid", true);
}

void placeacid(string &in asItem, string &in asEntity)
{
RemoveItem("acidjar_1");
SetEntityActive("explosivejar", true);
SetPlayerActive( false);
StartPlayerLookAt("walkto", 10.0f, 10.0f, "");
AddEntityCollideCallback("Player", "walkto", "lookexplosion", true, 1);
AddTimer("walktotimer", 0.3f, "atwalkto");
}

void atwalkto(string &in asTimer)
{
MovePlayerForward(15.0f);
}

void lookexplosion(string &in asParent, string &in asChild, int alState)
{
StopPlayerLookAt();
StartPlayerLookAt("explosivetable", 10.0f, 10.0f, "");
AddTimer("explodetimer", 1.0f, "explosion");
}

void explosion(string &in asTimer)
{
CreateParticleSystemAtEntity("", "ps_break_cavein.ps", "explosivejar", false);
StartEffectFlash(0.0f, 1.0f, 0.2f);
PlaySoundAtEntity("", "explosion_rock_large.snt", "barrel_1", 0, false);
SetEntityActive("explosivejar", false);
SetEntityActive("pathblock_1", false);
SetEntityActive("explosivetable", false);
SetPlayerActive( true);
}

Any Help It was supposed to be a thing where when you place explosives the player deactivates and walks to a script area, and then the jar explodes. but the Move Script isnt working.

This Darn House! , Four Doors, Youtube
04-06-2012, 03:23 PM
Find


Messages In This Thread
Using MovePlayerForward Script - by heyitsrobert97 - 04-06-2012, 03:23 PM
RE: Using MovePlayerForward Script - by Statyk - 04-06-2012, 04:43 PM



Users browsing this thread: 1 Guest(s)