Category | Editor |
Created | 16.05.2021 14:56 |
Steven Farmer (stev11113) | 16.05.2021 14:56 |
---|---|
HI can you help please. I`m having trouble with my gate triggers. This is what I have done. I got a animated Objects.xml, I go in to my placeables folder and open a gate folder I pick the gate I want. I then go in to that gates xml and copy the animatedObjects text which I put in to animatedObjects.xml. I then go in to the gates modDesc and copy the lines between the 110n and put them in the maps modDesc. I go in to my map and place the gates. Then I go in to userattributes. 1 index string, 2 onCreate scriptcallback, 3 xmlFilename string, in 1 I put gate name,2 AnimatedObject.onCreate and in 3 maps/animatedObjects.xml. <l10n> <text name="shopItem_StationTotal"> <en>Total Station</en> <de>Total Tankstelle</de> </text> <text name="function_StationTotal"> <en>Place this gas station on your map and keep your vehicles full of fuel all the time.</en> <de>Setzen Sie diese Tankstelle auf Ihre Karte und halten Sie Ihre Fahrzeuge jederzeit mit Kraftstoff gefüllt.</de> </text> <text name="placeableMisc"> <de>Das ist eine Konfigurierbare Deko</de> <en>This is a Configurable Decoration</en> </text> <text name="action_OPEN_ROLLDOOR"> <en>Open Rollinggate</en> <de>Rolltor öffnen</de> </text> <text name="action_CLOSE_ROLLDOOR"> <en>Close Rollinggate</en> <de>Rolltor schließen</de> </text> <text name="action_OPEN_DoorRight"> <en>Open Door</en> <de>Tür öffnen</de> </text> <text name="action_CLOSE_DoorRight"> <en>Close Door</en> <de>Tür schließen</de> </text> <text name="Letterbox_Menu"> <en>Open menu</en> <de>Menü öffnen</de> </text> <text name="Letterbox_FlagUp"> <en>Up</en> <de>Oben</de> </text> <text name="Letterbox_FlagDown"> <en>Down</en> <de>Unten</de> </text> <text name="Letterbox_TextColour"> <en>Text Colour</en> <de>Textfarbe</de> </text> <text name="Letterbox_NumberColour"> <en>Number Colour</en> <de>Nummernfarbe</de> </text> <text name="Letterbox_NumberInput"> <en>Numbers</en> <de>Nummer</de> </text> <text name="Letterbox_TextInput"> <en>Text</en> <de>Text</de> </text> <text name="Sign_GUI_Title"> <en>Sign Configuration</en> <de>Schildkonfiguration</de> </text> </l10n> <animatedObject index="Rollinggate_Blue1" > <animation duration="4.5"> <part node="0|0|1"> <keyFrame time="0.0" translation="0.092 0.076 7.619"/> <keyFrame time="1.0" translation="0.092 0.076 -0.048"/> </part> </animation> <controls triggerNode="0|1" posAction="ACTIVATE_HANDTOOL" posText="action_OPEN_ROLLDOOR" negText="action_CLOSE_ROLLDOOR" /> <sounds> <moving file="sounds/door_Markus_77.wav" loops="0" linkNode="0|0|2" volume="0.8" radius="25" innerRadius="3" fadeOut="0.25"/> </sounds> </animatedObject> <animatedObject index="Door_Blue" > <animation duration="2.5"> <part node="0|0|2|0"> <keyFrame time="0.0" translation="-0.015 1.167 -1.012"/> <keyFrame time="0.2" translation="-0.015 1.167 -0.914"/> </part> <part node="0|0|2"> <keyFrame time="0.2" translation="0.1 0.078 8.767" rotation="0 0 0"/> <keyFrame time="1.0" translation="0.1 0.078 8.767" rotation="0 -100 0"/> </part> </animation> <controls triggerNode="0|2" posAction="ACTIVATE_HANDTOOL" posText="action_OPEN_DoorRight" negText="action_CLOSE_DoorRight" /> <sounds> <moving file="$data/sounds/prefab/gate/gate_loop.wav" loops="0" linkNode="0|0|1" volume="0.8" radius="25" innerRadius="3" fadeOut="0.25"/> <posEnd file="$data/sounds/prefab/gate/gate_opened.wav" linkNode="0|0|1" volume="0.8" radius="25" innerRadius="3" /> <negEnd file="$data/sounds/prefab/gate/gate_closed.wav" linkNode="0|0|1" volume="0.8" radius="25" innerRadius="3" /> </sounds> </animatedObject> Game log throws up a error saying failed to open xml AnimatedObjects.xml gates can not be found in AnimatedObjects.xml. But they are in there. |
Bilbo Beutlin (BBeutlin) | 16.05.2021 16:07 |
---|---|
Placeable animated objects and inbuilt (in map) are different. Those in map are 'animatedMapObjects', they need as scriptCallback "AnimatedMapObject.onCreate". Also the associated xml has slightly different structure. |
Steven Farmer (stev11113) | 17.05.2021 14:12 |
---|---|
Thanks that works appreciate the help. |
Note: Log in to post. Create a new account here.