I am trying to hookup a public collision into a trigger
public Collider CollisionTest;
public void OnTriggerStay(CollisionTest other)
{
}
I am trying to hookup a public collision into a trigger
public Collider CollisionTest;
public void OnTriggerStay(CollisionTest other)
{
}
1, i see… so what does public colliders be used for then?
Simply using OnTriggerSay as normal does work, but testing shows that there will be problems, one test player 1 died, but for player 3 player 1 was still alive. My idea was, have the bullet script on the player object, put the collider for the bullet into that public, then though a command deal damage, if it is the server, because the server relays everything.
I don’t remember using collider in the way that you meant, but I think that this is used together with their API’s, something like Cast, Distance, IsTouching.
No, you don’t, you have passed the NAME of your variable as a TYPE in a message callback provided by the unity that you can’t change their signature. Someone that knows how it works will not do this kind of error
So because I decided to do some experimenting, it means I 100% do not know how they work?
No, we think you don’t know how C# works, because you presented that code in your OP.
I do know how code works, in fact, I am finishing up an Aircraft controller as we speak that is also networked.
Whoa guys, look out, this guy has code on an aircraft carrier.
Why do you care so much that we think you’re smart? You’re trying to get help, stop trying to impress us at the same time. You do not know how C# works. That is a statement of fact, demonstrated by your original code posted, which tries to do something that has never and will never work in C#. That doesn’t mean you don’t know how any code works, it refers specifically to C#. There may well be programming languages and frameworks where trying something like that would be entirely valid, but C# is not one of them.
Would you rather impress us or would you rather learn how C# works? I’ll tell you right now the former is a lost cause, and I don’t know why you’d care to anyway. But you keep trying to do that, instead of following the good advice from the first reply and actually learning how it works.
I know how C# works, i am using unity to make the carrier, which uses C#. I did an experiment and it failed