Page 3 of 4

Posted: Wed Jun 17, 2009 1:05 pm
by dalek501
I think I've answered my own question here. The rear texture is made up in a 600x600 square and is therefore being stretched much more across the back than the the top and bottom textures.

What software do you use to add flashers, or is it all done by coding? And is there any tutorial for that?

Posted: Wed Jun 17, 2009 4:21 pm
by dalek501
Further to this, I've been trying some tinkering... :?

I literally cut and paste the example flasher code from the wiki, and I'm trying to put it into the shipdata plist. But nothing seems to work. I have tried it in several places.

I expect I'm missing something obvious.... :oops:

But I am trying! :lol:

Posted: Wed Jun 17, 2009 4:22 pm
by Nemoricus
I would check to make sure that the code has eight items in each flasher entry and doesn't put them inside your ship.

Posted: Wed Jun 17, 2009 4:29 pm
by dalek501
OK, co if I was using a supercobra what would rough x y z coordinates be to hover one above the ship? For the moment I just want to see it working so I can them go on tinkering...

Posted: Wed Jun 17, 2009 4:31 pm
by Nemoricus
I would check the ship's dimensions and make sure that the coordinates are greater than any one dimension.

See if that works.

Posted: Wed Jun 17, 2009 9:33 pm
by dalek501
Hmm, I'm really struggling. But I'm still trying! :oops:

This is the ship model:
NVERTS 12
NFACES 20

VERTEX
16.3787518, -0.1218359, 36.7125778
-16.3787518, -0.1218359, 36.7125778
0, 13.1859007, 10.0971088
-61.4203186, -1.6573437, -6.2816429
61.4203186, -1.6573437, -6.2816429
-45.0415688, 8.0675402, -22.6603947
45.0415688, 8.0675402, -22.6603947
65.515007, -4.2165241, -22.6603947
-65.515007, -4.2165241, -22.7115784
0, 13.1859007, -22.7115784
-16.3787518, -12.4059, -22.7115784
16.3787518, -12.4059, -22.7115784

FACES
127,127,127, -0.514479,0.857487,-0.005346, 3, 8,3,5
127,127,127, -0.283418,0.921946,0.263988, 3, 3,1,5
127,127,127, -0.301363,0.914023,0.271557, 3, 5,1,2
127,127,127, -0.112910,0.993605,0.000000, 3, 5,2,9
127,127,127, -0.000000,0.894427,0.447214, 3, 1,0,2
127,127,127, 0.112910,0.993605,-0.000000, 3, 9,2,6
127,127,127, 0.301363,0.914023,0.271557, 3, 2,0,6
127,127,127, 0.283418,0.921946,0.263988, 3, 6,0,4
127,127,127, 0.514488,0.857481,-0.005359, 3, 6,4,7
127,127,127, -0.001986,0.007476,-0.999970, 3, 5,9,8
127,127,127, 0.000000,-0.000000,-1.000000, 3, 8,9,10
127,127,127, 0.000000,0.000000,-1.000000, 3, 10,9,11
127,127,127, 0.000941,0.000602,-0.999999, 3, 11,9,7
127,127,127, 0.001402,0.002336,-0.999996, 3, 7,9,6
127,127,127, -0.161371,-0.968228,0.191032, 3, 10,3,8
127,127,127, -0.157847,-0.967018,0.199900, 3, 10,1,3
127,127,127, 0.000000,-0.979295,0.202438, 3, 10,0,1
127,127,127, 0.000000,-0.979295,0.202438, 3, 10,11,0
127,127,127, 0.157847,-0.967018,0.199900, 3, 11,4,0
127,127,127, 0.161160,-0.968158,0.191565, 3, 7,4,11

