Page 42 of 42 FirstFirst ... 323839404142
Results 616 to 623 of 623

Thread: EDDI Scripts and EDDI enabled VA Commands Thread

  1. #616
    The problem is it doesn't read ANY variable, I mean, my output is exactly "In the system is controlled by the faction, in a state of, with a goverment, and security level. It is a. This station is light seconds from the star and alligned to, with an economy of".
    I'm using Eddi 2.4.5, live game, and triggering the script in normal space, just out of station, with the station targetted. Even inside the result is the same. That's why I was asking if the script needs some "set" to recognize the station.

    Edit: Ok, just entering the game, inside the station's hangar the script works, once I go to the station's surface lvl no longer works nor if I back to hangar.

  2. #617
    Hi, everyone just wanted to thank you for some great work and keep it up. Iím not a programmer but have been able to tweak things thanks to the help. When I do a body scan using a DSS I get an update with the number of rings and what the reserves are (pristine,etc) but I cannot work out how to get it to tell me the type of rings (metallic,etc). Can anyone point me in the right direction please?

  3. #618
    Are you running your tests right as you begin a play session? It might take a mode change (landing, takeoff, supercruise entry, supercruise exit, or similar before EDDI fully orients and populates the station and system objects.

    Originally Posted by Talone View Post (Source)
    Hi, everyone just wanted to thank you for some great work and keep it up. Iím not a programmer but have been able to tweak things thanks to the help. When I do a body scan using a DSS I get an update with the number of rings and what the reserves are (pristine,etc) but I cannot work out how to get it to tell me the type of rings (metallic,etc). Can anyone point me in the right direction please?
    Here's what I use:
    Code:
        {if len(reportbody.rings):
            with {if len(reportbody.rings) = 1: a}
            {if find(reportbody.reserves, "Pristine") >= 0:
                pristine
            |elif find(reportbody.reserves, "Major") >= 0:
                rich
            }
            {set ringname to []}
            {set ringcomposition to []}
            {for Ring in reportbody.rings:
                {set ringcomposition to cat(ringcomposition, [Ring.composition])}
            }
            {if len(ringcomposition) > 0:
                {List(ringcomposition)}
            }
            {if find(ringname[0], "Belt") >= 0: 
                {set ring to "belt"}
            |else:
                {set ring to "ring"}
            }
            {ring}{if len(reportbody.rings) > 1 || len(event.rings) > 1:s}
        }
    Example output: "with pristine rocky and metallic rings"

  4. #619
    Originally Posted by Tkael View Post (Source)
    Are you running your tests right as you begin a play session? It might take a mode change (landing, takeoff, supercruise entry, supercruise exit, or similar before EDDI fully orients and populates the station and system objects.
    I thought something like that would be happening, but anyway I find weird how just undocking makes the recently information dissapears; currently the station report is giving me info only when docked, so I assume that is the intended use?

  5. #620
    Originally Posted by Kroiden View Post (Source)
    I thought something like that would be happening, but anyway I find weird how just undocking makes the recently information dissapears; currently the station report is giving me info only when docked, so I assume that is the intended use?
    I can't speak to JGM's original intentions, but that appears to be be in-line with what I'm seeing in the code. EDDI only fills the station object when it detects that you are docked, and removes that station object information once you undock (I imagine that his purpose for doing this was to prevent EDDI from acting on, or reporting, stale data).

    Have you looked into the ReportStation() function yet? It allows you to query the server for information about a station even when you are not docked.

  6. #621
    Originally Posted by Tkael View Post (Source)
    Have you looked into the ReportStation() function yet? It allows you to query the server for information about a station even when you are not docked.
    Uff, couldn't do that. I just learned Basic language there in the '80s, and didn't see more than C basic concepts, so can't go deeper into scripting. So, which code should I add in order to trigger the station report outside of the station, just targetting it?

    Btw, saw some videos of HCS voice packs with the "On my mark" script that makes voiceattack to start a timer waiting for a command to trigger. Loved that, it would be possible make one saying "On my mark... disengage", and triggering with the order "Now"?. I got some examples but not exactly what I pretend and besides they were incompletes.
    Thanks in advance.

    Edit: Ok, with some help in the voiceattack forum I managed to do the "On my mark" stuff. Sorry if this forum is more Eddi concerned, but this is such a cool feature that I need to share it ^^ Note that you can make all "(x order on my mark)" you want and just 1 general trigger, even having one command and same command adding "on my mark" has no conflicts and works fine, recognizing both of them separately. Here goes my own commands:

    - General trigger:
    When I say: [dissengage; now]

    Set Boolean [mark] to True


    - Optimal impulse on my mark (I use this one when going max supercruise speed approaching to a station/planet, so when I reach 0:07 I say the trigger order and speed goes to 75% -blue zone-. Note that my 75% speed is set to key F2):
    When I say: [optimal impulse] [on my mark;]

    Begin Text Compare: [{CMD}] Contains 'on my mark'
    Set Boolean [mark] to False
    Set Text[Script] to '[Acknowledge]'
    Execute external plugin, 'EDDI 2.4.5'
    Start Loop While: [mark] Does Not Equal True
    End Loop
    Set Boolean [mark] to False
    End Condition
    Press F2 key and hold for 0.1 seconds and release
    Set Text[Script] to '[Approach speed set]'
    Execute external plugin, 'EDDI 2.4.5'


    - Disengage on my mark (similar to previous example, I use this one approaching to station/planet/signal etc on supercruise, and triggering when distance and speed bars reach blue zone. Supercruise binded to key J)

    When I say: [disengage] [on my mark;]

    Begin Text Compare: [{CMD}] Contains 'on my mark'
    Set Boolean [mark] to False
    Set Text[Script] to '[Acknowledge]'
    Execute external plugin, 'EDDI 2.4.5'
    Start Loop While: [mark] Does Not Equal True
    End Loop
    Set Boolean [mark] to False
    End Condition
    Press J key and hold for 0.1 seconds and release
    Set Text[Script] to '[Entering normal space]'
    Execute external plugin, 'EDDI 2.4.5'


    As you see the "disengage on my mark" is obviously the same code as "optimal impulse on my mark", the only things that change are the command initial phrase, the key to press (or external command/action to trigger) and the say responses, so you can make all "on my mark" commands you like, just simply copy/pasting and changing those things.

    Hope you find this useful. Original voiceattack thread here if you want to investigate or see other variations.

  7. #622
    Fantastic thank you. Iíll give it a try after work.

  8. #623
    VA/EDDI ASKS TO RAISE THE LANDING GEAR!

    It worked ! I hit Launch from a landing pad, the station flight controller tells me docking clamps have released, I slowly drift upwards and a few seconds later my VA/EDDI profile asks me if I'd like the landing gear raised !!

    I say Yes thank you, and up comes the landing gear !!

    It's so awesome ! This is how I went about doing it:

    Code:

    VA script called ((undocked)) : Set small int (condition) [random] value as random from 1 to 2 //I only wanted a 1 in 2 chance of her using her initiative, so it's not the same all the time, and I still feel like I'm in control of the ship Begin Small Integer Compare : [random] Equals 2 Pause 5 seconds Execute command, 'Ask to retract landinggear' End Condition
    VA script called Ask to retract landinggear : Set small int (condition) [random] value as random from 1 to 2 // Another roll of the dice here, value of 1 makes her ask me to raise gear, value of 2 and she just tells me she is doing it. Begin Small Integer Compare : [random] Equals 1 Set Boolean [Request] to True //This value will be compared later so that nothing happens when I say Yes unless she has actually asked me Set Text [Script] to 'rs_request_landing_gear' //This EDDI script simply generates some random ways of asking "Would you like me to raise the gear?" Execute external plugin, 'EDDI 2.4.5' and wait for return //Execute the above named script Set Text [CMDExecute] to 'Raise landing gear' //This sets the name of the script to execute once I say Yes, because I am going to have her ask me a lot of other things later. Pause 8 seconds // Wait for 8 seconds Set Boolean [Request] to False // after 8 second, set Request to false, so saying Yes after this will not trigger landing gear End Condition - Exit when condition met Begin Small Integer Compare : [random] Equals 2 Set Boolean [Request] to False Set Text [Script] to 'rs_command_landing_gear' //I did another randomly generated speech script in EDDI for telling me, instead of asking me, named rs_command instead of rs_request Execute external plugin, 'EDDI 2.4.5' and wait for return Press G key and hold for 0.03 seconds and release //and just lift the gear End Condition
    EDDI script called rs_request_landing_gear : {OneOf('Shall I','Would you like me to')} {OneOf('raise','retract')} the landing gear {OneOf(' sir',' captain',' commander','','')}? EDDI script called rs_command_landing_gear : {Occasionally(2, 'I am')} {OneOf('raising','retracting', 'bringing up')} the landing gear {Occasionally(2, 'now')} {OneOf(' sir',' captain',' commander','','')}.
    VA command Yes : Begin Boolean Compare : [Request] Equals True //When I say yes, first check that a request has been made, and if so Execute command, '{TXT:CMDExecute}' (by name) (and wait until it completes) //Execute the command by name, which was set as a text value earlier, and is simply the words (as if spoken) "Raise landing gear" Set Boolean [Request] to False //Finish the request Else Set Text [Script] to 'rs_clarify' //If a request has not been made and I say Yes, she will randomly say something along the lines of "Please clarify" Execute external plugin, 'EDDI 2.4.5' and wait for return End Condition VA command No : Begin Boolean Compare : [Request] Equals True Set Boolean [Request] to False Set Text [Script] to 'rs_no' //Give a random speech response along the lines of "Awaiting further instructions" Execute external plugin, 'EDDI 2.4.5' and wait for return Else Set Text [Script] to 'rs_clarify' //otherwise ask for clarification, as per the Yes command Execute external plugin, 'EDDI 2.4.5' and wait for return End Condition

    Thank you kindly Brigetiol1 for your help and for putting up with my PMs asking noob questions! and Josh Calvert for providing me with your example of an alternative way to achieve the same result. It's very much appreciated gentlemen!

    Hope this helps someone else.

Page 42 of 42 FirstFirst ... 323839404142