In theory:
Every object is made from materials. Their names are road, wall, tree, glass, water, snow, sand, grass, gravel etc.
Because the tracks are built from many objects, that use different textures, the material names must be numbered or suffixed: road1, road2, road_to_pit, and so on.
When driving on the road, the game reads reactions from specialfx.tec and applies them: what is the tire grip, how much the car glides on the road, is the road flat or bumpy - this is the first part.
The next part are visual effects: sparks, dust, skids, how strong the effect is and how long it lasts.
The third part is sound, what sound effect corresponds the contact of a car vs the material, how loud it is and how long it lasts.
In practice, the track developers created various types of roads on the same track. They named them roadA, roadB, they separated ground roads, low grip roads, bumpy roads, roads covered with snow or ice.
Every material got a different name: RoadA is reserved for the fastest tarmac road. Other roads are names B1Road, B2Road, B3Road for 3 levels of bumpy roads, LGRoad and VLGroad for two levels of low grip roads.
But this was not enough. When driving a car through a ground road, you should see a lot of dust, when drving through snow, the skids should be white, not black, like on the tarmac road.
Also, the roadside materials needed to be named, when you drive through them (grass, water, curbs on the roadside) or collide with them (buildings, walls, fences, tirewalls, trees, parked cars)...
The diversity of materials would not be visible, if the track builders didn't add the new material names to the specialfx file and define the reactions.
It also caused that some names are more important from the other, for example RoadA, RoadB must be above Road in the file.
If Road was the first, there would be the same reaction for all materials that begin with Road.
If RoadA is above (before) Road, the effects are different for RoadA, and for other names (Roads, Roadside, Road_to_pit) the reactions for Road are used.
The order causes many problems, because I noticed that the game ignores many material names that have been added (not existing in the original game).
If I find a track, with new drivable materials, named for example Terrain01, Terrain02, I must add the name, at least Terra or even Ter, to specialfx,
and define the reactions (from rFactor .tdf fle or experimentally).
If the name is not present in specialfx, it is not drivable (you have no control over the car).
If you find a track, where the main road material is named Motorway, you need to: add the name to sfx, or rename the material to RoadA and save all objects.
I haven't found yet, what causes problems, when the new name is added in one place of the file, it works, in the other places it doesn't work or makes the other materials work incorrectly.
I think, all the material definitions should be rearranged by these criteria:
Longer names first
All types of roads before other materials
Most frequently used materials before rarely used.
Drivable materials before crashable (these that you only collide with).
Making them all work may be incredibly hard (or even impossible).
The game code may contain a limit of mateial names. When exceeded, the names at the end of the file may be ignored.
The game may be buggy, or for faster processing (when many objects and cars are rendered), it may read only the first letter of material names.
The simplest specialfx file could look this way
Line 1
(here the definition of a drivable road)
materials=Ro
Line 2
(here the definition of "not road", using for example the effect for a Low Grip Road)
materials=a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,1,2,3,4,5,6,7,8,9,0,_,-
and all other possible characters that the material names may begin with.
And this is the place, where we should start again...