Release EDDI Scripts and EDDI enabled VA Commands Thread

I looked for a variable for "max fuel per jump", but no luck. It is a rare secondary effect that could lower your jumps per tank and my code will not account for that.

If you know the max fuel per jump value, could you manually edit the code to reflect this? I really like this script, but it's not accurate with and engineered FSD. :(
 
If you know the max fuel per jump value, could you manually edit the code to reflect this? I really like this script, but it's not accurate with and engineered FSD. :(

I'm not interested in doing this myself, but perhaps you could write some code that could "learn" this.
- Each time you jump it would compare the fuel used to a variable and replace the variable value if the fuel used was larger.
- You could use a dynamically named variable that correlates with each ship you use so that you could have a different value per ship.
The variable would not be persistent across play sessions if you're using EDDI standalone. With VoiceAttack, however, I believe that you may be able to use the SetState function to send the variable to VoiceAttack, then re-load it later from VoiceAttack by adding some code to ((EDDI commander continued)).

An alternative approach, that cares less about max fuel and more about having a few jumps left when giving the low fuel warning, might be something like the following (this code sounds a warning when I have about 2.5 jumps left in the tanks and scales if I'm in economy mode):
Code:
{if (event.fuelused * 2.5) > event.fuelremaining:
   {OneOf("Warning:", "Caution:", "Danger:", "Attention:")} 
   {Occasionally(2, "{P(ShipName())}s" )}
   Fuel 
   {OneOf("levels", "tanks", "reserves")} 
   are 
   {OneOf("dangerously low.", "almost depleted.")} 
   {OneOf("Please refuel.", "Refueling is strongly recommended.")}
}
 
Last edited:
Inspired by the original post, this also tells you your remaining number of max jumps with warnings.

Code:
{set fc to ship.frameshiftdrive.class}
{set fg to ship.frameshiftdrive.grade}
{set fttc to ship.fueltanktotalcapacity}
{set fr to event.fuelremaining}
{set fuellevel to (fr/fttc ) * 100}

{if   fc=2 && fg='E': {set mf to 0.6}
|elif fc=2 && fg='D': {set mf to 0.6}
|elif fc=2 && fg='C': {set mf to 0.6}
|elif fc=2 && fg='B': {set mf to 0.8}
|elif fc=2 && fg='A': {set mf to 0.9}
|elif fc=3 && fg='E': {set mf to 1.2}
|elif fc=3 && fg='D': {set mf to 1.2}
|elif fc=3 && fg='C': {set mf to 1.2}
|elif fc=3 && fg='B': {set mf to 1.5}
|elif fc=3 && fg='A': {set mf to 1.8}
|elif fc=4 && fg='E': {set mf to 2.0}
|elif fc=4 && fg='D': {set mf to 2.0}
|elif fc=4 && fg='C': {set mf to 2.0}
|elif fc=4 && fg='B': {set mf to 2.5}
|elif fc=4 && fg='A': {set mf to 3.0}
|elif fc=5 && fg='E': {set mf to 3.3}
|elif fc=5 && fg='D': {set mf to 3.3}
|elif fc=5 && fg='C': {set mf to 3.3}
|elif fc=5 && fg='B': {set mf to 4.1}
|elif fc=5 && fg='A': {set mf to 5.0}
|elif fc=6 && fg='E': {set mf to 5.3}
|elif fc=6 && fg='D': {set mf to 5.3}
|elif fc=6 && fg='C': {set mf to 5.3}
|elif fc=6 && fg='B': {set mf to 6.6}
|elif fc=6 && fg='A': {set mf to 8.0}
|elif fc=7 && fg='E': {set mf to 8.5}
|elif fc=7 && fg='D': {set mf to 8.5}
|elif fc=7 && fg='C': {set mf to 8.5}
|elif fc=7 && fg='B': {set mf to 10.6}
|elif fc=7 && fg='A': {set mf to 12.8}
|else: error; unknown frame shift drive. Cannot determine max fuel per jump.
}

{set mjr to fr/mf}

{if fuellevel < 25: Warning;
   |elif fuellevel <50: Caution;
}

fuel level at {Humanise(fuellevel)} percent.

{if mjr <1: You do not have enough fuel for a max jump. Refuel as soon as possible.
   |elif mjr <2: You have fuel for only one max jump.
   |else: {floor(mjr)} max jumps remain.
}

I like this addition and have added it to my 'Jumped' script. I also made a few alterations to it. Some cosmetic, like fleshing out the variable names ('cos I'm picky! Lol! ;) ), and also I re-wrote the main part of the code to make it shorter, tidier, more efficient (sorry, I like to do that kind of thing too), and to give a little more variety in the spoken sentence at low fuel levels.

