Community Forum

attempt to call global 'registerPlaceableType' (a nil value)

Forum Overview >> Scripting

CategoryScripting
Created07.05.2021 21:27


Robert Sarnelli (GalaticDude5452) 07.05.2021 21:27
Trying to convert a place able mod from FS17 to FS19 and this error popped up in my log. Can't seem to find any solutions regarding this error. Any help would be much appreciated!
Thanks!

Bilbo Beutlin (BBeutlin) 08.05.2021 01:34
The xml entry <placeableType> is invalid (obsolete).
Try a similar type from FS19 defaults.
There will be more things to adapt due to FS19 changes.

Robert Sarnelli (GalaticDude5452) 12.05.2021 23:21
in the the Modesc?

Robert Sarnelli (GalaticDude5452) 12.05.2021 23:24
in the the Modesc?

Bilbo Beutlin (BBeutlin) 12.05.2021 23:42
Of course not only in the modDesc.xml, but also in placeable.xml and perhaps also in placeable.i3d.

Robert Sarnelli (GalaticDude5452) 13.05.2021 20:38
So, Id have to add a default FS19 placeable type in those XML's and I3D file?


Robert Sarnelli (GalaticDude5452) 13.05.2021 20:48
So, Id have to add a default FS19 placeable type in those XML's and I3D file?


Bilbo Beutlin (BBeutlin) 14.05.2021 00:45
What do you expect? I don't know what you're going to convert, so I can't say what exactly has to be done.
So I can advise only to take a similar default placeable and compare step-for-step with your mod.

Looks like you're very new to FS modding, so you'll have to learn at first. Look into guides/tutorial here and elsewhere in web.
After changes always look into editor and game log, these will give you valuable hints. Use Google to find more infos to "fs19 {error message}".

Robert Sarnelli (GalaticDude5452) 14.05.2021 01:51
I am very new to modding FS. seems liked I annoyed you... I do always check my log for errors, some I can figure out on my own, other ones, not so much. And I have been googling "FS19 (error message) and I either come up finding the answer or most of time I can not, so I turn to these forums for help/guides

Bilbo Beutlin (BBeutlin) 14.05.2021 02:53
Sorry, but we are no clairvoyants and your descriptions are very vague.

The error message "attempt to call global 'registerPlaceableType' (a nil value)" says the <placeableType> in your placeable.xml is missing or invalid.
Could also be, the mod uses a custom script. Usually these won't work in later FS versions anymore.

For converting mods you need some enhanced knowledge and experience. Not suitable for absolute beginners.
I'd recommand you begin like all others: start with small projects and learn.

Robert Sarnelli (GalaticDude5452) 14.05.2021 23:14
Alright, I understand, Again I am sorry If I annoyed you in anyway. I believe after doing some further re search, FS19 placeable mods don't use Placeable LUA script, as the FS17 mod I'm trying to convert has one

Bilbo Beutlin (BBeutlin) 15.05.2021 00:03
Certainly FS19 placeables still use a LUA script. The script is determined by the xml tag <placeableType>..</placeableType>.
However some things have changed in FS19. Some types don't exist anymore, new ones were added.
The most important types (and scripts) you'll find in
https://gdn.giants-software.com/documentation_scripting_fs19.php?version=script&category=27&class=264
The xml tag <placeableType> has mostly the same name, merely 1st letter lowercase.

Anyway, be aware that not only type may have changed, but also the structure of xml and perhaps i3d. To convert these you'll need to compare and analyze step-for-step similar recent FS19 placeables with older ones.


Note: Log in to post. Create a new account here.