Frictional Games Forum (read-only)
Repeat a Script Function? - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html)
+---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html)
+---- Thread: Repeat a Script Function? (/thread-25935.html)

Pages: 1 2


Repeat a Script Function? - Amnesiaplayer - 08-22-2014

Hello!
i have 1 question about my cannon (downloaded)
it can shoot balls ( you must place an area and the ball (inactive) )
is it possible that the cannon shoot EVERY TIME a cannonball... (without adding 9999 cannonballs but just 1 cannonball and repeat that..


RE: Repeat a Script Function? - Romulator - 08-22-2014

How are the balls inserted? Is it an AddUseItemCallback?


RE: Repeat a Script Function? - Amnesiaplayer - 08-22-2014

AddEntityCollideCallback...


RE: Repeat a Script Function? - Mudbill - 08-22-2014

You can try ResetProp("CannonBall");

If that doesn't work, you can try to CreateEntityAtArea("CannonBall", "cannonball.ent", "Area", false);

The parameters are internal name, entity file, area name, full game save. The last one can be changed to true, in which case it will save your cannonball's location when you re-enter the level. If you don't need it, don't use it.


RE: Repeat a Script Function? - FlawlessHappiness - 08-22-2014

Show us a picture please. it will make it easier to understand


RE: Repeat a Script Function? - Amnesiaplayer - 08-22-2014

What do i have to do ?

SetPlayerCrouchEnabled(true);
idk what Const bool means..


RE: Repeat a Script Function? - Mudbill - 08-22-2014

What gave you that idea? This has nothing to do with crouching.
Const bool simply means you need to input a boolean value (either true or false).


RE: Repeat a Script Function? - Amnesiaplayer - 08-22-2014

i want that a cannon shoot to me... and i don't want to die so i set the health thing to 1 and want that the player falls , en then tp's to an another place... and wake up.. BUT tp doesn't work -_- it says about my SWORD file ?! wth ?! and tells that i need voidonleave


RE: Repeat a Script Function? - Daemian - 08-22-2014

(08-22-2014, 04:10 PM)Mudbill Wrote: What gave you that idea? This has nothing to do with crouching.
For some people going down is the solution for everything =p


RE: Repeat a Script Function? - Amnesiaplayer - 08-22-2014

yes i need that now , but it doesn't work Sad