Commit Graph

1780 Commits (7a6e669a37ba0d46b13efc62c095498db31f92c6)

Author SHA1 Message Date
krzys-h 1e97d41a2d Fixed RedArrow and BlackArrow transparency (#545) 2015-08-06 22:39:06 +02:00
krzys-h 6e5e3c4822 Fixed crash in IntroduceVirus if robot doesn't have any programs 2015-08-06 22:34:46 +02:00
krzys-h 69e6ae2c5e Added "saving in progress" indicator 2015-08-06 20:15:17 +02:00
krzys-h 8d34286b1d Added "No userlevels installed" message 2015-08-06 19:37:18 +02:00
Piotr Dziwinski f95980456a Replace anonymous union in Event with pointer to appropriate struct 2015-08-06 19:11:50 +02:00
krzys-h e05fba22fd Moved some interface controls around 2015-08-06 19:03:15 +02:00
krzys-h ec3ded75b8 Removed unused LOD level setting 2015-08-06 18:35:56 +02:00
krzys-h 69c6e9d4be Fixed level loading error message 2015-08-06 18:29:59 +02:00
krzys-h 7649731b49 Reimplemented hiding mouse during loading 2015-08-06 18:28:28 +02:00
krzys-h dc9e2d2e8b GUI loading error popup
Also added fireParticles option
2015-08-06 18:19:01 +02:00
krzys-h b9bd075903 Drop (now unused) m_phase from CMainDialog 2015-08-06 16:20:29 +02:00
krzys-h 6e8266fd58 Always clear tooltip and highlighted object on phase change 2015-08-06 16:14:11 +02:00
krzys-h 50aaf04405 Don't rotate autosaves if not needed 2015-08-06 16:11:49 +02:00
krzys-h 711643b454 Refactored CMainDialog 2015-08-06 16:02:59 +02:00
Piotr Dziwinski f29a826ad2 Fix Clang warnings about use of abs() 2015-08-06 14:31:40 +02:00
Piotr Dziwinski 654ef7ba59 Add proper initializers to common classes 2015-08-06 14:31:40 +02:00
Piotr Dziwinski 2906451d06 Indent style fix 2015-08-06 14:31:40 +02:00
Piotr Dziwinski 61ec101b11 Replace size_t with std::size_t
For some reason Clang's AST API doesn't like size_t
2015-08-06 14:31:40 +02:00
Piotr Dziwinski 6ca0757fec Fix for Clang compilation 2015-08-06 14:31:40 +02:00
krzys-h 0dbfa027b1 Fixed dialog opening animation and particles 2015-08-06 14:04:33 +02:00
krzys-h 02417363e4 Fixed version text disappearing during loading 2015-08-06 14:03:07 +02:00
krzys-h f0cfc35356 Fixed mouse particles appearing in simulation 2015-08-06 13:54:59 +02:00
krzys-h d538b65ace Fixed saving of selected object in autosaves 2015-08-06 13:53:03 +02:00
krzys-h b20d589c87 Check available texture units in shadow mapping settings 2015-08-06 13:47:42 +02:00
Piotr Dziwinski 4faeffa77d Fix for cursor particles in main menu 2015-08-06 13:25:56 +02:00
krzys-h dc85aa2138 Moved all UI controls to a subdirectory 2015-08-06 13:25:24 +02:00
krzys-h 2b4210dcbc Separated CMainUserInterface from CMainDialog 2015-08-06 12:59:09 +02:00
krzys-h a322f46f00 Split CScreenSetup 2015-08-06 12:16:38 +02:00
Piotr Dziwinski 0c9cf51d81 Address comments on commit d7bc28a 2015-08-06 11:17:54 +02:00
Piotr Dziwinski 596bb49de0 Normalize static variables and functions
* get rid of some of them
 * put the rest into anonymous namespaces
2015-08-06 10:12:20 +02:00
Piotr Dziwinski bdeeaf690b Get rid of memsets 2015-08-06 09:37:25 +02:00
Piotr Dziwinski 0c9e745213 Add proper initializations in remaining graphics classes 2015-08-06 09:33:27 +02:00
Piotr Dziwinski c339838cd2 Add proper initializations in CWater, CTerrain and CCloud
Also make associated structs private
2015-08-06 08:22:11 +02:00
Piotr Dziwinski d7bc28a595 Add proper initializations in CPlanet and refactor planet mode 2015-08-06 08:22:11 +02:00
Piotr Dziwinski 111d279de5 Add proper initializations in OpenGL classes 2015-08-06 08:22:11 +02:00
Piotr Dziwinski 91658c7df0 Add proper initializations in basic graphics structures 2015-08-06 08:22:11 +02:00
Piotr Dziwinski 7097ec38e3 Fix very subtle memory access bug
Some CScreen classes have functions which call ChangePhase() on
CRobotMain, which in turn calls ChangePhase() on CMainDialog, which in
turn deletes current CScreen object :(.

So the fix is to keep all CScreen objects created all the time and only
keep pointer to the currently active object.

This also makes it easy to clean up dependencies between CScreen classes
and get rid of all these ugly static variables and functions.
2015-08-06 08:18:22 +02:00
Piotr Dziwinski c38ecd67ea Fix crash in glDeleteTexture 2015-08-05 23:06:54 +02:00
krzys-h 95a438bcc6 Fixed cheat console and particles during loading 2015-08-05 22:54:13 +02:00
krzys-h 86caf4f098 Fixed a bug in 47d79c9977 2015-08-05 22:16:52 +02:00
Piotr Dziwinski 9ccb39ce66 Fix Clang compilation 2015-08-05 22:02:59 +02:00
Piotr Dziwinski a9a643eea4 Add virtual destructor to CScreen to fix memory corruption issue 2015-08-05 20:59:49 +02:00
krzys-h 47d79c9977 Added #Include support in level files 2015-08-05 19:27:26 +02:00
krzys-h c62e583c12 Fixed log message 2015-08-04 23:34:39 +02:00
krzys-h 5e0cff29dc Removed GetChapPassed from maindialog.h 2015-08-04 23:32:44 +02:00
krzys-h 54254e2158 Split CMainDialog 2015-08-04 23:29:18 +02:00
Piotr Dziwinski c2387b4b56 Class naming fix 2015-08-04 20:58:03 +02:00
Piotr Dziwinski 18f9bfb575 Make saving screenshot thread- and exception-safe
* introduce ResourceOwningThread wrapper for safely passing resources
   to new threads
 * make CEventQueue thread-safe
 * start screenshot saving thread using ResourceOwningThread
 * change direct call at end of writing screenshot to thread-safe
   event communication
2015-08-04 20:37:15 +02:00
MrSimbax 5005e760b9 Fix interrupting Me building when he's not selected (fixes #548) 2015-08-04 20:31:17 +02:00
krzys-h 3f48e4699d Moved window position and font size storage from CRobotMain to CSettings 2015-08-04 13:09:34 +02:00
krzys-h a4f12f1b11 Removed unused m_access* variables 2015-08-04 12:50:49 +02:00
krzys-h 4b271cee2d Moved settings out of CMainDialog into a separate class
Also fixed some problems with resolution list selection after starting game
2015-08-04 12:46:54 +02:00
krzys-h ea7bfdefda Moved scene to load out of CMainDialog 2015-08-04 10:56:49 +02:00
krzys-h fc8d8cb9d4 Moved saved scene loading to CPlayerProfile 2015-08-04 09:55:39 +02:00
krzys-h 72210d523f Fixed this.orientation values outside of 0-360 range 2015-08-03 23:10:24 +02:00
krzys-h 13ef6e5498 Fixed position & direction when copying object from F12 menu 2015-08-03 22:26:22 +02:00
krzys-h 522c54afc3 Possible fix for MXE builds 2015-08-03 22:12:41 +02:00
krzys-h 6ea98ed995 Fixed screenshot image lag on old GPUs that have problems with not power-of-2 textures (#546) 2015-08-03 22:06:27 +02:00
krzys-h 04960035c1 Save screenshot image in a separate background thread (#546) 2015-08-03 21:40:30 +02:00
krzys-h 5e4a423bf0 Cleaned up "textures/"+something, fixed more possible occurences of #531 2015-08-03 20:55:33 +02:00
krzys-h 1e38edcec7 Fixed InterfaceGlint and InterfaceRain using the same config value name 2015-08-03 20:40:27 +02:00
krzys-h 45d6091a74 Fixed program from object.factory() being kept in BotFactory for every next manual operation 2015-08-03 20:33:45 +02:00
krzys-h 4bdadc8cc8 Updated help file paths 2015-08-03 20:23:35 +02:00
krzys-h 794d1f3cbe Fixed "this" (#547) 2015-08-03 19:56:35 +02:00
Piotr Dziwinski 11b0398c03 Include refactoring
* reordered includes according to correct style
 * removed some unnecessary includes
2015-08-02 17:49:07 +02:00
Piotr Dziwinski 7d8b56d9ab More style fixes 2015-08-02 12:06:14 +02:00
Piotr Dziwinski 3b585d9f51 Some style and whitespace fixes 2015-08-02 11:36:36 +02:00
krzys-h 60ae9b1959 Fixed ExchangePost info saving 2015-08-01 21:19:47 +02:00
MrSimbax a18d195cfd Add an ability to cancel making a building (fixes #509) 2015-07-30 17:47:26 +02:00
krzys-h 119bc62a7c Fixed #542 2015-07-29 22:46:52 +02:00
krzys-h 6818e32150 Fixed shadow mapping disable when not supported (#522) 2015-07-29 22:30:44 +02:00
krzys-h ccd55a4319 Fixed reversed Arrow colors (#537)
A major derp during TraveColor refactoring :P I hope I didn't break anything else
2015-07-29 18:25:36 +02:00
krzys-h 1bc0c891b0 Fixed early profile creation (#538) 2015-07-29 18:17:28 +02:00
krzys-h 11b3615df6 Fixed #541
I broke it in 86f473ac16
2015-07-29 11:53:54 +02:00
krzys_h 62f75892ae Merge pull request #544 from vieux/this_not_type
fix type highlighting in the CBOT editor
2015-07-29 09:53:34 +02:00
krzys-h ab6a8eba2b Possible fix to #482 2015-07-29 09:41:25 +02:00
Victor Vieux 7c421b7151 fix highlighting
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-07-29 00:37:56 -07:00
Victor Vieux 38c64940a5 this is not a type
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-07-29 00:37:29 -07:00
MrSimbax d7cdcab2c5 Fix flatspace editor hint 2015-07-27 18:49:02 +02:00
MrSimbax a5d579fc31 Add filter parameter to radar editor hint 2015-07-27 18:12:38 +02:00
Piotr Dziwinski a5ff361bcc Replace std::regex with boost::regex
std::regex doesn't work in older GCC version (#532)
2015-07-25 09:13:17 +02:00
Piotr Dziwinski 4e836fa1d8 Remove unneeded LoadTexture calls
This caused reading of directory instead of file and caused crash on MacOSX (#531)
2015-07-25 08:49:14 +02:00
Piotr Dziwinski 7e289e7927 Add missing forward declaration in CBotToken.h 2015-07-23 20:48:35 +02:00
krzys-h dfd73118a6 Added flatspace()
Works like space(), but makes sure there is enough flat space for building
2015-07-22 18:26:05 +02:00
krzys-h 59d5545eca Fixed code pause editor bug (#527) 2015-07-22 18:01:24 +02:00
krzys-h 53a4176d29 Fix #528 2015-07-22 17:44:27 +02:00
krzys-h 8e02786dbc Fix #529 2015-07-22 17:42:02 +02:00
krzys-h 393317fa48 Added researched(), canresearch() and buildingenabled()
closes #524
2015-07-22 17:08:51 +02:00
krzys-h d5d8c0b29f Removed the need for progfunc() in object.factory()
Changes to object.factory():
* The second argument will be automatically interpreted as public function name, file name or program code
* The program starts earlier (when the robot is ready, not when the doors open)
* Refactored to std::string
2015-07-22 16:16:16 +02:00
krzys-h 2e606f4dcb Fixed warning in CBrain 2015-07-22 13:56:51 +02:00
krzys-h 329393a65a Added object.velocity, closes #523 2015-07-22 13:46:13 +02:00
krzys-h abdb4e9782 Moved "object" class management to CScriptFunctions 2015-07-22 13:25:51 +02:00
krzys-h cba3863d75 Fixed bug with object loading introduced in 083f216529 2015-07-22 12:51:29 +02:00
krzys-h 083f216529 Team object recoloring (#514) 2015-07-22 12:45:50 +02:00
krzys-h 0c54e1e8de Fixed public program save directory
Such a dumb mistake. AGAIN.
2015-07-22 12:23:26 +02:00
krzys-h 72b9738eb9 Fixed possible problems when trying to use shadow maps in unsupported configuraions (#522) 2015-07-20 22:34:39 +02:00
krzys-h 52a3e0b24f Fixed minimap texture disappearing on texture settings change
Bug mentioned by @erihel in #505
2015-07-20 21:22:34 +02:00
krzys-h e821aa9cef Better scaling of shortcut buttons on widescreen resolutions 2015-07-20 21:07:20 +02:00
krzys-h 4741118b61 Added new options to configuration presets 2015-07-20 20:47:44 +02:00
krzys-h 5593f427f6 Proper fix to #94 (finally!!!!)
It was so simple, wasn't it?
Additionaly:
* fixed texture recoloring after changing texture settings while simulation is running
* fixed annoying "could not open textures/shadow*.png" messages
* don't ChangeColor() if not in simulation to reduce lag in settings
2015-07-20 19:35:20 +02:00
krzys-h 7b3ae32626 Shadow mapping now disables old shadows 2015-07-20 18:56:15 +02:00
krzys-h 9e7cc0bab5 Renamed original shadows to simple shadows 2015-07-20 18:51:01 +02:00
krzys-h f03734d17f Added shadow mapping to settings screen 2015-07-20 18:42:09 +02:00
krzys-h fce1539888 Made settings unavailable during in simulation setup visible but not editable 2015-07-20 17:19:49 +02:00
krzys-h 572b8ea566 Fixed a crash on exiting from win scene to level list 2015-07-20 17:06:28 +02:00
krzys-h e2ebcb769e Added MSAA to settings screen 2015-07-20 16:29:09 +02:00
krzys-h 90756f8b34 Added FilterMode, MipmapLevel and Anisotropy to settings screen 2015-07-20 13:56:45 +02:00
krzys-h a879e496f5 Removed unused texture quality setting 2015-07-20 12:21:16 +02:00
krzys-h 283676fea1 Fixed CEditValue crash
It happened after pressing slider buttons
2015-07-20 12:12:01 +02:00
krzys-h 1c947f9a80 Renamed some phases to more meaningful names 2015-07-19 23:11:41 +02:00
krzys-h a2f1aa195b Combined all level list phases into one, removed PHASE_TERM 2015-07-19 23:07:57 +02:00
krzys-h 347654db15 Refactored CBot class "file" to PHYSFS 2015-07-19 22:34:41 +02:00
krzys-h 0554a77813 Refactor reading "object" class in CBot 2015-07-19 21:53:08 +02:00
krzys-h 8c87eedd28 Fixed huge lag on closing settings
Introduced in 02c24fbf27, this was supposed to make it more resistant to crashes but turned out to generate huge lag on closing settings
Instead, I added manual .Save() after every value change
2015-07-19 21:35:55 +02:00
krzys-h d3c3f47b19 Fixed particle rendering (#518)
Introduced in 5a1c6d19ff - I'm so dumb D:
I kinda recently noticed some of the SpaceShip particles were missing...
2015-07-19 21:17:58 +02:00
krzys-h 8ce3a783bb Fixed EndMissionTake processing order with immediat=1
immediat=1 is supposed to work only if this condition AND all conditions above are true
2015-07-19 19:20:55 +02:00
Piotr Dziwinski 73536290b2 Fix for incorrect compile flags in colobot-lint 2015-07-19 18:11:12 +02:00
Piotr Dziwinski 963fa15a1c Fix for #516 2015-07-19 16:43:03 +02:00
krzys-h 264f5dc278 Removed obsolete save directory configuration
This was used in one of the CeeBots probably for setting up networked installations in schools. This is now obsolete since now those are only paths relative to main PHYSFS save directory.
2015-07-19 16:05:09 +02:00
krzys-h ffb387f8af Changed scene loading to use CPlayerProfile for paths 2015-07-19 16:05:09 +02:00
krzys-h 7dc3e90e41 CPlayerProgress -> CPlayerProfile 2015-07-19 16:05:09 +02:00
krzys-h 02c24fbf27 CProfile -> CConfigFile 2015-07-19 16:05:09 +02:00
Tomasz Kapuściński 644f5b4d7f Corrected some problems with dynamic shadows 2015-07-19 00:07:59 +02:00
krzys-h e2691d943c Fixed #346
Thanks @erihel
2015-07-18 23:16:14 +02:00
krzys-h 3e1fc06d6c CPlayerProgress
Extracted most operations on user profile from CRobotMain and CMainDialog to a dedicated class
2015-07-18 23:14:20 +02:00
krzys-h 86f473ac16 Finished support for up to 999 chapters and levels 2015-07-18 19:48:25 +02:00
krzys-h ea9361fbb4 LevelCategory enum 2015-07-18 19:45:40 +02:00
Tomasz Kapuściński 59a68892c6 Game displays an error message and uses default graphics device when unknown device is selected with -graphics switch 2015-07-18 12:03:33 +02:00
Tomasz Kapuściński 1d69021e94 Potential fix to #511 2015-07-18 02:02:38 +02:00
Piotr Dziwinski 25eaf8f72f Add MakeUniqueArray for array types 2015-07-17 20:57:12 +02:00
Piotr Dziwinski b3b6435039 Use MakeUnique with level parser classes 2015-07-17 20:38:21 +02:00
krzys-h 35043e04de Addressed commit comments on a872ea128b 2015-07-17 20:29:53 +02:00
Piotr Dziwinski a872ea128b Add MakeUnique template to avoid use of naked new 2015-07-17 20:06:59 +02:00
krzys-h 2c0baeec35 Fixed potential error in locale logging
setlocale() result is valid only until next call to setlocale()
2015-07-17 19:55:02 +02:00
krzys-h dffeff929e Removed manual memory management in CBrain in program list 2015-07-17 19:53:17 +02:00
krzys-h 5e44092144 Fixed brain.cpp compilation under MSVC 2015-07-17 17:01:31 +02:00
krzys-h 2ef68cf12d Fixed Polish translations for Scribbler 2015-07-17 11:59:44 +02:00
krzys-h 14f784646b Refactored Scribbler recorder to std::string 2015-07-17 11:52:11 +02:00
krzys-h 82247e75fc Fixed a crash
This replaced more than I throught
2015-07-16 22:27:25 +02:00
krzys-h 9e19d8433c Removed old CBot-related files 2015-07-16 22:17:54 +02:00
krzys-h aa0946f4ba Fixed line endings in pathman.cpp 2015-07-16 22:15:22 +02:00
krzys-h 999c35e46b Fixed Alt+Enter starting not runnable programs, fixes #510 2015-07-16 22:12:44 +02:00
krzys-h c8f6e8124e Replaced CLogger::GetInstancePointer() calls with GetLogger() 2015-07-16 22:12:44 +02:00
krzys-h c115d72d71 More TraceColor refactoring 2015-07-16 22:09:50 +02:00
krzys-h 2b9811d225 Movie lock refactoring 2015-07-16 22:09:50 +02:00
Piotr Dziwinski 6dcf4dffa6 Refactor CSNDFile -> CSNDFileWrapper
This seems more consistent
2015-07-16 21:47:48 +02:00
Piotr Dziwinski 8ca77f27a1 Extracted CSDLFileHandler from CResourceManager
This also possibly fixes some rare error cases (e.g. #439)
2015-07-16 21:13:38 +02:00
krzys-h 8a72f0a849 Addressed commit comments on a0e0ee3631 2015-07-16 20:09:06 +02:00
krzys-h a0e0ee3631 Separate shortcut bars for teams 2015-07-16 13:46:40 +02:00
Piotr Dziwinski f581d87474 Fix double increment bug in OpenAL channel allocation 2015-07-16 07:16:55 +02:00
Piotr Dziwinski c8498548cc Remove manual memory management in oalsound
Plugging a few more memory leaks detected by valgrind
2015-07-15 22:43:30 +02:00
Piotr Dziwinski 83f3cfa6e0 Fix some memory problems reported by valgrind
Also remove some manual memory management
2015-07-15 20:23:21 +02:00
Piotr Dziwinski 31bc740f4b Fix focusing issues with controls and cheat console 2015-07-15 19:11:48 +02:00
krzys-h 61ea372e51 Fixed enemy ruins not becoming neutral on destruction 2015-07-15 18:49:15 +02:00
krzys-h 80963f1a2b Added global magnifyDamage setting 2015-07-15 18:15:26 +02:00
Piotr Dziwinski 94ea1ff106 DeselList refactoring
Make CRobotMain hold selected object history instead of
every object holding some part of it
2015-07-15 18:09:23 +02:00
Piotr Dziwinski 9af1422589 Fix setting wrong explosion type 2015-07-14 22:14:14 +02:00
krzys-h 730319ba20 Fixed Robby (OBJECT_TOTO) animations 2015-07-14 21:40:07 +02:00
Piotr Dziwinski d5da68d59a Refactor old Get/SetAngle/Zoom -> Get/SetPartRotation/Scale 2015-07-14 21:35:43 +02:00
krzys-h e1223ff881 Fixed shortcuts behavior
It was kinda broken after implementing code battles
Also, fixed overlap of shortcuts bar with cheat console
2015-07-14 21:32:08 +02:00
krzys-h a1a96c62ab Fixed system mouse setting 2015-07-14 21:03:40 +02:00
Piotr Dziwinski 1183ed1980 Refactor old Get/SetPosition -> Get/SetPartPosition 2015-07-14 19:40:39 +02:00
Piotr Dziwinski 7c229b4e83 Fix reading new model format with CRLF line endings 2015-07-14 19:40:07 +02:00
Piotr Dziwinski 3f41555a61 Better exception handling in CRobotMain 2015-07-14 18:46:22 +02:00
Piotr Dziwinski 0d1b97510d Add exception handling when creating new objects on level loading 2015-07-14 18:28:42 +02:00
krzys-h 62fddd6d4f Made pendown() trace opaque 2015-07-14 17:38:29 +02:00
krzys-h 5a1c6d19ff Removed unused particle types 2015-07-14 14:16:19 +02:00
krzys-h 4506a4b8bd TraceColor enum 2015-07-14 13:53:50 +02:00
Piotr Dziwinski fdc0081bb8 Fix checking boolean like int 2015-07-13 23:04:11 +02:00
Piotr Dziwinski 62fdfc9f92 Refactor ResetCap -> AnimateOnReset 2015-07-13 22:47:11 +02:00
Piotr Dziwinski 20dbb8320b Remove unused reset code 2015-07-13 22:46:51 +02:00
krzys-h 4d7de592b4 Merged destructor parsing from tr00per/dev
Merge branch 'dev' of https://github.com/tr00per/colobot into dev
2015-07-13 19:24:43 +02:00
krzys-h 78f4749134 Disallow controlling enemy objects from CBot 2015-07-13 18:53:56 +02:00
krzys-h 0e66104829 Hacked CBot engine to get pointers to CObject* in calls to class members 2015-07-13 18:40:13 +02:00
krzys-h 79c131394d Separate DoneResearch for teams 2015-07-13 18:13:28 +02:00
krzys-h 3479c51bb9 Refactored EnableBuild, EnableResearch and DoneResearch
* Moved from global variables to CRobotMain members
* Added functions for accessing the values
* Cleaned up some code related to building objects, BotFactory, ResearchCenter and AutoLab
2015-07-13 17:38:19 +02:00
krzys-h 38a0849e10 Added system mouse option
This reverts commit e21853d632.
2015-07-13 12:11:11 +02:00
krzys-h 6e404f5aa2 Better mouse scaling on widescreen resolutions 2015-07-13 11:58:52 +02:00
Piotr Dziwinski 9023aac960 Fix for #504 2015-07-12 20:49:00 +02:00
Piotr Dziwinski 6c7a79de5a Fix for #503 2015-07-12 20:44:46 +02:00
Piotr Dziwinski e72936c240 Clean up more functions from COldObjectInterface 2015-07-12 20:05:12 +02:00
Piotr Dziwinski 394f911d7b Remove unnecessary #include "object/object.h" 2015-07-12 14:23:18 +02:00
Piotr Dziwinski 3ed8980c46 Make CTask classes use COldObject 2015-07-12 14:22:12 +02:00
Piotr Dziwinski 45302a3f4e Make CPhysics and CBrain use COldObject 2015-07-12 14:19:09 +02:00
Piotr Dziwinski 2c474d7c06 Make CMotion classes use COldObject 2015-07-12 14:01:14 +02:00
Piotr Dziwinski 16883fcdc4 Make CAuto classes use COldObject 2015-07-12 14:01:07 +02:00
Piotr Dziwinski fdb594b9f7 Fix crash when replacing power cell 2015-07-12 13:19:41 +02:00
Piotr Dziwinski a1e5812740 Make object deletion safe while iterating through their list
Perhaps a bit of a hack but there is no other way to implement this now
2015-07-12 13:16:07 +02:00
Piotr Dziwinski 4dc40a8853 Fix missing curly braces 2015-07-12 12:38:25 +02:00
Piotr Dziwinski 37b0d5796d Fix PNGSaveSurface not closing file sometimes 2015-07-12 12:33:30 +02:00
Piotr Dziwinski 9a7c1961a4 GetPostion(), GetRotation() and GetScale() in CObject interface
Also replace old calls like GetPosition(0) to GetPosition()
2015-07-12 11:05:50 +02:00
Piotr Dziwinski 57e3e16517 Added check to avoid possible object deletion bug
Objects must not be deleted while iterating through their list
2015-07-12 10:34:00 +02:00
Piotr Dziwinski fcbbbcb83c Fix some more CObject interface issues
* fix mission 1.3
 * fix saving/loading missions
 * fix compile warnings
2015-07-12 00:03:57 +02:00
krzys-h 03717e11d4 Added aspect ratio in resolution list (#501) 2015-07-11 23:53:25 +02:00
Piotr Dziwinski e8582d214c CStaticObject subclass using new model framework
* added reading/writing working version of new model format V3
 * added CStaticObject with minial interface intended for
   non-interactive static objects like trees
 * converted first model, tree0, to new format
2015-07-11 19:52:38 +02:00
krzys-h 639de56e6c Fixed file.readln() help file 2015-07-11 18:36:36 +02:00
Piotr Dziwinski 6dcef71802 GlobalSphere -> CameraCollisionSphere refactoring 2015-07-11 13:52:04 +02:00
Piotr Dziwinski f4b2f3468d CPoweredObject interface 2015-07-11 13:38:27 +02:00
krzys-h 36d08e852c Better splashscreen scaling on widescreen resolutions 2015-07-11 12:57:18 +02:00
Piotr Dziwinski 0a85fae9b5 Fix crash in appearance menu 2015-07-10 23:58:53 +02:00
krzys-h 9537048964 Cleaned up GetHelpFilename 2015-07-10 23:30:11 +02:00
Piotr Dziwinski 4c10730f87 CCarrierObject interface 2015-07-10 23:16:55 +02:00
Piotr Dziwinski 8d5ddd848d CJostleableObject interface 2015-07-10 23:04:30 +02:00
Piotr Dziwinski 5d30de0d09 CProgrammableObject interface 2015-07-10 20:46:33 +02:00
Tomasz Kapuściński 17ae31e639 Added 'speed ###' cheat for changing simulation speed to arbitrary value 2015-07-10 20:45:50 +02:00
krzys-h 24db675d3f Added x6 speed option 2015-07-10 20:17:00 +02:00
Piotr Dziwinski 0dfbb00491 Remove unused variable 2015-07-10 19:55:18 +02:00
Piotr Dziwinski 93479af188 CTransportableObject interface 2015-07-10 19:51:49 +02:00
krzys-h 52f809b8bb Removed cmdline limit 2015-07-10 13:40:29 +02:00
Piotr Dziwinski b84130e067 Fix not updating track texture mapping 2015-07-10 12:22:00 +02:00
krzys-h ad08d50bea Renamed some CAuto and CMotion classes 2015-07-10 12:18:21 +02:00
krzys-h 26619e3f88 Removed old level parser functions (cmdtoken.cpp) 2015-07-10 11:51:59 +02:00
krzys-h e6c6b77be2 Removed old Teen objects
The models for them were removed a looong time ago, but the code was left for no reason
2015-07-10 11:37:32 +02:00
krzys-h c63efeca46 Fixed EndMissionTake conditions (again) 2015-07-10 10:45:30 +02:00
krzys-h d3c3a51ede Don't open joystick if it's not enabled in ChangeJoystick 2015-07-10 10:28:04 +02:00
krzys-h 20a367783b Added joystick settings in colobot.ini 2015-07-10 10:25:31 +02:00
krzys-h 7e41e9fe23 Refactored keybindings storage 2015-07-10 10:11:40 +02:00
krzys-h 3d5bc5c563 Fixed unused variable warnings 2015-07-10 10:11:40 +02:00
Piotr Dziwinski b0ac2f8326 Refactor CObject interface related to crash spheres 2015-07-10 09:38:53 +02:00
krzys-h 5a68558f4c Implemented basic joystick selection
You can select joystick in the config file, there is still no GUI. By default, the first available joystick is used.
issue #171
2015-07-10 00:05:43 +02:00
krzys-h bd4a661a06 Made autosave timer independent from simulation speed, closes #485 2015-07-09 23:23:38 +02:00
krzys-h b7c3a8a30b Don't hardcode script4Runnable=in exercises, closes #493 2015-07-09 23:09:08 +02:00
krzys-h 978fc8f1fb Remove program limit in scene files, closes #494 2015-07-09 23:01:18 +02:00
Piotr Dziwinski c585922a45 Use boost::lexical_cast instead of std::to_string 2015-07-09 22:53:58 +02:00
Piotr Dziwinski 93e950584a Refactor model-related code
* refactored model loading code based on code from dev-models
 * support new model format V2 (without LOD levels)
 * removed LOD levels support in CEngine and from model files
 * preparations for new model format V3:
   - support for multiple meshes in one model file
   - support for saving crash spheres and shadow spots
   - removed all direct dependencies on CEngine enum values
   - quantized model rendering states to new flags and enums
2015-07-09 21:37:04 +02:00
Piotr Dziwinski 9b232ee3f5 Sound enum refactoring
* rename Sound -> SoundType
 * add parsing string to SoundType
2015-07-09 21:32:25 +02:00
krzys-h c84ce92a86 Fixed F12 debug screen background 2015-07-09 18:50:11 +02:00
krzys-h dae7cdf229 Fixed build() particles 2015-07-09 18:45:52 +02:00
krzys-h 7c20bb4bf6 Fixed counting of nautral objects in EndMissionTake 2015-07-09 18:28:09 +02:00
krzys-h ce760aa9a3 Added All back to ObjectType parser
I throught this was unused, but it's actually used in NewScript
2015-07-08 20:21:30 +02:00
krzys-h 1361473358 Renamed Mission -> Level, MissionController -> LevelController
As suggested by @CoLoRaptor
2015-07-08 20:20:46 +02:00
krzys-h c18b5daf57 Don't use binary literals in radar filters
@tomaszkax86 noticed that this syntax is valid only in C++14 and Visual Studio 2013 doesn't support that
2015-07-08 19:05:11 +02:00
krzys-h b75ab7d8f6 Fixed radar() detecting neutral objects as enemies 2015-07-07 22:27:44 +02:00
Piotr Dziwinski b0b313f707 Fix for issue #492 2015-07-07 21:36:37 +02:00
krzys-h a6ccd7f270 Added TeamName 2015-07-07 21:25:44 +02:00
krzys-h 5da4adad41 Added Any constant in CBot 2015-07-07 19:01:18 +02:00
krzys-h 79c5fabfe6 Support for team filters in radar() 2015-07-07 18:54:36 +02:00
krzys-h 9a873c9bea Added object.team in CBot 2015-07-07 18:11:28 +02:00
krzys-h f94519b240 Don't finish mission if there are no win conditions
This replaces the old EndMissionNever hack
2015-07-07 18:04:17 +02:00
krzys-h a3726799c4 Added support for teams in EndMissionTake
Also fixed a bug in previous commit that caused lost= conditions to be skipped if previous min= max= condition was not met
2015-07-07 17:48:49 +02:00
krzys-h a32efc09a2 Refactored EndMissionTake and AudioChange 2015-07-07 16:17:19 +02:00
dreamer.dead 958ef43c1e Address review remarks, fix names and errors in code. 2015-07-06 22:00:33 +03:00
dreamer.dead b3c2d2c450 Set CBotVar::m_binit type to specific enum instead of plain int. 2015-07-05 23:39:55 +03:00
Piotr Dziwinski f1684f85be Introduce new CObject base class and mixin class framework 2015-07-02 23:50:50 +02:00
Piotr Dziwinski 80d93c0fea Fix comment changed by mistake 2015-06-30 18:47:35 +02:00
Piotr Dziwinski f6bc8f94bf Rename fret/truck to cargo/transporter 2015-06-29 23:11:02 +02:00
Piotr Dziwinski b00d62b9bb Further cleaning of CObject interface
* remove unused functions/members
 * delegate some functions to other objects
 * change some names to be more meaningful
2015-06-29 22:46:13 +02:00
Tomasz Kapuściński c7ccb29d6a Removed spoiler from tooltip in options menu (fixes #489) 2015-06-28 23:07:42 +02:00
Tomasz Kapuściński ac291f5bea Fix for issue #488 2015-06-28 21:05:12 +02:00
Piotr Dziwinski f871ba4729 Create CExchangePost subclass 2015-06-27 23:22:55 +02:00
Tomasz Kapuściński 1ccb807091 Fix for issues #486 and #487 2015-06-27 18:06:49 +02:00
krzys-h 78e09c757d Basic support for teams and code battle missions 2015-06-26 22:07:55 +02:00
krzys-h 2a672482a5 Vault now locks only objects created during level loading (fixed #164) 2015-06-26 20:19:16 +02:00
Tomasz Kapuściński 195667ab2c Potential fix for rendering problems in OpenGL 2.1 engine under Linux 2015-06-26 19:55:46 +02:00
krzys-h 4fc8364136 Fixed Destroyer object destruction (fixes #308) 2015-06-26 19:20:16 +02:00
krzys-h 2509f99776 Fixed program arguments not being parsed on restart (#483) 2015-06-26 18:51:39 +02:00
Tomasz Kapuściński efd0b2b28f Corrected energy cell's angle when created with robot 2015-06-26 18:07:54 +02:00
Tomasz Kapuściński ba3c049077 Corrected problem with loading level background images 2015-06-26 14:32:44 +02:00
Piotr Dziwinski 88ec9aaae3 Drop GCC 4.6 support 2015-06-26 00:24:32 +02:00
Piotr Dziwinski 7e21d3bd79 Get rid of some more manual memory management 2015-06-26 00:24:05 +02:00
Piotr Dziwinski 67be6fca2a CObject interface cleanup
* remove unused functions and members
 * make protected functions used only locally or in factory
 * rename some functions to be more meaningful
 * refactor some enums to enum classes
2015-06-25 20:43:50 +02:00
Piotr Dziwinski 7814c0c7bd Remove unused field "material" from CObject class in CBot 2015-06-25 18:07:48 +02:00
Tomasz Kapuściński 37e2f24fbc Corrected small rendering problem 2015-06-25 11:47:42 +02:00
Tomasz Kapuściński 3cc2857372 Small corrections in MSAA implementation 2015-06-22 23:42:01 +02:00
Tomasz Kapuściński 90bf51ba54 Possible fix for #458 2015-06-22 22:53:55 +02:00
Piotr Dziwinski 8806d1708d Proper CAuto, CBrain, CMotion, CPhysics, CPyro lifetime management
* change manual memory manament to std::unique_ptr
 * create CPyroManager
 * finally get rid of CInstanceManager
2015-06-22 21:58:58 +02:00
Piotr Dziwinski 7ae308cc75 Fix saving addresses instead of data in user profile 2015-06-22 21:25:00 +02:00
Tomasz Kapuściński f2318803e5 Added Multisample anti-aliasing (MSAA) 2015-06-22 00:56:47 +02:00
Piotr Dziwinski 02ffdcfe23 Refactor level parser code
* replace manual memory management with std::unique_ptr
 * remove unnecessary dynamic allocations
 * make coding style consistent
2015-06-21 20:59:23 +02:00
Piotr Dziwinski 5f1d3c21d4 Fix some more warnings reported by Clang 2015-06-21 19:46:01 +02:00
Piotr Dziwinski 2d623b4427 Fix introduced compilation warnings 2015-06-21 19:38:07 +02:00
Tomasz Kapuściński dabfdf1ea0 Merge branch 'dev' of https://github.com/colobot/colobot into dev 2015-06-21 18:51:24 +02:00
Tomasz Kapuściński 7d57ec634e Refactored framebuffer implementations 2015-06-21 18:48:31 +02:00
Piotr Dziwinski 2513052260 Fix setting position of power cells 2015-06-21 16:29:46 +02:00
Piotr Dziwinski 304542afe2 Some syntax sugar for iterating through all objects 2015-06-21 16:22:09 +02:00
Piotr Dziwinski 0c9a9bce98 Proper CObject lifetime management
CObjectManager is now the only class responsible for storing CObjects
2015-06-21 15:13:55 +02:00
Piotr Dziwinski fed67e6640 Rename objman.h/cpp -> object_manger.h/cpp 2015-06-20 20:02:40 +02:00
Tomasz Kapuściński 94851c2694 Merge branch 'dev' of https://github.com/colobot/colobot into dev 2015-06-20 20:02:11 +02:00
Tomasz Kapuściński ec3069eea7 Defaulted shadow color value to 0.5 2015-06-20 20:02:06 +02:00
Piotr Dziwinski f9b09d08f0 Create CObjectFactory
* move functions creating objects to new class CObjectFactory
 * replace calls to CObject::Create*() with CObjectManager::Create()
 * move creation/deletion of some objects to better places
 * make CModelManager non-singleton
 * clean up some code in changed functions
2015-06-20 19:37:25 +02:00
Tomasz Kapuściński 74a31c9fb4 Corrected compilation errors on Linux builds 2015-06-16 19:30:35 +02:00
Tomasz Kapuściński ff44637d49 Removed VBO override switch and some unnecessary code 2015-06-16 18:00:42 +02:00
Tomasz Kapuściński 26ec927b37 Corrected compilation errors and warning 2015-06-15 20:27:44 +02:00
Tomasz Kapuściński 012eb10e19 Added automatic graphics detection (-graphics auto) 2015-06-15 20:20:03 +02:00
Tomasz Kapuściński a880210b3d Added ShadowRange option 2015-06-15 18:41:31 +02:00
Tomasz Kapuściński 6434ff55dd Ending splashscreen enhancement (fixes #472) 2015-06-05 20:20:06 +02:00
Tomasz Kapuściński ae29ebead3 Defaulted shadow color to 0.5 in OpenGL 2.1 engine 2015-06-05 19:48:28 +02:00
Tomasz Kapuściński 66d865942c Added OpenGL 2.1 shaders for per-pixel lighting 2015-06-02 16:55:03 +02:00
Tomasz Kapuściński d477caed3e Second attempt at correcting compilation error 2015-06-01 18:41:14 +02:00
Tomasz Kapuściński 7acca9feb8 Corrected compilation error and unsigned comparison warnings 2015-06-01 17:45:51 +02:00
Tomasz Kapuściński d112971c3e Corrected shadow mapping and added experimental self-shadowing 2015-06-01 17:22:49 +02:00
Tomasz Kapuściński a0c56f54cb Shader and buffer optimizations 2015-06-01 17:21:10 +02:00
Tomasz Kapuściński d33ddae15a Added warnings and information what shader files are not available 2015-05-29 12:39:14 +02:00
Tomasz Kapuściński f69dfe3421 shield() rejects incorrect robots that try to invoke it (should fix #475) 2015-05-28 14:03:05 +02:00
Tomasz Kapuściński e1a0f5b1c7 Added OpenGL 2.1 engine 2015-05-27 22:12:02 +02:00
Tomasz Kapuściński 08bf066f78 Added shadow color setting 2015-05-27 21:58:32 +02:00
Tomasz Kapuściński 55b4e73a7a Corrected a problem with strmid() 2015-05-22 20:34:35 +02:00
Tomasz Kapuściński fa67e815b8 Implemented per-vertex lighting and set it as default in OpenGL 3.3 engine 2015-05-22 18:53:51 +02:00
Tomasz Kapuściński 8abdd4b740 Improved shadow mapping 2015-05-21 18:18:46 +02:00
Tomasz Kapuściński f67c01e5e7 Added proper render to texture support 2015-05-21 18:03:17 +02:00