Button With Wait Time At -1 Doesn't Reset?

dignomedignome Join Date: 2003-08-04 Member: 18853Members, Constellation, Reinforced - Shadow
<div class="IPBDescription">um, why?</div> I was scripting a sequence of entities for an ns map and noticed that a func_button with wait time of -1 doesn't reset on next round.....seriously why would they do that?

I'm new to ns mapping, usually on most mods the button actually resets....sucks now because I have to use globals to make the button stop triggering stuff.


also what is with the game not having a round start/end entity for triggering stuff?

Comments

  • TequilaTequila Join Date: 2003-08-13 Member: 19660Members
    Sit down, this is serious. I'm afraid that it didn't reset because of one simple factor, you haven't been giving funds to your local Christian church. God is angry with you, so has saw fit to fiddle with your entities (sounds filthy, I know) and thus you're in this situation.

    Well no, that's a pack of lies. Honestly I think it's something to do with the NS game code, some entities just don't reset round after round <!--emo&???--><img src='http://www.unknownworlds.com/forums/html/emoticons/confused.gif' border='0' style='vertical-align:middle' alt='confused.gif'><!--endemo-->
  • dignomedignome Join Date: 2003-08-04 Member: 18853Members, Constellation, Reinforced - Shadow
    Right on the money about the church ;p


    Any ideas on when they might fix this, maybe in 2.1? I think a few peeps would love a round start/end entity that can target.
  • dignomedignome Join Date: 2003-08-04 Member: 18853Members, Constellation, Reinforced - Shadow
    bah, rotating doors don't reset either....i'm getting the feeling that 2.0 successfully did nothing for us entity lovers. oh well, it's fun playing it ;p


    any good tutorial links for using <b>2.0</b> entities?
  • CageyCagey Ex-Unknown Worlds Programmer Join Date: 2002-11-15 Member: 8829Members, Retired Developer, NS1 Playtester, Constellation
    edited August 2003
    <!--QuoteBegin--dignome+Aug 19 2003, 08:33 PM--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> (dignome @ Aug 19 2003, 08:33 PM)</td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> I was scripting a sequence of entities for an ns map and noticed that a func_button with wait time of -1 doesn't reset on next round.....seriously why would they do that? <!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
    The entity code wasn't designed for round-based gameplay--Half-Life maps traditionally reload from scratch after every game, resetting their state from disk. The lack of reset is an artifact of the original code, not a design decision. The question shouldn't be "why would they do that?", but "when can they fix that?" <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->

    Personally, I'd look into a function added to the base entity class to recall state after each round using the strings passed from the BSP file during entity creation, but that might be more robust than what the NS team would like to do.
  • dignomedignome Join Date: 2003-08-04 Member: 18853Members, Constellation, Reinforced - Shadow
    I figured out how to trigger by round. This only works when the game has started though (as doors don't function when the game hasn't started)

    things you need: 1 trigger_random
    1 func_button
    1 trigger_changetarget
    something to be triggered on new round (feel like i'm making stew here)

    trigger_random: give it min and max values of zero....actually can be whatever as long as it's short and the same. then on the wait time set it to -1 as described in chromeangel's guide (this entity does reset btw ;p). now turn off smart edit and add in the name of your func_button and a value of 0...have no idea if 0 is a time call or not in this list. also on the flags tab, check "start on".

    func_button: give the func_button a target value pointing to the trigger_changetarget 'name' value. keep the "wait to reset" and "delay" near 0 on the func_button.

    trigger_changetarget: 'target' indicates the func_button in this case, so be careful. set the target value to the func_button name value. then set the "new target" value to the thing you want triggered on a new "round"


    note: you have to do all of the above because trigger_random is called twice....once on load of map and again on game start.
    You don't have to do yours this way, it's just something I rigged up.
    (my map now works which is really awesome, now i just need to concentrate on visuals)

    flayra can i have a round start/end entity...i've been good i swear.
  • PapercutPapercut Join Date: 2003-01-23 Member: 12656Members
    A simple solution would be to not use doors...

    Okay, you might have to add some extra twists and turns in your corridors and whatnot, but atleast you dont have to think about resetting and all that other crap.

    <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->
  • dignomedignome Join Date: 2003-08-04 Member: 18853Members, Constellation, Reinforced - Shadow
    My god, if I just gave myself enough time to mess with the entities I probably would have never posted. I literally made an engine from entities that counts off and triggers like a multi_manager (well it uses a multi-manager on a 1 second interval but is shut off next round anyway) but resets on the next round ;p I'll post it sometime. I'd like to thank everyone for putting up with my noob questions, and answering them. I'll do the same if it's a good question on entities.

    doors seem to reset fine, i just didn't realise they don't toggle without new round being triggered.

    /me loves entities....goes off to make some more funkiness
Sign In or Register to comment.