Here's my version which is functionally similar, just shorter and now includes the Class 8 FSD. Apparently, class 8 has the same max fuel per jump as class 7 (taken from Roguey's site). Also, if you manage to get an increase/decrease in max fuel per jump at an engineer, you will need to manually update the 'maxfuel' next to your FSD grade/class in the script.

Code:
{set class to ship.frameshiftdrive.class}
{set grade to ship.frameshiftdrive.grade}
{set fuelremaining to event.fuelremaining}
{set fuellevel to (fuelremaining/ship.fueltanktotalcapacity)*100}

{if grade='E' || grade='D' || grade='C':
    {if class=2: {set maxfuel to 0.6}
    |elif class=3: {set maxfuel to 1.2}
    |elif class=4: {set maxfuel to 2.0}
    |elif class=5: {set maxfuel to 3.3}
    |elif class=6: {set maxfuel to 5.3}
    |elif class=7 || class=8: {set maxfuel to 8.5}
    }
|elif grade='B':
    {if class=2: {set maxfuel to 0.8}
    |elif class=3: {set maxfuel to 1.5}
    |elif class=4: {set maxfuel to 2.5}
    |elif class=5: {set maxfuel to 4.1}
    |elif class=6: {set maxfuel to 6.6}
    |elif class=7 || class=8: {set maxfuel to 10.6}
    }
|elif grade='A':
    {if class=2: {set maxfuel to 0.9}
    |elif class=3: {set maxfuel to 1.8}
    |elif class=4: {set maxfuel to 3.0}
    |elif class=5: {set maxfuel to 5.0}
    |elif class=6: {set maxfuel to 8.0}
    |elif class=7 || class=8: {set maxfuel to 12.8}
    }
}

{set maxjump to fuelremaining/maxfuel}

{if fuellevel < 25: Warning;
|elif fuellevel <50: Caution;
}

Fuel level at {Humanise(fuellevel)}%.

{if maxjump <1:
   {OneOf("You do not have enough fuel for a max jump","Fuel reserves depleted")}.
   Refuel {OneOf("as soon as possible.","at the {OneOf('earliest','soonest')} opportunity")}.
|elif maxjump <2: {OneOf("You have fuel for only one max jump","Fuel for only one max jump remains")}.
|else: {floor(maxjump)} max jumps remain.
}
 
I couldn't resist the temptation to improve on my last post already. ;)

I've taken the script and put it in a new function called 'JumpFuel'. I've added EDDI context to it, and to my original 'Jumped' and 'Ship Refuelled' events, so that it can report fuel and jumps remaining at any time, when called with VA or another script.

My 'JumpFuel' function:
Code:
{set fuelremaining to state.eddi_context_fuel_remaining}
{set class to ship.frameshiftdrive.class}
{set grade to ship.frameshiftdrive.grade}
{set fuellevel to (fuelremaining/ship.fueltanktotalcapacity)*100}

{if grade='E' || grade='D' || grade='C':
    {if class=2: {set maxfuel to 0.6}
    |elif class=3: {set maxfuel to 1.2}
    |elif class=4: {set maxfuel to 2.0}
    |elif class=5: {set maxfuel to 3.3}
    |elif class=6: {set maxfuel to 5.3}
    |elif class=7 || class=8: {set maxfuel to 8.5}
    }
|elif grade='B':
    {if class=2: {set maxfuel to 0.8}
    |elif class=3: {set maxfuel to 1.5}
    |elif class=4: {set maxfuel to 2.5}
    |elif class=5: {set maxfuel to 4.1}
    |elif class=6: {set maxfuel to 6.6}
    |elif class=7 || class=8: {set maxfuel to 10.6}
    }
|elif grade='A':
    {if class=2: {set maxfuel to 0.9}
    |elif class=3: {set maxfuel to 1.8}
    |elif class=4: {set maxfuel to 3.0}
    |elif class=5: {set maxfuel to 5.0}
    |elif class=6: {set maxfuel to 8.0}
    |elif class=7 || class=8: {set maxfuel to 12.8}
    }
}

