xuxoyes, I added the light in the MapPropertiesTree, it is an existing light in the game, not created by me. and I have tried with 0,1,2 .... nothing.
Gm... Ok, to add light it's needed:
Go to Map Properties Tree => Ground/Underground Ambient Lights => Add element with Internal Name in properties.
Than write in script SetAmbientLight(floor, name, fade, time).
Could you try to write only string with SetAmbLight function in console and tell results?