Jump to content
The simFlight Network Forums

Sabrefly

Members
  • Posts

    142
  • Joined

  • Last visited

Everything posted by Sabrefly

  1. But there are no other logs (textmenu.log?) in WideClient folder. Sorry, I wish I knew what I did wrong? Thanks Igor
  2. Sorry, I didn't realize it crashed! (if it really did) Below is the log: ********* WideClient Log [version 6.999z2] Class=FS98MAIN ********* Date (dmy): 15/11/16, Time 20:26:20.734: Client name is LENA 141 LUA: "C:\MSFS\WideClient\Initial.LUA": not found 203 Attempting to connect now 203 Trying to locate server: Protocol not yet decided 203 Failed to connect: waiting to try again 2203 Attempting to connect now 4203 Server = I6 4203 Trying TCP/IP host "I6" port 8002 ... 4203 ... Okay, IP Address = 192.168.3.67 4203 Connection made okay! 4281 Connection closed by server! 4281 Attempting to connect now 8328 Server = I6 8328 Trying TCP/IP host "I6" port 8002 ... 8328 ... Okay, IP Address = 192.168.3.67 8328 Connection made okay! 297031 ****** End of session performance summary ****** 297031 Total time connected = 288 seconds 297031 Reception maximum: 25 frames/sec, 779 bytes/sec 297031 Reception average whilst connected: 23 frames/sec, 610 bytes/sec 297031 Transmission maximum: 2 frames/sec, 85 bytes/sec 297031 Transmission average whilst connected: 0 frames/sec, 28 bytes/sec 297031 Max receive buffer = 823, Max send depth = 2, Send frames lost = 0 297031 ********* Log file closed (Buffers: MaxUsed 4, Alloc 7682 Freed 7682 Refused 0) ********* Thanks, Igor.
  3. I know this is one of those: "...they pull me back in" moments, Pete, really sorry and thanks for your time! If I replace: wnd.text(w2, msgs[1]) by this: x = 80 --my example of how many characters you want, max mycopy = msgs[1] --make a copy for me to use len = string.len(mycopy) if len > x then --need to split mycopy = string.sub(mycopy,1,x) .. '\r' .. string.sub(mycopy, x+1) end wnd.text(w2, n, mycopy) the windows come up ok but no messages are displayed neither from GSX nor from PATC/X (menus are OK) Thanks, Igor.
  4. I went to the LUA site, I skimmed through LUA string library, but could not find anything I could understand there. Thanks, Igor.
  5. Of course I did that already, and it worked! No worries. I just wanted to have the luxury of a conveniently sized text visible in full on the additional monitor. I wish there was some program like ShowText for my purpose. When somebody knowledgeable has a moment please help me with this. Many thanks, Igor. PS: I'll try to edit as follows: wnd.text (w2, n, msgs[1]) and see what happens. Just pls don't rail or laugh at me :) PSS: It didn't work, of course ))
  6. But also when flying, particularly on longer BAV flights, I switch my main monitor and play NHL17, like below in the picture. Usually I have enough time for a couple of games, sometimes even online. Thats's when it's so helpful to have the info line on the right Monitor, because it may get very noisy in the game and the info window makes sure I won't miss any instruction from PATCX. :) However I'm having only one problem left with your lua now. I can't get long messages from PATC/X moved to the next line instead of getting cut off in the window. I played with some wnd.* parameters but in vain. Is it possible to have long lines word-wrap properly below and not going beyond the window (to the right)? Many thanks, Igor.
  7. Nothing worth your time, Pete! Generally I like to manage GSX/PATCX menus and see their info lines on the main P3D screen. These are my flight gear and monitors during my normal flight:
  8. Pete, one last question here please: I'd like to leave PATC/X information line on P3D screen and have it mirrored on the Client. I have NewInterceptTextMenu=Yes, so menus stay normal on P3D. But PATC/X info line is gone, I can see it only broadcast on the client. What do I need to edit in this lua? (above). Many thanks! Igor.
  9. Oh my! It's like a miracle, I see it now. Honestly I've learnt nothing from the example but your tip was invaluable. I'll try to fasten PROATC/X to your example lua. Thank you so much, Igor. PS: Now I'll just need to decrease the fonts and learn how to get messages move to the next line in the window instead of getting cut off, then I'm ultimately happy.
  10. I have only one video screen on my Client. I will try to use value 0 instead and see what happens. Hacking! Thanks, Igor. PS: sorry, I know nothing about programming, it would be quite a huge undertaking for me. Mostly I can only buy tools and utilities to achieve what I need.
  11. Ok, I'm on P3D v3.3, FSUIPC v4.958, WideClient v6.999z2. I have latest GSX in P3D. AS2016 and PATCX installed on different Clients. My first test is to conjure up GSX menu window and messages on one of my Clients. I first set NewInterceptTextMenu=Full in FSUIPC4.ini. I have the following textmenu.lua in WideClient folder: colours = { 0x000, 0xfff, 0xf00, 0x0f0, 0x00f, 0xff0, 0xf0f, 0x0ff } doshow = 1 shown = 2 textset = false menuset = false time2 = 0 time3 = 0 timeclear2 = 0 timeclear3 = 0 w1 = wnd.open("Radar Contact", WND_FIXED, 1280,0,1024,768) wnd.backcol(w1, 0x000) wnd.textcol(w1, 0x0f0) wnd.font(w1, WND_ARIAL, 24, WND_BOLD) w2 = wnd.open("FSX Text", WND_FIXED, 1280,0,1024,100) wnd.backcol(w2, 0xfff) wnd.textcol(w2, 0x000) wnd.font(w2, WND_ARIAL, 17, WND_BOLD) w3 = wnd.open("FSX Menu", WND_FIXED, 1280,100,1024,668) wnd.backcol(w3, 0x88f) wnd.textcol(w3, 0x000) wnd.font(w3, WND_ARIAL, 17, WND_BOLD) ext.state("FSX Menu", EXT_HIDE) ext.state("FSX Text", EXT_HIDE) ext.state("Radar Contact", EXT_NRML) w1text = ipc.readSTR(0x3380,128) ipc.log(w1text) wnd.text(w1, w1text) local function testifclear() doshow = 1 if menuset or textset then doshow = 2 end if doshow ~= shown then if doshow == 1 then ext.state("FSX Text", EXT_HIDE) ext.state("FSX Menu", EXT_HIDE) ext.state("Radar Contact", EXT_NRML) wnd.clear(w1) wnd.text(w1, w1text) ipc.log("Showing RC") else ext.state("Radar Contact", EXT_HIDE) ext.state("FSX Text", EXT_NRML) ext.state("FSX Menu", EXT_NRML) ipc.log("Showing FSX Menus") end shown = doshow end end local function clearw2() wnd.clear(w2) textset = false testifclear() end function clearw3() wnd.clear(w3) menuset = false testifclear() end function textandmenu(mtype, colour, scroll, delay, id, n, msgs) doshow = 1 if mtype == 2 then -- Menu time3 = 0 if n == 0 then wnd.clear(w3) menuset = false testifclear() else menuset = true testifclear() wnd.clear(w3) wnd.text(w3, " " .. msgs[1]) wnd.text(w3, " ") wnd.text(w3, " " .. msgs[2]) wnd.text(w3, " ") i = 3 j = 1 while i <= n do wnd.text(w3, " " .. j .. " - " .. msgs[i]) i = i + 1 j = j + 1 if (j > 9) then j = 0 end end if delay ~= 0 then timeclear3 = delay * 1000 time3 = ipc.elapsedtime() end end else -- Text time2 = 0 if n == 0 then wnd.clear(w2) textset = false testifclear() else textset = true testifclear() wnd.textcol(w2, colours[colour+1]) wnd.backcol(w2, logic.Xor(colours[colour+1], 0xfff)) wnd.text(w2, msgs[1]) if delay then timeclear2 = delay * 1000 time2 = ipc.elapsedtime() end end end end ctr = 0 function time() ctr = ctr + 1 val = ipc.elapsedtime() if time2 ~= 0 and ((val - time2) > timeclear2) then clearw2() time2 = 0 end if time3 ~= 0 and ((val - time3) > timeclear3) then clearw3() time3 = 0 end if (ctr <= 2) then ipc.togglebitsUW(0x32FA,0xffff) elseif (ctr > 10) then ctr = 0 end end function update1(off, val) w1text = ipc.readSTR(0x3380,128) wnd.clear(w1) wnd.text(w1, w1text) end event.textmenu(0, "textandmenu") event.offset(0x3380, "STR", "update1") event.offset(0x32FA, "UW", "update1") event.timer(500, "time") testifclear() from this post: After WideClient gets connected I open GSX menu. Due to the above code GSX menu opens truncated in the top left corner of my P3D screen. And this is it. No window comes up on the Client, and this must be my problem. Please help me with it. Ultimately I'd like to control GSX and PRO-ATC/X menus from my Client and to see their respective messages on it. For what it matters on the same Client I run as well VAS FSUIPC.lua: -- Create the display window for 2 values, position x=800, y=400 h = display.create("My next display", 2, 800, 400) -- Update the display at 500 msec intervals (see event at end) function mytimer(time) -- display 1 = frame rate fr = ipc.readUW(0x0274) if fr ~= 0 then fr = 32768/fr end fr = math.floor((fr * 10) + 0.5)/10 display.show(h, 1, "Frame Rate " .. fr .. " fps") -- display 2 = memory left free mem = ipc.readUD(0x024C) memmb = math.floor((mem/1024) + 0.5) display.show(h, 2, "Memory free " .. mem .. " kb (" .. memmb .. " Mb)") end -- Adjust timing to taste: 500 = 1/2 second event.timer(500, "mytimer") And it works OK as designed. Thanks, Igor.
  12. Guys, could you please help me with the text for GSX/PRO/ATCX lua, that I would just drop in my WideClient folder and enjoy handling of these programs from/on my Client PC. It's far beyond my depth to even edit TextMenu.lua properly so that it would show GSX and PRO/ATCX instead of Radar Contact. Much thanks, Igor.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.