Results 1 to 4 of 4
  1. #1
    MSgt. Shooter Person
    Join Date
    Dec 2011
    Posts
    110

    Default Listen Kismet event in Unreal Script

    Hi to all community.

    My question is in subj. I'm trying to limit some functions in UnrealScript that they work only at certain times.
    But that certain times are specified in the Kismet.
    It is possibly?
    Thanks

  2. #2
    MSgt. Shooter Person
    Join Date
    Dec 2011
    Posts
    110

    Default

    *bump *

  3. #3

    Default

    If you just need to turn on/off something, you can simply create the OnToggle function in your class that needs to be modified by kismet with the already implemented Toggle kismet action, like this :

    Code:
    class YourClass extends AnotherClass;
    
    // ...
    
    function SetEnabled(bool Enable) {
    	bEnabled = Enable;
    	if (Enable)
    		// turn features on (changing a boolean value, changing state, ...)
    	else
    		// turn features off (changing a boolean value, changing state, ...)
    }
    
    function OnToggle(SeqAct_Toggle Action) {
    	if (Action.InputLinks[0].bHasImpulse)
    		SetEnabled(true);
    	else if (Action.InputLinks[1].bHasImpulse)
    		SetEnabled(false);
    	else if (Action.InputLinks[2].bHasImpulse)
    		SetEnabled(!bEnabled);
    }
    
    // ...
    If it is not sufficient, you can create your own SequenceAction for Kismet, so this action will be able to do what you want with any object you want in Unrealscript. It will only need to have a reference to the object that you want to affect.
    Last edited by Jereak; 08-13-2012 at 06:45 AM.

  4. #4
    MSgt. Shooter Person
    Join Date
    Dec 2011
    Posts
    110

    Default

    It's great. Thank you, you made my day


 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Copyright ©2009-2011 Epic Games, Inc. All Rights Reserved.
Digital Point modules: Sphinx-based search vBulletin skin by CompletevB.com.