Author Topic: More builtin changes  (Read 5388 times)

0 Members and 1 Guest are viewing this topic.

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
More builtin changes
One of the more annoying things about built-in messages is that you'll hear the same one over and over again if the pilot is given the same order more than once. While looking at the code today I noticed that it was actually fairly easy to change this. The game now supports as many built-in messages as you want for any persona (although I may limit this to a sane number like 10 or so). You must remember that all built-in messages (not just the ones from this mission) + scripted messages (i.e the ones the FREDder added to this mission) must be less than the MAX_MISSION_MESSAGES which is currently 1000.

Standard rules for my builds apply (i.e don't use any of the new features for anything you want to release on 3.6.10 Official as it will probably be a couple of months before all this stuff is in trunk and it will never be in 3.6.10.)

EDIT : Build modified to include support for the High Praise builtin message type. This plays a different praise message if the player has more than 10 kills. If the message doesn't exist the game will play the old praise message instead.

EDIT 2 : Added the Primaries Low builtin type too. It will be used instead of the more generic rearm message if a ship is low on bullets.

*Other Features*
---------------

  • Advanced Team Loadout Functions
  • Ability to play cutscenes before Fiction, Command Brief, Brief, Game Start and Debrief.
  • Various multiplayer SEXP fixes detailed here.
  • Ability to chat to team mates only in TvT games briefings using /f:
  • Praise Self built-in message support (as described here). NB I'm likely to change how often these play in some way.
  • New SEXPs
    • do-for-valid-arguments
    • validate-argument
    • afterburner-energy-pct
    • weapon-energy-pct
    • get-damage-caused
    • primary-fired-since
    • secondary-fired-since
    • set-afterburner-energy
    • set-weapon-energy
    • set-shield-energy
    • set-ambient-light
    • set-respawns


Here's the build.
« Last Edit: May 09, 2009, 05:42:22 am by karajorma »
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: More builtin changes
Oh, man. I can't wait to try this out.

 

Offline Dark RevenantX

  • 29
  • anonymity —> animosity
Re: More builtin changes
The energy pct will be extremely helpful for me.  Thanks.

 

Offline Deckard

  • 27
  • DECK-A-R&D
Re: More builtin changes
Olé! ( great! ) ;)
-------------------------------
Deckard a.k.a The Silencer

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: More builtin changes
If anyone has any ideas for builtin messages that aren't already mentioned on this thread. Now's the time to ask, while how to add them is still fresh in my mind. :)

Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Angelus

  • 210
  • The Angriest Angel
Re: More builtin changes
If anyone has any ideas for builtin messages that aren't already mentioned on this thread. Now's the time to ask, while how to add them is still fresh in my mind. :)



Dunno if it's feasible or useful, but what about "environmental" based messages?
Warnings that get played in nebulae and asteroid fields only.
If  a player for instance is supposed to guard a ship in a asteroid field the wingman send warnings that "more rocks closing to the ship" or something like that.

Would it be possible to send buildin messages based on how many asteroids are closing to the ship?

While that stuff is FREDable, i think it might save the FREDed some time when such messages are played by default.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: More builtin changes
Builtins aren't just meant to save FREDders time though. They're meant to be there for things that are impossible or tediously difficult to set up without them.

In the example above you could just have the the guarded ship say that message. Changing it into a builtin forces you to come up with a line (and get it voice acted) for every single persona you have.

Which does remind me of an issue I forgot to mention. If you are using any of the new messages you must ensure that you have a version for every single persona as if the game fails to find a message for Persona A it will simply look to see if any other Persona has that message and will play that one instead.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Tolwyn

  • The Admiral
  • Administrator
  • 214
  • Ridiculously Old Fraud
    • Wing Commander Saga
Re: More builtin changes
Which does remind me of an issue I forgot to mention. If you are using any of the new messages you must ensure that you have a version for every single persona as if the game fails to find a message for Persona A it will simply look to see if any other Persona has that message and will play that one instead.

Meaning, that the ship in question will send the message using a different persona or will the game switch to next available wingman, that does have the required voice line?
Wing Commander Saga: A Legend Is Reborn | WingCenter
 
Tolwyn’s reputation for risk taking with other people’s lives was considered  to understate the facts. The admiral’s willingness to sacrifice anyone or anything to achieve his objectives had long been lauded in the popular press. He was “the man who got things done”.- Colonel Blair

No errors, no random CTDs, just pure fun and proof of why getting hit with missiles is a bad thing.
-WC Saga's beta tester


Report Wing Commander Saga bugs with Mantis

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: More builtin changes
The code works like this.

1) Select a random ship for the message if applicable (e.g Behind You, Praise, etc Death, Rearm, etc will have already specified a ship).
2) See if there is a message for that persona. Send from the ship from 1)
3) If 2) failed, see if there is a message for a different person. Send from the ship from 1)
4) Give up.

So if the persona doesn't have a certain message but other do the message will come from the right ship but the wrong persona. Unfortunately there is no way to change this without substantial re-engineering of the code. Which is why I suggested that if you use any new message, you make sure that all personae have that message. That is actually the way the game has always worked.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Aardwolf

  • 211
  • Posts: 16,384
    • Minecraft
Re: More builtin changes
That's ... odd. Would it be difficult to change that to be customizable? I haven't looked much at the files for personas (other than the audio files and tstrings.tbl), so I don't really know what that end is like.

  

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: More builtin changes
It's a little odd but quite frankly you should be providing full support to any new builtins or none at all anyway. That's how FS2 did it. (In fact FS2 has a bunch of recorded lines for builtins that aren't ever used).
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 
Re: More builtin changes
Is there also a "High Own Praise", as in someone saying "Damn, I lost count of my kills!"?

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: More builtin changes
Nope. AI don't keep track of their kills but I suppose it might  be possible to work out the number from the log.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]