{set maxjump to fuelremaining/maxfuel}

{if fuellevel < 25: Warning;
|elif fuellevel <50: Caution;
}

Fuel {OneOf("level","tanks")} at {Humanise(fuellevel)}% {Occasionally("capacity")}.

{if maxjump <1:
   {OneOf("You do not have enough fuel for a max jump","Fuel reserves depleted")}.
   Refuel {OneOf("as soon as possible.","at the {OneOf('earliest','soonest')} opportunity")}
|elif maxjump <2: {OneOf("You have fuel for only one max jump","Fuel for only one max jump remains")}
|else: {floor(maxjump)} max jumps remain
}
My 'Jumped' event script:
Code:
{_ Context }
{SetState('eddi_context_last_subject', 'jump')}
{SetState('eddi_context_last_action', 'complete')}
{SetState('eddi_context_system_name', system.name)}
{SetState('eddi_context_system_system', system.name)}
{SetState('eddi_context_fuel_remaining', event.fuelremaining)}

{if SystemDetails(state.eddi_context_system_system).population > 0:
    {F("System state report")}
}

{F("JumpFuel")}.
(Note: As reporting the system state was removed from EDDI's original 'Jumping' script because it didn't work properly there, I reinstated it in my 'Jumped' script as it seems to work fine here. I also made it only report if the system is populated.)

My 'Ship Refuelled' event script:
Code:
{SetState('eddi_context_last_subject', 'refuelling')}
{SetState('eddi_context_last_action', 'complete')}
{SetState('eddi_context_fuel_remaining', event.total)}
{set fueltotal to ship.fueltanktotalcapacity}

{if event.source = "Market":
   {Occasionally(2,"{OneOf('{ShipName()}','Ship')}")}
   {OneOf("re-fuelled","fuel tanks topped up","tanks re-filled")}
   {Occasionally(3,". Tanks at 100%")}
|else:
   {set tot to 100/fueltotal*event.total}
   {OneOf("{round(tot,1)} per cent refuelled", "{round(event.amount,2)} tonnes taken on board")}.
   {if tot = "100":
      {Occasionally(2,"Main")}
      {Occasionally(2,"Fuel")}
      Tanks at {OneOf("Maximum","100%")}
      {Occasionally(2,"capacity")}
   |else: {F("JumpFuel")}
   }
   {Occasionally(4,"{F('Honorific')}")}.
}
.

The only potential problem I can foresee, is when you first load EDDI as there will be no fuel remaining data to report.
 
Last edited:
I wrote a small C# program to watch the logs and trigger some keystrokes like "gear up" after "undocking" or "throttle to zero" after "jump". But as I saw, EDDI perfectly capturing all this stuff and more I like to ask if there is a way to send keystrokes directly out of the TTS scripts to achieve this functions without using voice attack?
 
Hi @omega9380,

EDDI is a great tool, is there a way to make EDDI only report when I ask for it, or to say "reporting off" and EDDI will only talk when I ask for status report?
It's because with the multi crew in VA (HCSPACKS) they are sometime talking on top of each other and that is driving me mad... :D
 
I wrote a small C# program to watch the logs and trigger some keystrokes like "gear up" after "undocking" or "throttle to zero" after "jump". But as I saw, EDDI perfectly capturing all this stuff and more I like to ask if there is a way to send keystrokes directly out of the TTS scripts to achieve this functions without using voice attack?

When you use VoiceAttack (cost 10 bugs) then EDDI can run as plugin and allow you (or better VA) to do this. EDDI on its own goes only one way (game to TTS)

Hi @omega9380,

EDDI is a great tool, is there a way to make EDDI only report when I ask for it, or to say "reporting off" and EDDI will only talk when I ask for status report?
It's because with the multi crew in VA (HCSPACKS) they are sometime talking on top of each other and that is driving me mad... :D

You can change the scripts so they do what you want. And if you use VA then there are some functions that might help you with this.
https://github.com/cmdrmcdonald/EliteDangerousDataProvider/blob/master/VoiceAttack.md#functions

