Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > IL-2 Sturmovik: Cliffs of Dover > FMB, Mission & Campaign builder Discussions

Reply
 
Thread Tools Display Modes
  #1  
Old 10-01-2011, 11:02 PM
41Sqn_Stormcrow
Guest
 
Posts: n/a
Default Scripting with Visual Basic?

As I am a bit more proficient in Visual Basic and less so in C# (where I have none) I would like to know if it is possible to script in Visual Basic. To my knowledge, the Framework logic implies that the code can be written in any object oriented language and is compiled during the execution rendering the function independent of the language. So basically, as I understand it, it should be possible. But what do the scripting experts think about this?
Reply With Quote
  #2  
Old 10-02-2011, 04:34 AM
fearlessfrog fearlessfrog is offline
Approved Member
 
Join Date: Jul 2010
Posts: 64
Default

If the scripting is run on the .NET Framework then you're right that there could be a choice of languages. C# and VB.NET both compile down to the same Intermediary Language (IL) that's then used by the framework to execute.

On a quick test it doesn't look as if a .vb file is picked up in the same was as a .cs file for a mission is. This would mean a change to CloD I think, as currently it looks for a source code file and then assumes it's C# code.

There are pros and cons of offering both, in that it would be easier to get started for those that know some VB or VBScript but then a downside it would mean a lot of the library of samples would get duplicated or not understood by the other half of the community.
Reply With Quote
  #3  
Old 10-02-2011, 04:57 AM
FG28_Kodiak FG28_Kodiak is offline
Approved Member
 
Join Date: Dec 2009
Location: Swabia->Bavaria->Germany
Posts: 884
Default

Have tried it also - same result.

But you can generate your own Dlls in VB and then use them in CoD.
Reply With Quote
  #4  
Old 10-02-2011, 07:29 AM
41Sqn_Stormcrow
Guest
 
Posts: n/a
Default

I am not sure if I understand your message correctly, frog. So basically you say it is possible but with uncertain results?

@Kodiak: So in principle I could write what I want to do into dll's using vb and then write a c#-script that runs the dll's? Not a convenient thing to do but would it work?
Reply With Quote
  #5  
Old 10-02-2011, 08:09 AM
41Sqn_Banks 41Sqn_Banks is offline
Approved Member
 
Join Date: Oct 2007
Posts: 644
Default

If the .vb file is not loaded one could try to write the VB code within a .cs file.

Another solution would be to automatically convert the VB code into C# and then paste it into the script file of the mission. Online converter: http://www.carlosag.net/tools/codetranslator/
Reply With Quote
  #6  
Old 10-02-2011, 10:06 AM
FG28_Kodiak FG28_Kodiak is offline
Approved Member
 
Join Date: Dec 2009
Location: Swabia->Bavaria->Germany
Posts: 884
Default

Have tried the cs file but get a compiler error in game.
Reply With Quote
  #7  
Old 10-02-2011, 10:14 AM
41Sqn_Stormcrow
Guest
 
Posts: n/a
Default

Bad. Very bad. So no vb for me
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:10 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.