Here's how I attempted to do it. Let's denote the multi-coloured hat as m, black hats as b, and green hats as g. Let's now consider a few scenarios.
EDIT: Scenario 3a has been update to reflect the correct answer as per @Guess Hat's comment.
SCENARIO 1
A has the multi-coloured hat.
As such, the 2 black hats that A sees would have to be full, simple black. This implies that there are 2 black hats and 1 green hat. This means that the order of hats (with A starting on the left) could be:
a. m, b, g, b
b. m, b, b, g
c. m, g, b, b
If it is Scenario 1a, then B would not be able to figure out his own hat, since he could either have the multi-coloured hat or the black hat. The same reasoning applies for Scenario 1b.
For scenario 1c, B knows that there are a total of 2 black hats and from A's statement, he cannot have the multi-coloured hat (otherwise A would see 3 black hats). Therefore, B figures out he has the green hat. However, C cannot figure out the colour of their own hat because he wouldn't know whether he has the multi-coloured hat or the other black hat. Therefore, none of these scenarios works.
SCENARIO 2
B has the multi-coloured hat.
If that is the case, then one the black hats that A mentioned must be B's. Since B is able to figure out his hat, then there must only be 1 black hat (otherwise, B wouldn't know whether he has a multi-coloured hat or a black hat). Therefore, there are 1 black hat and 2 green hats. This leads to the following combinations.
a. g, m, b, g
b. g, m, g, b
As mentioned, B can figure out his own hat colour. The question is whether C can. In 2a, C would see that D has a green hat, and therefore he must have one of the black hats in A's statement. However, he wouldn't know whether he has the black hat or the multi-coloured hat (since [g, b, m, g] would also allow B to figure out his hat.
In Scenario 2b, C sees that D has a black hat, so he would reason that he would either have the green hat or the multi-coloured hat. However, if he had the multi-coloured hat, then B would not have to wait for A's statement because he would have figured out on his own that his hat was green (since he sees the multi-coloured hat and black hat in front of him). Therefore, C figures out that his hat was green. However, D would not be able to figure out their own hat colour since he wouldn't know whether his hat was the multi-coloured one or the black one (a scenario like [g, b, g, m] would also allow B and C to know their own hat colours). Therefore, none of these scenarios works as well.
SCENARIO 3
One of C or D has the multi-coloured hat and the other has a black hat.
What this means is one of the two black hats that A saw was the multi-coloured one. The other black hat must belong to either B or one of C or D. Let's consider the case whether one of C or D had the black hat. So, B must thus have a green hat. Since he was only able to figure this out after A's statement, A must have a black hat (otherwise, B would have immediately known his hat was green). This leads to the following combinations:
a. b, g, b, m
b. b, g, m, b
In 3a, C would be able to figure out he has a black hat or a green hat (since if B had the black hat, B would not need to wait for A's statement). D realises that since C managed to figure out his hat colour, he does not have the multi-coloured hat and must have a black hat. Hence, D figures out that he has the multi-coloured hat. Therefore, [b, g, b, m] is a valid solution to this problem. But it is worth seeing other scenarios for completeness.
In 3b, C cannot figure out whether he has a black hat or a multi-coloured one ([m, g, b, b] could also be a potential configuration). Therefore, none of these scenarios works as well.
SCENARIO 4
B has the black hat and one of C or D has the multi-coloured one.
This also means that one of C or D has a green hat. Since B was able to figure out his hat colour, A must have a green hat as well. Therefore, there are 2 green hats and 1 black hat. The possible combinations are:
a. g, b, m, g
b. g, b, g, m
In 4a, C would not be able to tell whether he has the black hat or the multi-coloured hat (since [g, m, b, g] also lets B figure out his hat colour). Therefore, this scenario is not possible.
In 4b, C sees that D has a multi-coloured hat. He reasons that if he had a black hat, then B would have immediately known his hat colour without relying on A (since there is only 1 black hat and 1 multi-coloured hat). Therefore, C figures that B has the black hat and he must have a green hat. D can reason along similar lines and knows B must have either the multi-coloured hat or the black hat. If B had the multi-coloured hat, then we run into scenario 2b. Thus, no matter what, D is unable to figure out his hat colour.
Thus, I conclude that,
A scenario like [b, g, b, m] is the only valid solution.