oh, btw tell jgm how awesome EDDI is, he will appreciate it ;)
https://forums.frontier.co.uk/showthread.php/294579-EDDI-Windows-app-for-immersion-and-more
 
When you use VoiceAttack (cost 10 bugs) then EDDI can run as plugin and allow you (or better VA) to do this. EDDI on its own goes only one way (game to TTS)



You can change the scripts so they do what you want. And if you use VA then there are some functions that might help you with this.
https://github.com/cmdrmcdonald/EliteDangerousDataProvider/blob/master/VoiceAttack.md#functions

oh, btw tell jgm how awesome EDDI is, he will appreciate it ;)
https://forums.frontier.co.uk/showthread.php/294579-EDDI-Windows-app-for-immersion-and-more

Yeah, Credit where it belongs :)

However I only use it with VA multi crew profile, got it with my ASTRA voice pack, so don't know much about coding.
 
I wrote a small C# program to watch the logs and trigger some keystrokes like "gear up" after "undocking" or "throttle to zero" after "jump". But as I saw, EDDI perfectly capturing all this stuff and more I like to ask if there is a way to send keystrokes directly out of the TTS scripts to achieve this functions without using voice attack?

There's no way of doing this at the moment. Rather than overload the speech responder this would probably be a separate responder that would provide the ability to send keypresses, but it's not no the list to do at the moment I'm afraid. For now VoiceAttack is the best way to go for this type of function.
 
Hi @omega9380,

EDDI is a great tool, is there a way to make EDDI only report when I ask for it, or to say "reporting off" and EDDI will only talk when I ask for status report?
It's because with the multi crew in VA (HCSPACKS) they are sometime talking on top of each other and that is driving me mad... :D

Today you can totally disable the speech responder, although it's not a perfect solution because by doing this EDDI loses its "memory" of what it is saying so the contextual commands won't work. To fix this, the next version of EDDI will have the ability to tell the speech responder to be quieter, only speaking when asked for something, but still keeping an internal note of everything that happens.

If you do want to disable the speech responder entirely from VoiceAttack you can find details as to how to do this at https://github.com/cmdrmcdonald/EliteDangerousDataProvider/blob/master/VoiceAttack.md
 
Hi,

I wrote a very simple script for Request Docking. For me, it was a little bit strange feeling just to fly in to a station without saying 'Hello', or anything. Now, when I request docking permisson, there is a conversation-like thing happening, which gives me a more realistic and more personal feeling. One important thing: throttle has to be set to 0%, when you are requesting docking permission! The timing of the conversation works this way.

{event.station}, {ShipName()} is checkin' in.

{Pause(8000)}

{OneOf(
"Controls are in your hands now!",
"Hi honey, I'm home!",
"Santa Claus is back in town!",
"Show me the way home honey!",
"Watch the paint, when parking my ship!",
"One huge cheese-burger with hot sauce, pommes frites with chili salsa and a big cup of milk, please, for take-away! Thanks!",
"Who ordered pizza with extra pepperoni?")}.

My other try was to make a 'Good bye' script, which would also warn me, that I can turn on my FSD (when Mass locked state goes off), but it doesnt work perfectly:( I tried to attach it to the 'Station no fire zone exited', it works in case of planetary stations, and in most cases when leaving orbital stations. But unfortunately, there are some situations, when the timing doesn't work.

Do you guys have any idea, how to trigger this message with mass locked off state (or distance to station>5.5km, or anything)?

This is how it looks like (crazy-complicated:) ):

{Pause(5500)}

{ShipName()} is checkin' out, good bye! Mr. Zulu, Warp 5!

Best regards!
 
Hi,

I wrote a very simple script for Request Docking. For me, it was a little bit strange feeling just to fly in to a station without saying 'Hello', or anything. Now, when I request docking permisson, there is a conversation-like thing happening, which gives me a more realistic and more personal feeling. One important thing: throttle has to be set to 0%, when you are requesting docking permission! The timing of the conversation works this way.



My other try was to make a 'Good bye' script, which would also warn me, that I can turn on my FSD (when Mass locked state goes off), but it doesnt work perfectly:( I tried to attach it to the 'Station no fire zone exited', it works in case of planetary stations, and in most cases when leaving orbital stations. But unfortunately, there are some situations, when the timing doesn't work.

Do you guys have any idea, how to trigger this message with mass locked off state (or distance to station>5.5km, or anything)?

This is how it looks like (crazy-complicated:) ):