TEXTURES
galsupercobra_top.png 256 256 0.000000 0.000000 7.936000 70.656000 39.936000 0.256000
galsupercobra_top.png 256 256 7.936000 70.656000 96.000000 256.000000 39.936000 0.256000
galsupercobra_top.png 256 256 39.936000 0.256000 96.000000 256.000000 128.000000 141.312000
galsupercobra_top.png 256 256 39.936000 0.256000 128.000000 141.312000 128.000000 0.000000
galsupercobra_top.png 256 256 96.000000 256.000000 160.000000 256.000000 128.000000 141.312000
galsupercobra_top.png 256 256 128.000000 0.000000 128.000000 141.312000 216.064000 0.256000
galsupercobra_top.png 256 256 128.000000 141.312000 160.000000 256.000000 216.064000 0.256000
galsupercobra_top.png 256 256 216.064000 0.256000 160.000000 256.000000 248.064000 70.656000
galsupercobra_top.png 256 256 216.064000 0.256000 248.064000 70.656000 256.000000 0.256000
galsupercobra_rear.png 256 256 39.936000 204.800000 128.000000 256.000000 0.000000 81.920000
galsupercobra_rear.png 256 256 0.000000 81.920000 128.000000 256.000000 96.000000 0.000000
galsupercobra_rear.png 256 256 96.000000 0.000000 128.000000 256.000000 160.000000 0.000000
galsupercobra_rear.png 256 256 160.000000 0.000000 128.000000 256.000000 256.000000 81.920000
galsupercobra_rear.png 256 256 256.000000 81.920000 128.000000 256.000000 216.064000 204.800000
galsupercobra_bottom.png 256 256 96.000000 0.000000 7.936000 70.656000 0.000000 0.000000
galsupercobra_bottom.png 256 256 96.000000 0.000000 96.000000 256.000000 7.936000 70.656000
galsupercobra_bottom.png 256 256 96.000000 0.000000 160.000000 256.000000 96.000000 256.000000
galsupercobra_bottom.png 256 256 96.000000 0.000000 160.000000 0.000000 160.000000 256.000000
galsupercobra_bottom.png 256 256 160.000000 0.000000 248.064000 70.656000 160.000000 256.000000
galsupercobra_bottom.png 256 256 256.000000 0.256000 248.064000 70.656000 160.000000 0.000000

