Search Unity

Jobs system or compute shader?

Discussion in 'Scripting' started by TomBellNo, Sep 23, 2021.

  1. TomBellNo

    TomBellNo

    Joined:
    Mar 13, 2018
    Posts:
    12
    Hi All

    I'm making a strategy game that has a large number of provinces and for each 'tick' the economic calculation is run on each province. As the economic calculation code is growing, the speed of the game is slowing, so it's clear I need to move to some form of parallel processing if I want to grow the game further.

    My question is which system is better? Compute shaders or the new jobs system? The calculation code is done in such a way that it's not got any conditional statements, it's all the same code running for each province but with different data and I know the GPU excels at running code like that.