Commit Graph

135 Commits (master)

Author SHA1 Message Date
Karl F 9e44b09314 Happy new year!
HAPPY MERRY 2021!
2021-01-03 19:40:16 +01:00
Webster Sheets 37c96041e1
Refactor Body inheritance tree to remove Object and CityOnPlanet (#4995)
* Remove CityOnPlanet from Object hierarchy

* Remove Object from the inheritance hierarchy

* Rename Object -> ObjectType
2020-11-11 19:33:04 -05:00
cwyss 21a80e4488 Make setspeed target more sticky when in setspeed mode
- Don't clear the setspeed target when in setspeed mode and a
  different nav target is selected.

- Change or clear the setspeed target in setspeed mode when
  ctrl-selecting a new nav target or ctrl-deselecting the old
  setspeed target, respectively.

- When not in setspeed mode, implicitly clear the setspeed target on
  any target change.
2020-02-23 22:06:21 +01:00
Karl F 436db08636 Happy new decade!
May you live long and prosper!
2020-01-01 10:47:46 +01:00
Andrew Copland f2d5c8cf09 Rename DoCrushDamage to generic DoDamage. Remove unused ExtrapolateHullTemperature. Restore GetHullTemperature. Damage if overheating instead of instantly Explode. 2019-06-01 15:29:58 +01:00
mike-f1 75956b9fd0 Decouple includes of Sfx.* and trade dependency from Ship with dependency from ModelBody
Forward declare Space in Ship.h; Make things compiling again

Decouple WorldView.h; Some other decouple here and there

Decouple Renderer no more included in RenderState; Model not including directly its childs
2019-05-21 17:50:50 +02:00
mike-f1 bfe68e5d33 Separate SystemBody from StarSystem; Decouple a lot of includes 2019-05-12 14:16:54 +02:00
Webster Sheets c0e5d89469 Move the ShipController code into ship/, split PlayerShipController into it's own file. 2019-03-10 21:42:11 +01:00
mike-f1 bbb6416528 Delete default ctor in Ship and Player; avoid variable definition with std::tie in Ship; Move LuaObject push outside of ctor (...read Body) 2019-02-03 20:45:11 +01:00
Webster Sheets 5cdaefad6a Run clang-format over the entire code base.
Fix hidden header-inclusion-order dependency errors.
Update .clang-format for v7.0.1.
2019-01-05 17:09:05 -05:00
Karl F d2ab921b62 Happy New Year!
Awesome sauce (for next year):
find . -type f -exec sed -i 's/2008-2018 Pioneer Developers'/'2008-2019 Pioneer Developers/g' {} \;

closes #4507
2019-01-03 15:28:42 +01:00
Webster Sheets 3a3a13edec Update pioneer to use the new save system. 2018-10-11 11:45:57 -04:00
Peter b9d4e6a9bb Backend changes for radial menu.
Update the existing function. Add a few new ones.
2018-07-13 22:13:25 +02:00
Karl F 7225e9c723 Happy New Year!
Ten years in the making now, but how can we improve upon perfection
for ten more years?
2018-01-01 21:22:12 +01:00
John Bartholomew f491c7704c Let Lua specify what sounds to use for a hyperjump.
This brings WKFO's military hyperdrive sound effects into use.
2017-12-21 16:43:51 +00:00
Peter bf9266ed59 Make Ctrl-clicking select the set-speed target. 2017-08-14 11:55:07 +02:00
Andrew Copland 590c480540 Damage the ship instead of instantly exploding. Add audio if it's the player. 2017-05-07 14:54:52 +01:00
Peter 1f336bef4b Prepare C++ for imgui HUD.
Remove the existing C++ HUD, add necessary functions for lua.
2017-04-24 10:35:50 +02:00
Andrew Copland 74d50958fe MERRY HAPPY 2017 2017-01-04 15:11:15 +00:00
Peter 1e1221ec35 add "override" to silence warnings in clang 2016-10-07 00:03:41 +02:00
Andrew Copland ac460d1223 Mostly perf issues around passing by reference instead of value and initialisation in construction. 2016-09-23 21:53:28 +01:00
Andrew Copland fea5ac26b2 MERRY HAPPY 2016 2016-01-29 11:31:54 +00:00
nick-the-ninja 724eb89d47 Removing old serialisation code in body classes, Game and Space. Added JSON serialisation code to classes Player and Space. Pioneer would not have saved and loaded correctly without it. 2015-02-17 22:54:23 +00:00
Robert Norris 9f95339a9d MERRY HAPPY 2014-12-31 23:05:37 +11:00
John Bartholomew 0bc6080ad0 mark Player::SetShipType as virtual/override (explicit is good) 2014-07-14 22:28:24 +01:00
Simon Chopin 25e3ec4787 Replace the OnPlayerChangeEquip event system
The current replacement is a bit of a hack, allowing one function to be
called whenever a specific EquipSet changes its content.
2014-06-26 15:56:00 +02:00
Simon Chopin a7f97faa0f Replace the C++ hyperjump handling by a Lua-based system 2014-06-26 15:56:00 +02:00
Simon Chopin 79f7227c96 New API to make (almost) uncondional jumps
This commit adds new InitiateHyperjump and AbortHyperjump methods to
Ship, with only the minimal consistency checking (not in hyperspace
already, and not jumping towards the current system), as well as a way
to use an arbitrary Lua function to abort the jump during the countdown.

The plan is to make these methods available from Lua, and to implement
all Hyperspace-related policies in Lua (waiting on #1719, as usual). In
the end, I plan on removing CheckHyperSpaceTo and friends.

In order to make this work, I had to add a temporary flag to
the HyperspaceOut structure to tell the various checking functions not
to deal with considerations of fuel or range when the hyperjump has been
initiated by the new methods. This flag will definitely be on its way
along with all the fuel-related code in an hopefully near future.
2014-02-17 09:38:11 +01:00
Andrew Copland 2409d986c7 Merge branch 'master' of https://github.com/pioneerspacesim/pioneer into Shields
Conflicts:
	src/Intro.cpp
	src/Ship.cpp
	src/Ship.h
	src/gameui/ModelSpinner.cpp
	win32/vc2012/pioneer.vcxproj.filters
	win32/vc2013Express/pioneer.vcxproj.filters
2014-01-14 08:06:59 +00:00
Robert Norris 6b7ee8d6d7 hook up the config switch 2014-01-04 22:32:41 +11:00
Robert Norris 539bffbc54 move cockpit hooks to Player
its not the right place either, but its more sane than Ship. NPCs do not need a cockpit
2014-01-04 22:11:26 +11:00
Robert Norris 0c06e1350d update for pioneer code standards 2014-01-03 08:45:23 +11:00
Robert Norris e23fc46880 Merge remote-tracking branch 'fluffyfreak/cockpit3d' into cockpit3d 2014-01-02 19:17:25 +11:00
Robert Norris 6dc4283eb6 happy new year 2014-01-02 14:43:38 +11:00
Andrew Copland 577d37edc9 Merge branch 'master' of https://github.com/pioneerspacesim/pioneer into cockpit3d
Conflicts:
	src/ShipType.cpp
2013-12-30 16:10:28 +00:00
Andrew Copland b31dc32570 Merged across Salwans latest updates, adds lag to the movement of the cockpit when maneuvering or accelerating. 2013-12-21 16:48:07 +00:00
Robert Norris 7f453624e6 remove MarketAgent, Lua can do it all now 2013-12-21 16:27:54 +11:00
Andrew Copland 8898da7e52 Set the Wave to use the "cockpit" model - which I'm adding as a mod currently.
Have it try to set the cockpit when a ship is initialised rather than on construction so that it works when the ship is changed by buying/selling or through scripts.
Fix a bunch of line endings.
2013-12-15 00:23:01 +00:00
Andrew Copland f392572e25 WIP - pre-holiday commit.
Trying to get hitting the shield to work.
Need to pass through the collision data (position and normal etc) to bodies so I can extract and transform it in Ship. Not done yet.
Started adding a "Hit it!" button to ModelViewer but run out of time today.
2013-10-20 15:05:30 +01:00
Robert Norris c68c64317c remove RefList, its unused 2013-05-09 07:35:49 +10:00
Simon Chopin 1df8485478 Use the distance facilities for missile explosion.
This changes the behaviour of missiles : they now spawn without target,
and will explode whenever a body enters a 100m radius, to the exception
of the missile owner.
2013-01-23 18:27:26 +01:00
Simon Chopin 82bac5103e Merge remote-tracking branch 'upstream/master' into missile-lua
Conflicts:
	src/Ship.cpp
2013-01-20 16:42:13 +01:00
John Bartholomew 615668d2c8 remove kill count from the core (it's been in Lua for a while) 2013-01-16 21:00:48 +00:00
Robert Norris 91b8586653 happy new year 2013-01-01 12:36:52 +11:00
Robert Norris 3ff89b4b9b remove old mission api 2012-12-17 07:18:27 +11:00
Robert Norris a7b4bd837c Merge remote-tracking branch 'laarmen/missile-lua'
Conflicts:
	src/LuaShip.cpp
	src/Missile.cpp
	src/Missile.h
	src/Ship.cpp
2012-12-03 16:33:56 +11:00
Simon Chopin 50db2b49d9 Player.cpp: Emit the missile sound on missile spawning instead of firing. 2012-11-03 14:26:15 +01:00
Robert Norris abc0209f95 type->id everywhere 2012-10-31 15:27:22 +11:00
Robert Norris efbce7648a update license paths 2012-09-16 10:59:15 +10:00
Robert Norris e9f4448bba add copyright notices to all the code 2012-09-16 09:45:04 +10:00