END
This is the example flasher on the wiki:
<key>subentities</key>
<array>
<string>mySubEntity 0 -5 10 1 0 0 0</string>
<string>*FLASHER* 0 5.5 10 30.0 1 0.0 12</string>
</array>
And this is my ship plist:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>supercobra</key>
<dict>
<key>aft_eject_position</key>
<string>0.0 15.5 -22.71</string>
<key>aft_weapon_type</key>
<string>WEAPON_MILITARY_LASER</string>
<key>ai_type</key>
<string>supercobraAI.plist</string>
<key>auto_ai</key>
<false/>
<key>bounty</key>
<string>100</string>
<key>cargo_carried</key>
<string>Narcotics</string>
<key>cargo_type</key>
<string>CARGO_NOT_CARGO</string>
<key>energy_recharge_rate</key>
<string>7</string>
<key>exhaust</key>
<array>
<string>-19 0.0 -21.5 15.0 7.5 20</string>
<string>19 0.0 -21.5 15.0 7.5 20</string>
<string>-42 0.0 -21.5 5 5 15</string>
<string>42 0.0 -21.5 5 5 15</string>
</array>
<key>forward_weapon_type</key>
<string>WEAPON_MILITARY_LASER</string>
<key>fuel</key>
<string>135</string>
<key>has_ecm</key>
<true/>
<key>has_energy_bomb</key>
<true/>
<key>has_escape_pod</key>
<true/>
<key>has_fuel_injection</key>
<true/>
<key>has_military_scanner_filter</key>
<true/>
<key>has_scoop</key>
<true/>
<key>has_shield_booster</key>
<string>0.75</string>
<key>launch_actions</key>
<array>
<string>switchAITo: galsupercobraAI.plist</string>
</array>
<key>max_cargo</key>
<integer>40</integer>
<key>max_energy</key>
<integer>450</integer>
<key>max_flight_pitch</key>
<real>1.2</real>
<key>max_flight_roll</key>
<real>2.2000000000000002</real>
<key>max_flight_speed</key>
<integer>450</integer>
<key>missile_launch_position</key>
<string>0.0 -12.0 15.5</string>
<key>missiles</key>
<integer>4</integer>
<key>model</key>
<string>galsupercobra.dat</string>
<key>name</key>
<string>Gallifreyan SuperCobra</string>
<key>roles</key>
<string>supercobra trader(0.5)</string>
<key>script</key>
<string>supercobra.js</string>
<key>script_info</key>
<dict>
<key>sc_barrel</key>
<string>narcotics_container</string>
</dict>
<key>thrust</key>
<integer>41</integer>
<key>weapon_energy</key>
<integer>35</integer>
<key>weapon_offset_x</key>
<string>0</string>
<key>weapon_position_aft</key>
<string>0.0 0.0 -22.71</string>
<key>weapon_position_forward</key>
<string>0.0 0.0 36.71</string>
</dict>
<key>supercobra-alternative</key>
<dict>
<key>cargo_carried</key>
<string>Firearms</string>
<key>fuel</key>
<integer>240</integer>
<key>has_shield_enhancer</key>
<string>0.75</string>
<key>like_ship</key>
<string>supercobra</string>
<key>roles</key>
<string>supercobra trader(0.5)</string>
<key>script_info</key>
<dict>
<key>sc_barrel</key>
<string>firearms_container</string>
</dict>
<key>weapon_energy</key>
<integer>28</integer>
</dict>
<key>supercobra-barrel</key>
<dict>
<key>ai_type</key>
<string>dumbAI.plist</string>
<key>bounty</key>
<integer>1</integer>
<key>cargo_carried</key>
<string>firearms</string>
<key>cargo_type</key>
<string>CARGO_CARRIED</string>
<key>energy_recharge_rate</key>
<real>0.0</real>
<key>forward_weapon_type</key>
<string>WEAPON_NONE</string>
<key>likely_cargo</key>
<integer>0</integer>
<key>max_cargo</key>
<integer>0</integer>
<key>max_energy</key>
<real>1</real>
<key>max_flight_pitch</key>
<real>0.5</real>
<key>max_flight_roll</key>
<real>0.5</real>
<key>max_flight_speed</key>
<real>50</real>
<key>missiles</key>
<integer>0</integer>
<key>model</key>
<string>galbarrel_supercobra.dat</string>
<key>name</key>
<string>Cargo container</string>
<key>roles</key>
<string>firearms_container</string>
<key>scanClass</key>
<string>CLASS_CARGO</string>
<key>thrust</key>
<real>0.0</real>
<key>weapon_energy</key>
<real>0.0</real>
<key>weapon_offset_x</key>
<real>0.0</real>
</dict>
<key>galsupercobra-barrel2</key>
<dict>
<key>cargo_carried</key>
<string>firearms</string>
<key>like_ship</key>
<string>galsupercobra-barrel</string>
<key>roles</key>
<string>narcotics_container</string>
</dict>
<key>supercobra-marker</key>
<dict>
<key>ai_type</key>
<string>nullAI.plist</string>
<key>like_ship</key>
<string>splinter</string>
<key>name</key>
<string>SC Marker</string>
<key>roles</key>
<string>supercobra_marker</string>
</dict>
<key>supercobra-mine</key>
<dict>
<key>ai_type</key>
<string>supercobraMineAI.plist</string>
<key>energy_recharge_rate</key>
<string>0</string>
<key>max_energy</key>
<string>10</string>
<key>max_flight_pitch</key>
<string>2</string>
<key>max_flight_roll</key>
<string>2</string>
<key>max_flight_speed</key>
<string>500</string>
<key>model</key>
<string>qbomb.dat</string>
<key>name</key>
<string>Standard Mine</string>
<key>roles</key>
<string>supercobra_mine</string>
<key>scanClass</key>
<string>CLASS_MINE</string>
<key>thrust</key>
<string>0</string>
<key>weapon_energy</key>
<string>45000</string>
</dict>
<key>gallifreyansupercobra-player</key>
<dict>
<key>aft_eject_position</key>
<string>0.0 15.5 -22.71</string>
<key>custom_views</key>
<array>
<dict>
<key>view_description</key>
<string>Rear View</string>
<key>view_orientation</key>
<string>1.0 0.0 0.0 0.0</string>
<key>view_position</key>
<string>0.0 30.0 -200.0</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Rear Right View</string>
<key>view_orientation</key>
<string>0.9239 0.0 0.3827 0.0</string>
<key>view_position</key>
<string>141.42 30.0 -141.42</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Right View</string>
<key>view_orientation</key>
<string>0.7071 0.0 0.7071 0.0</string>
<key>view_position</key>
<string>200.0 30.0 0.0</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Front Right View</string>
<key>view_orientation</key>
<string>0.3827 0.0 0.9239 0.0</string>
<key>view_position</key>
<string>141.42 30.0 141.42</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Front View</string>
<key>view_orientation</key>
<string>0.0 0.0 1.0 0.0</string>
<key>view_position</key>
<string>0.0 30.0 200.0</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Front Left View</string>
<key>view_orientation</key>
<string>0.3827 0.0 -0.9239 0.0</string>
<key>view_position</key>
<string>-141.42 30.0 141.42</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Left View</string>
<key>view_orientation</key>
<string>0.7071 0.0 -0.7071 0.0</string>
<key>view_position</key>
<string>-200.0 30.0 0.0</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Rear Left View</string>
<key>view_orientation</key>
<string>0.9239 0.0 -0.3827 0.0</string>
<key>view_position</key>
<string>-141.42 30.0 -141.42</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Top View</string>
<key>view_orientation</key>
<string>-0.7071 0.7071 0.0 0.0</string>
<key>view_position</key>
<string>0.0 200.0 -15.0</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
<dict>
<key>view_description</key>
<string>Bottom View</string>
<key>view_orientation</key>
<string>0.0 0.0 0.7071 0.7071</string>
<key>view_position</key>
<string>0.0 -200.0 -15.0</string>
<key>weapon_facing</key>
<string>FORWARD</string>
</dict>
</array>
<key>energy_recharge_rate</key>
<string>7</string>
<key>exhaust</key>
<array>
<string>-19 0.0 -21.5 15.0 7.5 20</string>
<string>19 0.0 -21.5 15.0 7.5 20</string>
<string>-42 0.0 -21.5 5 5 15</string>
<string>42 0.0 -21.5 5 5 15</string>
</array>
<key>forward_weapon_type</key>
<string>WEAPON_MILITARY_LASER</string>
<key>hud</key>
<string>hud.plist</string>
<key>hyperspace_motor_spin_time</key>
<string>10</string>
<key>laser_color</key>
<string>blueColor</string>
<key>max_cargo</key>
<string>40</string>
<key>max_energy</key>
<string>450</string>
<key>max_flight_pitch</key>
<string>1.2</string>
<key>max_flight_roll</key>
<string>2.2</string>
<key>max_flight_speed</key>
<string>450</string>
<key>max_missiles</key>
<string>4</string>
<key>missile_launch_position</key>
<string>0.0 -4.5 16.5</string>
<key>missiles</key>
<string>4</string>
<key>model</key>
<string>galsupercobra.dat</string>
<key>name</key>
<string>Gallifreyan SuperCobra</string>
<key>roles</key>
<string>player</string>
<key>thrust</key>
<string>41</string>
<key>view_position_aft</key>
<string>0.0 7.5 -32.5</string>
<key>view_position_forward</key>
<string>0.0 7.25 16.25</string>
<key>view_position_port</key>
<string>-40.0 4.75 0.0</string>
<key>view_position_starboard</key>
<string>40.0 4.75 0.0</string>
<key>weapon_position_aft</key>
<string>0.0 0.0 -22.71</string>
<key>weapon_position_forward</key>
<string>0.0 0.0 36.71</string>
<key>weapon_position_port</key>
<string>-65.5 2.17 -4.33</string>
<key>weapon_position_starboard</key>
<string>65.5 2.17 -4.33</string>
</dict>
</dict>
</plist>
I wonder if anyone would be kind enough to place the example in the correct place in my plist, with a flasher or two somewhere around the ship? Doesn't need to accurate, just so I can see it. Once I can see what I'm doing wrong maybe I'll be able to play around with it?

