Jump to content

Promethium

Members
  • Content Count

    59
  • Donations

    $0.00 
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Promethium

  • Birthday 08/03/1984

Contact Methods

  • Website URL
    http://
  • ICQ
    0

Profile Information

  • Gender
    Male
  • Location
    Melbourne, Australia
  1. Hey oThe ultimate goal of this exercise was too display the NAV and COM frequency's for the radio stack. Well getting something, anything to display was the first half of the battle and with your help i got there.Well just to show that it hasen't all gone to waste. :) Heres my code for displaying the NAV1 standby frequency (which i can change with my newly codded buttons :) )FLOAT64 val = 0; // first declare the float C variableFLOAT64 FSAPI string_cb( PELEMENT_STRING pelement ){ execute_calculator_code("(A:NAV STANDBY FREQUENCY:1, MHz)",&val,NULL,NULL); sprintf( pelement->string, "%6.2f", val ); return 0;}//////////////////////////////////MAKE_STRING( temperature_string, NULL, NULL, IMAGE_USE_ERASE | IMAGE_USE_BRIGHT | IMAGE_USE_TRANSPARENCY, 0, 142, 12, 60, 29, 6, MODULE_VAR_NONE, MODULE_VAR_NONE, MODULE_VAR_NONE, RGB(255,0,0), RGB(0,0,0), RGB(92,92,92), GAUGE_FONT_DEFAULT, GAUGE_WEIGHT_DEFAULT, GAUGE_CHARSET, 0, DT_CENTER | DT_VCENTER | DT_SINGLELINE, NULL, string_cb)PELEMENT_HEADER TEST_plist1[] ={ &temperature_string.header, NULL}; Works a treat thanks guysHave fun peoplesPaul
  2. Good day peoplei had a look in the properties and I was indeed using UNICODE i reset it to "Not set" as you described and woo hoo it worked i have a string from the SDK.Temperature example working on my gauge its now just a matter of messing with it till i get what i wont. Thanks heaps guys ur bloody legends, this C++ caper has been a huge leaning curve but i can see how you can get hooked when somthing works the way it should :)Thanks for for the help and adviceHave funPaul
  3. Included the stdio.h file into the header and WWOOO HHOO it compiled yaaaaa. However now i just get a blank display in FS :( but thats ok now at least i know it will compile and its just a case of messing with it till it works. if i can't get it working i will post a new question :) . Thanks for your help Ed and Tom i have been beating my head against the keyboard for two days on this one now i might get someware.Tom are there any other header file that you might suggest including to prevent this kind of thing.Cheers and thanks againHave funPaul
  4. HiThanks for the reply, i tried the modified callback but to no successes i still get the same "can't convert" error and a new "error C2059: syntax error : '.'"i have had this error before but i don't have enough knowledge to diagnose the problem. I have only just started to learn C++ :) (good way to start i thing :( )CheersPaul
  5. Good day peopleI have been working on a number a C++ gauges for an aircraft project i am working on. So far i have been able to get everything working with the search function in this forum :) the Dragonflight Design tutorial and the SDK (god help me). But finally i have come to a sticky spot, i have started working on the radio stack, i can do all the frequency changes turn stuff on and off and all that but for the life of me a can't get a handle in displaying a string with MAKE_STRING. Heres the code i have all i wont it to do is display "hello" (now it that so hard) once i get it working i should be able to do what i wontMAKE_STRING( string_speed, NULL, NULL, IMAGE_USE_ERASE | IMAGE_USE_BRIGHT, 0, 142,12, 151,63, 5, MODULE_VAR_NONE , MODULE_VAR_NONE, MODULE_VAR_NONE, RGB(255,0,0), RGB(0,0,0), RGB(00,00,00), GAUGE_FONT_DEFAULT, GAUGE_WEIGHT_DEFAULT, GAUGE_CHARSET, 0, DT_SINGLELINE, NULL, STRING_cb)FLOAT64 FSAPI STRING_cb( PELEMENT_STRING pelement ){FLOAT64 val=pelement->source_var[0].var_value.n;val = !val; wsprintf(pelement->string, "%5s", "HELLO"); // return val;}now the problem i am having is that if i try and compile the i get:"error C2664: 'wsprintfW' : cannot convert parameter 1 from 'PCHAR' to 'LPWSTR'Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast"If i try and use "sprintf(pelement->string, "%5s", "HELLO");"i get "error C3861: 'sprintf': identifier not found" I tried to compile the temperature gauge from the SDK and i get the same sorts of errors, so its not that nothing is displayed i cant even get it to compile (i'm using Visual C++ 2008 Express Edition) as far as i can tell i have included all of the necessary headers and what not and i have tried code snipits for every ware but nothing works.Any help on this would be greatly appreciatedCheersPaul
  6. Thanks for the reply but i think i have it sorted i tried your suggestion and didn't have any luck, however i am using pandasofts x exporter plugin for 3DS and i found a setup guide for it to work correctly with MakeMDL so i tweeked a couple of the export settings and it seems to be working ok now :). this completely removes my dependence on Gmax :)Thanks for helpPaul
  7. Hello every one looking for a bit of helpI have been working on a victa airtourer model for some time now and i am having a bit of trouble with the export. I am using 3DSmax 8 and exporting to a .x file which I am then compiling with makeMDL for FS9. The problem i am having is that when i compile the model and load it in FS9 95% of the parts become invisible (its not alway whole parts sometimes some polys of the fuselage show). The problem it is not that the normals have invented as i have fixed those problems and this only occur if all the parts are linked under a dummy object or grouped together. If the model is unlinked or ungrouped then the model shows up fine but i cant adjust the global pivot point. YThe same problem occurs if i move the model into Gmax and export from there.The model is unanimated and is 57537 polysAny help on this would be greatly appreciatedCheersPaul
×
×
  • Create New...