[.xml] Tricks, Discoveries and Joy

Sebastian

  • VC:MP Beta Tester
  • Something like this: hga hga hga
  • Posts: 884
[.xml] Tricks, Discoveries and Joy
«  »Last edited
I've made this post so I can share what I've found, with you.
Don't know how many of you know, but you can play with the engine more than R* did when about special features of vehicles.
Didn't test too much, but will update when I have news.
Also, if you have your own discoveries, feel free to share. Will put it in the list.

Flags calculator: https://vc-flags.netlify.com/
Original Author: @maxorator
Modified by: @MEGAMIND



1. Emergency Lights/Taxi Light can be used even if the vehicle is not properly categorized

Take the Flying Delly as example.
All you need to do, is adding this <specials></specials> category and play with the settings inside, like colors, position, if the lights should be turned on all the time or not, etc
(click to show/hide)
Code: [Select]
<specials>
<taxilight>
<alwayson>false</alwayson>
<colour>128,128,0</colour>

<position>
<x>0.0</x>
<y>0.0</y>
<z>0.95</z>
</position>
</taxilight>
</specials>
(click to show/hide)
Code: [Select]
<specials>
<emlights>
<alwayson>true</alwayson>
<colourone>50,255,50</colourone>
<colourtwo>50,50,255</colourtwo>

<posleft>
<x>-0.750687</x>
<y>-2.64971</y>
<z>-0.147924</z>
</posleft>

<posright>
<x>0.750687</x>
<y>-2.64971</y>
<z>-0.147924</z>
</posright>
</emlights>
</specials>
(click to show/hide)
Code: [Select]
<specials>
<emlightsingle>
<alwayson>false</alwayson>
<colour>70,70,255</colour>

<position>
<x>0.4</x>
<y>0.6</y>
<z>0.3</z>
</position>
</emlightsingle>
</specials>



2. Heli weapons will work only with heli flags, in .xml

Simple: Even with the weapons code inserted, weapons won't be active, if you use different flags than heli's.
So, in order to use Hunter's weapons, you gonna add heli's flags + specials + helidata.
Then, via script, you can play how much you want with the flags, because when you gonna reset the flags to heli's, weapons will be still working.

Heli's flags:
Code: [Select]
<flags>08028000</flags>
(click to show/hide)
Code: [Select]
<helidata>
<helitype>hunter</helitype>
<weapons>hunter</weapons>
<rotorradius>6.150000</rotorradius>
<rotordammult>0.500000</rotordammult>
</helidata>

<specials>
<heliweps>
<missilepos>
<x>2.5</x>
<y>1.0</y>
<z>-0.5</z>
</missilepos>

<machinegunpos>
<x>0.0</x>
<y>4.8</y>
<z>-1.3</z>
</machinegunpos>
</heliweps>
</specials>
(click to show/hide)
Code: [Select]
<helidata>
<helitype>water</helitype>
<weapons>sparrow</weapons>
<rotorradius>5.150000</rotorradius>
<rotordammult>0.800000</rotordammult>
</helidata>

<specials>
<heliweps>
<machinegunpos>
<x>0.0</x>
<y>4.8</y>
<z>-1.3</z>
</machinegunpos>
</heliweps>
</specials>



Notes:
  • you cannot mix lights styles (e.g.: taxi light with some emergency lights)
  • light style + heli weapons is posible
  • you can use special lights on helicopters too - don't know about the others, but it must work also. (boat tested, but no lights shown up)
  • even if you trick the flags, like I did with the Flying Delly, you cannot make weapons work when vehicle is a car.
    It must be helicopter.

(click to show/hide)
https://i.imgur.com/c7JhcDf.png - helicannon + lights



PS:
<author></author> setting acutally does something,
so when using downloaded vehicles in your server, don't forget to add the setting and the name.

MEGAMIND

  • Hero Member
  • Developer of "Web-Net" search engine
  • Posts: 679