![]() |
[Help] Envy the Dead Developemt & Scripting Questions - 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: [Help] Envy the Dead Developemt & Scripting Questions (/thread-20332.html) |
RE: [Help] Envy the Dead Developemt & Scripting Questions - plutomaniac - 03-16-2013 1) As far as I understand pickuptinder is the internal name and PickUpTinder is the function to call. But where do you actually specify at which entity the callback will execute? 2) So for music I should probably use PlayMusic and for small sounds PlayGuiSound. Because if I want to play a scared sound (reaction) which is like 2 seconds, noone will even notice the 3D lack. Edit: At PlayMusic I think it says that only the sound with the highest priority can be heard. What does that mean? Because when I first read it I thought that only one sound can be played at any given time making multiple sound playback not possible, something that I know is not true. 3) Thank you for the info, that thread was indeed helpful. When I'm done with everything I will spend some time improving the performance and I will add all those performance fixes. There's also a small guide at the wiki as far as I recall. But that's for later... RE: [Help] Envy the Dead Developemt & Scripting Questions - NaxEla - 03-16-2013 (03-16-2013, 03:26 PM)plutomaniac Wrote: 1) As far as I understand pickuptinder is the internal name and PickUpTinder is the function to call. But where do you actually specify at which entity the callback will execute? 1) asName is the internal name for the item (the name it's called in the level editor). SetEntityPlayerInteractCallback(asName, asCallback, abRemoveOnInteraction); 2) Yes, you should use PlayMusic for music, and for sounds, you should use either PlaySoundAtEntity or PlayGuiSound. If you don't need the sound to be 3d, then use PlayGuiSound. Regarding the priority stuff, only the music with the highest priority will play. PlayMusic(string& asMusicFile, bool abLoop, float afVolume, float afFadeTime, int alPrio, bool abResume); You can have multiple sound playing at the same time, but only one music track is allowed to be played. RE: [Help] Envy the Dead Developemt & Scripting Questions - plutomaniac - 03-16-2013 Something that also bumps me is that when I use AddUseItemCallback even if I set the boolean to true in the end, the item is not automatically removed and thus I have to use RemoveItem. Is this normal? RE: [Help] Envy the Dead Developemt & Scripting Questions - Your Computer - 03-16-2013 (03-16-2013, 07:24 PM)plutomaniac Wrote: Something that also bumps me is that when I use AddUseItemCallback even if I set the boolean to true in the end, the item is not automatically removed and thus I have to use RemoveItem. Is this normal? The wiki article may say to remove the item, but it's actually removing the callback so that using the item again won't trigger the callback. RE: [Help] Envy the Dead Developemt & Scripting Questions - plutomaniac - 03-18-2013 I searched the wiki today to find the special words that you can use when making notes/diaries but I found that there was nothing about them there. So far I know [br] [new_page] and [voice sound.ogg]. Are there more? I want to leave space between two words. RE: [Help] Envy the Dead Developemt & Scripting Questions - Your Computer - 03-18-2013 (03-18-2013, 08:57 PM)plutomaniac Wrote: I searched the wiki today to find the special words that you can use when making notes/diaries but I found that there was nothing about them there. So far I know [br] [new_page] and [voice sound.ogg]. Are there more? I want to leave space between two words. The only reason i know about those is because i looked for them in the game's original lang file. RE: [Help] Envy the Dead Developemt & Scripting Questions - plutomaniac - 03-18-2013 (03-18-2013, 10:03 PM)Your Computer Wrote: The only reason i know about those is because i looked for them in the game's original lang file. Yes I learned these from you. So as far as I understand it is not possible to do this: Code: Dear XXX, 17.8.2013 RE: [Help] Envy the Dead Developemt & Scripting Questions - The chaser - 03-20-2013 Try to be creative. Use a lot of space to simulate it. RE: [Help] Envy the Dead Developemt & Scripting Questions - plutomaniac - 03-20-2013 spaces do not seem to be registered for some reason. Of course I tried that first. RE: [Help] Envy the Dead Developemt & Scripting Questions - plutomaniac - 03-21-2013 Is there a way to add 1 to a global variable? I tried many things and this is the best I have though to do so far: PHP Code: int tempvar = 0; EDIT: Go it! This works instead: PHP Code: void Something(string &in entity, string &in type) |