Search Unity

a "Global" collision place/instance with no hack

Discussion in 'Scripting' started by mescalin, Feb 25, 2014.

  1. mescalin

    mescalin

    Joined:
    Dec 19, 2012
    Posts:
    67
    Hi

    I have looked around carefully and I was looking if there is a way to simply hook ALL COLLISIONS.... is this possible?


    Currently you have to put the script inside the actual object that collides which makes complete sense from some designs.


    Is there not simply a way of getting all the collision events however? I can then use my own game logic to decide what to do with them.



    If you code a game that essentially spawns loads of items from some main script, this avoids having to fill them all up with scripts etc.

    The only way I can currently do this is some phone home generic collision script that sends the events to some central script, I think this may be okay but it strikes that I am backwards engineering the Unity Engine and it makes my script look less friendly, I'd like it deployable in one script if possible.


    An open question where I'd just hope for your thoughts on the issue if not possible. When in rome as they say, so it looks like I might have to just right a generic collision hook type code thing.
     
  2. mescalin

    mescalin

    Joined:
    Dec 19, 2012
    Posts:
    67
    okay I did find another thread, if anyone has any thoughts on this however please say

    otherwise thread is resolved as "impossible" but a +1 to a global systems where I can get the same flexibility as a custom engine