I've just downloaded the new Unity (beta) 2018.1b version and I'm wondering how to use all the new fanciness they introduced, like the two things mentioned in the topic. Can I just put pathfinding and raycasting code into IJob.Execute method definition and it will just work, or are there some more specialized structs I need to extend in order for those two to work (like IJobParallelForTransform)?
I'm asking this because the docs and google search uncovered nothing, which is to be expected, since this new version was released earlier today, but maybe someone already has some knowledge.
For anyone interested in this topic, here's the discussion on unity forums: https://forum.unity.com/threads/asynchronous-raycasting-and-pathfinding.511973/#post-3349101
Related
I'm using Unity 2018.3 and am building an application in which I'm trying to do something very simple: turn off the pointer, after some command.
I can't find any scripting documentation in the GitHub repository and am wondering if it exist somewhere. What I'm finding is how to use the Unity Inspector to configure anything, half of it not working yet (e.g. controller model), but after anything is configured, can't find anything on how to use scripting to control it. Am I out to lunch? Anyone knows where to look?
Thanks!
From another example, I've chosen the following path, but maybe I'm wrong... let me know.
The API documentation for MRTK is available at https://microsoft.github.io/MixedRealityToolkit-Unity/api/Microsoft.MixedReality.Toolkit.html
It looks like you are also asking a second question here, if you could please post a separate question about your specific issue, it would be great. Here is a guide for how to ask good questions on stackoverflow, which might help give ideas for how to frame your question: https://stackoverflow.com/help/how-to-ask.
I am specifically trying to replicate a few lines of code, but cannot seem to find the equivalent in .net core. Any help in replacing would be appreciated, or at least some direction in where to look. I did try looking into Kerberos.NET but it didn't seem to have this kind of functionality.
System.IdentityModel.Tokens.KerberosRequestorSecurityToken Ticket = null;
try
{
Ticket = new System.IdentityModel.Tokens.KerberosRequestorSecurityToken(UserSPN);
}
So, I came across a blog post published the day I posted this question and I've been messing around with it. It does effectively replace the System.IdentityModel.Tokens.KerberosRequestorSecurityToken class. The blog is from Harmj0y, who effectively wrote PowerView and helped write Sharphound. My next step is trying to replace the interop features, since the .dll files referenced won't be available on *nix type systems. That may end up being another question. The blogs link is below.
http://www.harmj0y.net/blog/redteaming/kerberoasting-revisited/
First, let me clarify somethings, I don't know python.
I am currently working on my final year project and I needed a good Object detection technique, after trying many methods (color threshold, Haar-Classifiers), I stumbled around tensorflow, found myself a good tutorial, followed it and got the detector I want.
The problem:
I need and I want to work on Unity, Unity only supports C#.
I found an asset called TensorflowSharp but didn't know how to use it. The fact is I don't want to train on Unity, I trained on python I just need to use the "frozen inference graph" (as named in the tutorial) in unity to detect the object I want.
Please, I have to present in a month, any help is appreciated.
You can take a look at my TFClassify-Unity example. It uses trained model from official Tensorflow repo, but you can try your own by renaming its extension from '.pb' to '.bytes' and replacing default one with it.
Some of the dialogue from this question turned ugly and it was requested that I ask a new question, but because there is an answer, I cannot delete it despite the similarity (pretty lame, Stackoverflow).
Please see this question:
Implementing a content-hashable HashSet in C# (like python's `frozenset`)
You need an ImmutableHashSet<>. Your timing is good, it is available through NuGet in the Microsoft.Collections.Immutable package.
For background, see Preview of Immmutable Collections Released on NuGet. The video Inside Immutable Collections is also available.
Relating to another question I asked yesterday with regards to logging I was introduced to TraceListeners which I'd never come across before and sorely wish I had. I can't count the amount of times I've written loggers needlessly to do this and nobody had ever pointed this out or asked my why I didn't use the built in tools. This leads me to wonder what other features I've overlooked and written into my applications needlessly because of features of .NET that I'm unaware of.
Does anyone else have features of .NET that would've completely changed the way they wrote applications or components of their applications had they only known that .NET already had a built in means of supporting it?
It would be handy if other developers posted scenarios where they frequently come across components or blocks of code that are completely needless in hindsight had the original developer only known of a built in .NET component - such as the TraceListeners that I previously noted.
This doesn't necessarily include newly added features of 3.5 per se, but could if pertinent to the scenario.
Edit - As per previous comments, I'm not really interested in the "Hidden Features" of the language which I agree have been documented before - I'm looking for often overlooked framework components that through my own (or the original developer's) ignorance have written/rewritten their own components/classes/methods needlessly.
The yield keyword changed the way I wrote code. It is an AMAZING little keyword that has a ton of implications for writing really great code.
Yield creates "differed invoke" with the data that allows you to string together several operations, but only ever traverse the list once. In the following example, with yield, you would only ever create one list, and traverse the data set once.
FindAllData().Filter("keyword").Transform(MyTransform).ToList()
The yield keyword is what the majority of LINQ extensions were built off of that gives you the performance that LINQ has.
Also:
Hidden Features of ASP.NET
Hidden Features of VB.NET?
Hidden Features of F#
The most frequently overlooked feature I came across is the ASP.net Health Monitoring system. A decent overview is here: https://web.archive.org/web/20210305134220/https://aspnet.4guysfromrolla.com/articles/031407-1.aspx
I know I personally recreated it on several apps before I actually saw anything in a book or on the web about it.
I spoke to someone at a conference one time and asked about it. They told me the developer at MS had bad communication skills so it was largely left undocumented :)
I re-wrote the System.Net.WebClient class a while back. I was doing some web scraping and started my own class to wrap HttpWebRequest/HttpWebReponse. Then I discovered WebClient part way through. I finished it anyway because I needed functionality that WebClient does not provide (control of cookies and user agent).
Something I'm thinking about re-writing is the String.Format() method. I want to reflect the code used to parse the input string and mimic it to build my own "CompiledFormat" class that you can use in a loop without having to re-parse your format string with each iteration. The result will allow efficient code like this:
var PhoneFormat = new CompiledFormat("({0}){1}-{2}x{3}");
foreach (PhoneNumber item in MyPhoneList)
{
Console.WriteLine(PhoneFormat.Apply(PhoneNumber.AreaCode, PhoneNumber.Prefix, PhoneNumber.Number, PhoneNumber.Extension));
}
Update:
This prompted me to finally go do it. See the results here: Performance issue: comparing to String.Format