Best regards!

Ok I feel completely stupid, where do these script go and what is the syntax for using it with VA???

If I want to use this "enablespeechresponder/disablespeechresponder" with VA where do i put it and what is the syntax .....aggghhh give me a hammer and some metal, but this....
 
Last edited:
If you know the max fuel per jump value, could you manually edit the code to reflect this? I really like this script, but it's not accurate with and engineered FSD. :(

A bit late (I wish I could get notifications for replies and quoted text). YES. That's what I did. Find your modded fsd and edit mf
 
Hi,

I wrote a very simple script for Request Docking. For me, it was a little bit strange feeling just to fly in to a station without saying 'Hello', or anything. Now, when I request docking permisson, there is a conversation-like thing happening, which gives me a more realistic and more personal feeling. One important thing: throttle has to be set to 0%, when you are requesting docking permission! The timing of the conversation works this way.



My other try was to make a 'Good bye' script, which would also warn me, that I can turn on my FSD (when Mass locked state goes off), but it doesnt work perfectly:( I tried to attach it to the 'Station no fire zone exited', it works in case of planetary stations, and in most cases when leaving orbital stations. But unfortunately, there are some situations, when the timing doesn't work.

Do you guys have any idea, how to trigger this message with mass locked off state (or distance to station>5.5km, or anything)?

This is how it looks like (crazy-complicated:) ):



Best regards!

There is an event on no-fire zone enter/exit that can be used to trigger a message.
 
Ok I feel completely stupid, where do these script go and what is the syntax for using it with VA???

If I want to use this "enablespeechresponder/disablespeechresponder" with VA where do i put it and what is the syntax .....aggghhh give me a hammer and some metal, but this....

Okay, so you need to create a new VoiceAttack command. The first thing you want to do is decide what you want to say to trigger the command. For disabling the speech responder I'm using a simple 'Be quiet' and for re-enabling it 'You may talk' but obviously you can set it to whatever you want.

In terms of setting the command: create a new command and set your trigger as above in the 'When I Say' bit. Then you need to set up a plugin function. This is away in the 'Other'->'Advanced'->'Execute an External Plugin Function' menu as shown here:

2HzIcro.png


Once you've selected this item you just need to set the context as per the docs, so in this case it would look like this:

FUAq0Uv.png


And that's pretty much it. Now when you say 'Be quiet' it will call the EDDI plugin, tell it to disable the speech responder, and off you go. You'll want to build another command for re-enabling it.
 
Okay, so you need to create a new VoiceAttack command. The first thing you want to do is decide what you want to say to trigger the command. For disabling the speech responder I'm using a simple 'Be quiet' and for re-enabling it 'You may talk' but obviously you can set it to whatever you want.

In terms of setting the command: create a new command and set your trigger as above in the 'When I Say' bit. Then you need to set up a plugin function. This is away in the 'Other'->'Advanced'->'Execute an External Plugin Function' menu as shown here:

http://i.imgur.com/2HzIcro.png

Once you've selected this item you just need to set the context as per the docs, so in this case it would look like this:

http://i.imgur.com/FUAq0Uv.png

And that's pretty much it. Now when you say 'Be quiet' it will call the EDDI plugin, tell it to disable the speech responder, and off you go. You'll want to build another command for re-enabling it.

Thank you, thank you, thank you, now I understand :D I bow to your infinite wisdom, no joking around here, oh boy oh boy that was much easier than I expected :)

[up] [up] [up] [up] [up] [up] [up] [up]
 
There is an event on no-fire zone enter/exit that can be used to trigger a message.

Hmm... maybe there is something wrong with my english. I wrote:

"I tried to attach it to the 'Station no fire zone exited', it works in case of planetary stations, and in most cases when leaving orbital stations. But unfortunately, there are some situations, when the timing doesn't work."

I was trying to say, that I'm aware of the existence of the 'Station no fire zone exited' event, tried it, but it is not doing its job properly in case of the "mass locked off, turn on FSD" message.

Thanks anyway.
 
Back
Top Bottom