Thanks in advance
:)

Posted: Wed Jun 17, 2009 9:51 pm
by Screet
dalek501 wrote:
Further to this, I've been trying some tinkering... :?

I literally cut and paste the example flasher code from the wiki, and I'm trying to put it into the shipdata plist. But nothing seems to work. I have tried it in several places.

I expect I'm missing something obvious.... :oops:
Uhm, could it be that you also copied the "mysubentity" part? You'd only need this part of it:

<key>subentities</key>
<array>
<string>*FLASHER* 0 5.5 10 30.0 1 0.0 12</string>
<string>*FLASHER* 0 6 10 30.0 1 0.0 12</string>
</array>

and place it somwhere where you like without breaking existing definitions (e.g. not splitting a key-value pair).

Screet

Posted: Thu Jun 18, 2009 9:12 am
by dalek501
Thank you that worked a treat. I still needed a couple of attempts at placing it in the plist to get it to work. But it did in the end. I placed it next to the exhaust info.

I see one flasher using that bit of code. So is that right? I need two lines with "flasher" in to produce one actual flasher?

Once I know that I think I can experiment.

Posted: Thu Jun 18, 2009 9:19 am
by Nemoricus
No, each flasher only needs one entry. Make sure that neither of them has ended up inside your ship.

Posted: Thu Jun 18, 2009 9:46 am
by Screet
dalek501 wrote:
I see one flasher using that bit of code. So is that right? I need two lines with "flasher" in to produce one actual flasher?
I simply copied the entry and modified one value slightly to show that multiple flashers can end up in such an array. Might be that the positions of both were too close to each other, thus looking like one flasher...

It would be interesting to know if you can use fuel stations after adding the flashers. I recently noticed that it's not only turret subentities, but also model subentities like engines which cause my ship to explode when I try to fly in there...and flashers also are subentities, however of a slightly different type.

Screet

Posted: Thu Jun 18, 2009 9:47 am
by dalek501
Thanks :)

With a bit of adjustment I managed to dig out the other. Now I just need to play around to get colours and positioning right.

Posted: Thu Jun 18, 2009 9:54 am
by Nemoricus
Before you give a go at that, I would do as Screet suggests and see if you can fly through a Fuel Station. It would help answer an important question.

Posted: Thu Jun 18, 2009 10:33 am
by dalek501
Ah well, I have already! I have 4 nice flashing lights, all offset and at the speed I like. It feels good to take my first small and basic steps in oxp'ing.

I will download a fuel station oxp and give it a go...

Posted: Thu Jun 18, 2009 10:56 am
by dalek501
OK I downloaded the fuel station oxp. I flew to it, it told me to halt, and the refuelled me no problem. The flashers were working as I tried an external view at the same time.

So thats ok for me.

Posted: Thu Jun 18, 2009 11:09 am
by Nemoricus
Which type was it? Was it the small satellite or the large fly-through station? It's important because if it was the former, it means nothing. It's the latter that you need to test.