Battlestar Galactica

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

Post Reply
User avatar
CaptKev
---- E L I T E ----
---- E L I T E ----
Posts: 519
Joined: Fri Jan 26, 2007 3:21 pm
Location: Shropshire, UK

Post by CaptKev »

I'm using 1.65 with the JavaScript branch (Until I get around to installing version 1.68 :D)

probably just two small flashers on each wing.

If I can sort the double laser problem out I'll upload it as a replacement to the GalCoop viper for anybody who wants it.
Download Fighter HUD, Stingray and System Redux from the EliteWiki
User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton »

Arexack_Heretic wrote:
I may be mistaken by the smooting-groups technique... maybe not defining some faces as a smoothing group will have them non-smoothed.
In OBJ terms, smoothing group 0 is not smoothed, and is the default (any faces before a smoothing group declaration are in group 0). In modeller terms, I have no idea.
User avatar
Arexack_Heretic
Dangerous Subversive Element
Dangerous Subversive Element
Posts: 1876
Joined: Tue Jun 07, 2005 7:32 pm
Location: [%H] = Earth surface, Lattitude 52°10'58.19"N, longtitude 4°30'0.25"E.
Contact:

Post by Arexack_Heretic »

Thanks Ahruman.

You can have multiple weapons by assigning them to subentities.
These need not be big, but if you are going to add a subentity, why not make it look the part?
Weapon_positions can be defined by shipdata, but I always center the entity, so that the beam is along the Z-axis.
(So I'm not sure whether a X-shifted lasermount will rotate along with a quaternion, but I asume it does.)
Multiple weapons are only possible on NPC ships.
Riding the Rocket!
User avatar
CaptKev
---- E L I T E ----
---- E L I T E ----
Posts: 519
Joined: Fri Jan 26, 2007 3:21 pm
Location: Shropshire, UK

Post by CaptKev »

I've created a sub-entity for the left and right lasers which show up okay in-game (as in the last two pictures above) but when I shoot at the space station, loads of vipers come out, but don't attack me.

Code: Select all

	<key>right_laser</key>
	<dict>
		<key>ai_type</key>
		<string>nullAI.plist</string>
		<key>energy_recharge_rate</key>
		<real>4</real>
		<key>max_energy</key>
		<real>80</real>
		<key>forward_weapon_type</key>
		<string>WEAPON_BEAM_LASER</string>
		<key>model</key>
		<string>right_laser.dat</string>
		<key>laser_color</key>
		<string>redColor</string>
		<key>name</key>
		<string>Right Laser Cannon</string>
		<key>roles</key>
		<string>right_laser</string>
	</dict>
Download Fighter HUD, Stingray and System Redux from the EliteWiki
User avatar
Griff
Oolite 2 Art Director
Oolite 2 Art Director
Posts: 2483
Joined: Fri Jul 14, 2006 12:29 pm
Location: Probably hugging his Air Fryer

Post by Griff »

I'm working on a mangled krait ship with two subentities for lasers, it seems to work ok, from comparing your code with mine the only differences i can spot is that my main ship has

Code: Select all

<key>forward_weapon_type</key>
<string>WEAPON_NONE</string>
and my two lasergun subentities have the dumbAI.plist instead of the nullAI.plist, maybe that's what's needed?, the full code for a laser subentitly looks like this,

Code: Select all

<key>griff_krait_millaser_l</key>
<dict>
<key>ai_type</key>
<string>dumbAI.plist</string>
<key>model</key>
		<string>griff_krait_millaser_l.dat</string>
		<key>name</key>
		<string>Krait</string>
		<key>roles</key>
		<string>griff_krait_subents</string>
		<key>forward_weapon_type</key>
		<string>WEAPON_BEAM_LASER</string>
		<key>weapon_position_forward</key>
		<string>39.9 -21.3996 36.2183</string>
		<key>laser_color</key>
		<string>orangeColor</string>		
	</dict>	
User avatar
LittleBear
---- E L I T E ----
---- E L I T E ----
Posts: 2882
Joined: Tue Apr 04, 2006 7:02 pm
Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.

Post by LittleBear »

As Griff says, think (in the main entry) you need to set the forward weapon to WEAPON_NONE. The Renegades.oxp ships use mutiple lasers, if looking there helps you, obviously C&P anything that helps. (I wrote this by cribbing Murgh's method for giving the Wolf 2 lasers).
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
User avatar
Arexack_Heretic
Dangerous Subversive Element
Dangerous Subversive Element
Posts: 1876
Joined: Tue Jun 07, 2005 7:32 pm
Location: [%H] = Earth surface, Lattitude 52°10'58.19"N, longtitude 4°30'0.25"E.
Contact:

Post by Arexack_Heretic »

When you're at it, set the beamtype to pulse, which is much more in-character. (You can set the weaponenergy to any value)

Another possibility is that their AI is faulty.
Are they hanging around the station beacon or take off on a patroll after launch?
try giving them missiles, if they do not fire these in response to your attack, the AI cannot performAttack.
Riding the Rocket!
User avatar
LittleBear
---- E L I T E ----
---- E L I T E ----
Posts: 2882
Joined: Tue Apr 04, 2006 7:02 pm
Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.

Post by LittleBear »

Maybe give the main entry pirateAI whilst testing, as then you know the AIs OK and your just testing the lasers.
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
User avatar
Arexack_Heretic
Dangerous Subversive Element
Dangerous Subversive Element
Posts: 1876
Joined: Tue Jun 07, 2005 7:32 pm
Location: [%H] = Earth surface, Lattitude 52°10'58.19"N, longtitude 4°30'0.25"E.
Contact:

Post by Arexack_Heretic »

better give them interceptAI like normal station defenders. ;)
Riding the Rocket!
User avatar
CaptKev
---- E L I T E ----
---- E L I T E ----
Posts: 519
Joined: Fri Jan 26, 2007 3:21 pm
Location: Shropshire, UK

Post by CaptKev »

Thanks for the help; Griff, LB and AH. I've got it working by following all the above advice. :D
Download Fighter HUD, Stingray and System Redux from the EliteWiki
User avatar
CaptKev
---- E L I T E ----
---- E L I T E ----
Posts: 519
Joined: Fri Jan 26, 2007 3:21 pm
Location: Shropshire, UK

Post by CaptKev »

Unfortunetly the police vipers still aren't firing at me when they should be, they fire missiles but don't use there lasers. I'm sure they did on one occation but I just can't replicate the code for when they did.

Here's the code, any ideas would be much apprieciated.

Code: Select all

	<key>viper</key>
	<dict>
		<key>aft_eject_position</key>
		<string>0.0 6.5 -28.0</string>
		<key>ai_type</key>
		<string>route1patrolAI.plist</string>
		<key>bounty</key>
		<integer>0</integer>
		<key>cargo_type</key>
		<string>CARGO_NOT_CARGO</string>
		<key>energy_recharge_rate</key>
		<real>4</real>
		<key>exhaust</key>
		<array>
			<string>15.0 -2.0 -51.5 5.7 5.7 6.0</string>
			<string>-16.0 -2.0 -51.5 5.7 5.7 6.0</string>
			<string>0 10.0 -51.5 5.7 5.7 6.0</string>
		</array>
		<key>forward_weapon_type</key>
		<string>WEAPON_NONE</string>
		<key>has_ecm</key>
		<real>1</real>
		<key>laser_color</key>
		<string>redColor</string>
		<key>likely_cargo</key>
		<integer>0</integer>
		<key>max_cargo</key>
		<integer>0</integer>
		<key>max_energy</key>
		<real>180</real>
		<key>max_flight_pitch</key>
		<real>1.8</real>
		<key>max_flight_roll</key>
		<real>2.8</real>
		<key>max_flight_speed</key>
		<real>320</real>
		<key>max_missiles</key>
		<integer>1</integer>
		<key>missile_launch_position</key>
		<string>0.0 -8.5 -11.0</string>
		<key>missiles</key>
		<integer>1</integer>
		<key>model</key>
		<string>police_viper.dat</string>
		<key>name</key>
		<string>GalCop Viper</string>
		<!-- Enable smooth engines here -->
		<!-- <key>smooth</key> -->	
		<!-- <true/> -->
		<key>roles</key>
		<string>police</string>
		<key>scanClass</key>
		<string>CLASS_POLICE</string>
		<key>subentities</key>
		<array>
			<string>viper_wings 0 0 0 1 0 0 0</string>
			<string>right_laser 0.0 0.0 0.0 1 0 0 0</string>
			<string>left_laser 0.0 0.0 0.0 1 0 0 0</string>
			<string>*FLASHER* 41 -20 -8 260 2 0.1 8</string>
			<string>*FLASHER* -42 -21 -7 260 2 0.8 8</string>
			<string>*FLASHER* 41 -20 -54 260 2 0.1 8</string>
			<string>*FLASHER* -42 -21 -53 260 2 0.8 8</string>
		</array>
		<key>thrust</key>
		<real>32</real>
		<key>view_position_aft</key>
		<string>0.0 6.0 -57.5</string>
		<key>view_position_forward</key>
		<string>0.0 6.0 35.875</string>
		<key>view_position_port</key>
		<string>-6.25 4.0 0.0</string>
		<key>view_position_starboard</key>
		<string>6.25 4.0 0.0</string>
	</dict>
	<key>viper_wings</key>
	<dict>
		<key>ai_type</key>
		<string>dumbAI.plist</string>
		<key>model</key>
		<string>viper_wings.dat</string>
		<key>name</key>
		<string>GalCop Viper Wings</string>
		<key>roles</key>
		<string>viper wings</string>
	</dict>
	<key>right_laser</key>
	<dict>
		<key>ai_type</key>
		<string>dumbAI.plist</string>
		<key>energy_recharge_rate</key>
		<real>4</real>
		<key>max_energy</key>
		<real>80</real>
		<key>forward_weapon_type</key>
		<string>WEAPON_BEAM_LASER</string>
	      <key>weapon_position_forward</key>
      	<string>0.0 0.0 0.0</string>
		<key>model</key>
		<string>right_laser.dat</string>
		<key>laser_color</key>
		<string>redColor</string>
		<key>name</key>
		<string>Right Laser Cannon</string>
		<key>roles</key>
		<string>right_laser</string>
	</dict>
	<key>left_laser</key>
	<dict>
		<key>ai_type</key>
		<string>dumbAI.plist</string>
		<key>energy_recharge_rate</key>
		<real>4</real>
		<key>max_energy</key>
		<real>80</real>
		<key>forward_weapon_type</key>
		<string>WEAPON_BEAM_LASER</string>
	      <key>weapon_position_forward</key>
      	<string>0.0 0.0 0.0</string>
		<key>model</key>
		<string>left_laser.dat</string>
		<key>laser_color</key>
		<string>redColor</string>
		<key>name</key>
		<string>Left Laser Cannon</string>
		<key>roles</key>
		<string>left_laser</string>
	</dict>
Download Fighter HUD, Stingray and System Redux from the EliteWiki
User avatar
CaptKev
---- E L I T E ----
---- E L I T E ----
Posts: 519
Joined: Fri Jan 26, 2007 3:21 pm
Location: Shropshire, UK

Post by CaptKev »

Colonial viper leaving the Galactica, but still not firing at me! :?

Image

Might have to use just a single laser which works okay.
Download Fighter HUD, Stingray and System Redux from the EliteWiki
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2278
Joined: Tue Jan 02, 2007 12:38 pm

Post by Killer Wolf »

8-0

each pic of that thing looks better than the last!
User avatar
LittleBear
---- E L I T E ----
---- E L I T E ----
Posts: 2882
Joined: Tue Apr 04, 2006 7:02 pm
Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.

Post by LittleBear »

Could try nullAI rather than dumbAI for the sub-entries. The other multi-laser ships all use nullAI for firing sub-entries.

I suspect though it may have somthing to do with the fact that the ship is being launched from a station. I had the same problem with the 3 lasered Black Monk Gun ships. When spawned in space with a customAI, they fired. But if I set them as defence ships, they would turn red on the scanner but refused to fire. Cannot think of a reason why they should do this, but there it is!

Try adding a few with addsystem ships and give them pirateAI. If these version fire then suspect it is just somthing to do with them being defence ships.
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
User avatar
Griff
Oolite 2 Art Director
Oolite 2 Art Director
Posts: 2483
Joined: Fri Jul 14, 2006 12:29 pm
Location: Probably hugging his Air Fryer

Post by Griff »

Wow, that's amazing looking!
I'm puzzled why your vipers won't use their lazers on you, try taking the laser colour key out of the viper plist and maybe for a test change the role from a police one to a pirate see if that gets them firing at you
Post Reply