March 17, 20188 yr Hi I just did my first fight class in F# for fun. Well the beginning only. I built the dll but the bot can't run it, big red error in logs. Anyone tried to make a class in F#? I am not sure if it's F# or me building the DLL the wrong way. I am new to F#. namespace priestf open robotManager.Helpful open wManager.Wow.Helpers type Main() = let mutable _loop = false interface ICustomClass with override this.Initialize() = Logging.Write "Start Class" _loop <- true override this.Dispose() = _loop <- false override this.ShowConfiguration() = () override this.Range = 30.0f
March 17, 20188 yr 1 hour ago, pasdoy said: Hi I just did my first fight class in F# for fun. Well the beginning only. I built the dll but the bot can't run it, big red error in logs. Anyone tried to make a class in F#? I am not sure if it's F# or me building the DLL the wrong way. I am new to F#. namespace priestf open robotManager.Helpful open wManager.Wow.Helpers type Main() = let mutable _loop = false interface ICustomClass with override this.Initialize() = Logging.Write "Start Class" _loop <- true override this.Dispose() = _loop <- false override this.ShowConfiguration() = () override this.Range = 30.0f Is F# fight class development supported? I know that WRobot supports .net 4.0 but hadn't ever seen things written in anything other than that.
March 17, 20188 yr Author I know it's part of .Net 4 and I have autocomplete when I develop and it builds. I think it's me with the dll when I build.
March 18, 20188 yr Author I did some more test but couldn't figure it out :/. DLL is attached. priestf2.dll
March 19, 20188 yr namespace priestf Sorry I didn't see this earlier, but you CANNOT use your own namespace on the main class. All other classes you have are fine to be used within any of your own and/or different namespaces, but the Main : CustomClass is not.
March 19, 20188 yr Author thanks for the help all. I didn't think it was the namespace because of this file Script.fsx. I thought it meant "Open everything in the namespace X". I haven't made it worked it. #load "Library1.fs" open priestf2
Create an account or sign in to comment