100 Commits
Author SHA1 Message Date
Matei 21d4808de3 Only use --no-undefined link flag on Linux, because it is only present in GNU ld.
This was SVN commit r7024.
2009-07-18 22:37:03 +00:00
Matei 4af379eec6 Fixed a bug in tan that was returning sin.
This was SVN commit r6720.
2009-03-03 06:45:44 +00:00
Matei 09f97a3422 Some fixes for OS X:
- Find enet properly
- Type conversion of size_t's in JS

This was SVN commit r6324.
2008-08-11 04:18:10 +00:00
Matei 5d35f6bfe0 Increase turn length to 300ms to work better with lag.
This was SVN commit r6318.
2008-08-08 05:57:10 +00:00
Matei 7addd3872f Added quickstart script.
This was SVN commit r6316.
2008-08-08 05:13:59 +00:00
Matei 98dd1a1bb4 Refactored "generic" order to just call it "contact action", and added support for intercepting targets if performing a contact action while moving.
This was SVN commit r6290.
2008-07-29 08:22:56 +00:00
Matei 0e8b7c5bc7 Removed some long commented out code.. no point keeping it there since it's in SVN.
This was SVN commit r6289.
2008-07-29 07:01:23 +00:00
Matei 435ac684e3 Fixed an bug where double-clicking on the minimap, or dragging the view and them leaving the minimap window, did not clear the "clicking" flag and caused further mouse motion to move the view around.
This was SVN commit r6288.
2008-07-29 06:56:38 +00:00
Matei 1144798b70 Use traits.id.tooltip rather than traits.id.rollover for descriptions on train buttons.
This was SVN commit r6278.
2008-07-24 06:12:17 +00:00
Matei d0c6805725 Fixed bug that was causing population to go negative. It was due to a unit being killed by multiple enemies in the same frame, which led to multiple calls of the death event handler. The fix is twofold: First, kill() only calls the event handler the first time the unit is killed. Second, damage() (in JS), which apart from killing things also loots them, makes sure that the unit is not already being destroyed. This latter fix is to ensure that we don't get a huge amount of loot by simply attacking a low-HP unit with many soldiers simultaneously, so they kill it in the same frame.
This was SVN commit r6276.
2008-07-24 05:50:45 +00:00
Matei 75a9b2f357 Made stance-setting work with multiplayer.
This was SVN commit r6274.
2008-07-24 05:25:14 +00:00
Matei 2ff3c7ac61 Added combat test map.
This was SVN commit r6270.
2008-07-23 05:58:44 +00:00
Matei aebe9a7936 Added active field to players to check whether the player is a human or CPU.
This was SVN commit r6267.
2008-07-23 05:21:57 +00:00
Matei 95f3036e74 Cleaner production icon tooltips.
This was SVN commit r6266.
2008-07-23 05:03:46 +00:00
Matei 86ea20df7b Fix a crash which happened when a unit with no actions.move tried to run (it got past the JS guard because JS code crashed).
This was SVN commit r6237.
2008-07-16 04:23:44 +00:00
Matei 0cbb38bfd9 Fixed 3+ player games. The problem was the FinalizeSlots method in GameAttributes, which confused player and slot IDs by deleting nonexistent slots/players from the array. Since this doesn't seem particularly useful (and is even undesirable for scenarios where some players *want* to be the last slot and to leave others empty), I commented it out rather than having the code incur the extra complexity of supporting renumberings.
This was SVN commit r6228.
2008-07-14 06:40:05 +00:00
Matei 8161197f0e Comment out error-producing code that tried to render player names in slots.
This was SVN commit r6227.
2008-07-14 06:29:57 +00:00
Matei 9025056ffd Made rally point setting net-safe.
This was SVN commit r6225.
2008-07-13 17:37:45 +00:00
Matei 36b18f646f Added shouldRun parameter to order(ORDER_GENERIC) calls from scripts.
This was SVN commit r6224.
2008-07-13 16:31:03 +00:00
Matei e4966f6f1b Added running support to GENERIC orders through a field that can be sent across the network (previous implementation used to be by setting properties on the entity itself).
This was SVN commit r6223.
2008-07-13 06:24:50 +00:00
Matei d5fedc7c76 Fixing some multiplayer issues:
a) Run commands were not being sent accross properly because the JS just
directly set flags on the entity. Note: The current fix has the
side-effect of making it no longer possible to double-rightclick a
target to charge, run-gather, etc. That will be fixed in a later commit.
b) EntityLists were serialized in a format that made it impossible to
deserialize a zero-length list.

This was SVN commit r6221.
2008-07-13 05:56:27 +00:00
Matei 1e64089cdb Hide console window when launching atlas and actor viewer.
This was SVN commit r6220.
2008-07-13 04:57:16 +00:00
Matei cc62b4196a Removed credits roll from main logo - it was too annoying to click it accidentally cause there was no way to get out.
This was SVN commit r6217.
2008-07-12 19:21:22 +00:00
Matei f6ac13c15a Networking fixes - it now more or less works over ENet!
This was SVN commit r6216.
2008-07-12 19:08:38 +00:00
Matei 088f3b54be - Treat units with health.max = 0 (the default when not defined as immortal and unattackable. This applies to Settlements, trees, etc. Should solve the problem of these things being killed by arrows by mistake.
- Better "unit X has killed unit Y" message - now includes player
number.

This was SVN commit r6213.
2008-07-12 07:22:11 +00:00
Matei 01dc8c3d72 Fix an annoying error message when some properties of templates were not defined.
This was SVN commit r6212.
2008-07-12 07:11:27 +00:00
Matei 23ade72800 Moved latium_generated back outside old since it is the default map.
This was SVN commit r6205.
2008-07-06 02:53:34 +00:00
Matei 2109f4eb0e Merged in Dacian's network changes.
This was SVN commit r6187.
2008-07-03 06:29:22 +00:00
Matei 3892f03e2e Use windowed mode by default.
This was SVN commit r5898.
2008-04-27 18:09:09 +00:00
Matei bdc7f3af7c Initialize CNetServerSession and CNetClient::CServerSession at server and client startup rather than when they are first created, to prevent crashes in SpiderMonkey due to intializing during an event handler or in a different thread.
This was SVN commit r5854.
2008-04-05 18:36:39 +00:00
Matei 455556783e # Fixed walking on a multistep path, which sometimes stopped after the first few steps.
The problem was incorrect logic in the start-next-segment-of-the-path
code that was added to allow multiple segments to be handled within the
same update. I'm not sure how this worked before but it seemed to give
continuous paths! Likely that's because the pathing for contact actions
is different.

Also added more sanity checks in Aura.cpp for deleted entities in the
m_Influenced queue. There was a crash caused by something here though
it's hard to reproduce.

This was SVN commit r5597.
2008-02-04 08:24:17 +00:00
Matei e4f3567d39 # Fixed a file save bug (wrong data size was being written, making the saved file invalid).
This was SVN commit r5595.
2008-02-04 07:30:15 +00:00
Matei 7773b9b204 # Some fixes to projectiles
- Removed use of erase() in the middle of iterating through projectiles
in CProjectileManager - that was dangerous! Replaced projectiles vector
with a linked list to make it easy and efficient to delete elements in
the middle.
- Fixed animation. It seemed like a problem with updating the Y position
came up and was more apparent as we lowered the turn length.

This was SVN commit r5593.
2008-02-03 09:10:15 +00:00
Matei 0201229520 Fixed build on Ubuntu.
This was SVN commit r5584.
2008-01-26 04:43:02 +00:00
Matei f304a4debe Enable overlays other than the pathfinding one when the pathfinding one is hidden.
This was SVN commit r5496.
2007-12-01 18:05:46 +00:00
Matei 207d1367ec # A number of network synchronization fixes.
- The server will no longer send a new turn until the previous one has
been "acknowledged". (TODO: this may create lag between turns in its
current form; investigate and possibly allow executing two turns while
the third is being negotiated).
- Mutexes are now being used in NetServer and NetClient to ensure
commands go into the right batches.
- Commented out some orders in the GUI code that should not be there and
are not 100% working anyway (they were part of the follow/formation
system).
- Units that spawn or are created by scripts now have net-safe position
and orientation.
- Added a debug flag that can be turned on to print details about when
commands are received and executed (DEBUG_SYNCHRONIZATION). This is
especially useful if you diff the stdouts of two running games. There
should be no differences if everything is in synch.

This was SVN commit r5463.
2007-11-18 09:09:06 +00:00
Matei 29e5130153 Updated required libraries to include some AtlasUI libs.
This was SVN commit r5437.
2007-11-10 02:58:23 +00:00
Matei 6bbd564910 Updated Ubuntu instructions.
This was SVN commit r5436.
2007-11-09 19:17:42 +00:00
Matei 57ac4228d1 Updated build instructions for Linux and commented out visibility options
that make GCC 4.1 fail to link the game.

This was SVN commit r5435.
2007-11-09 18:48:23 +00:00
Matei 6ba71202c9 # Multiplayer synchronization fixes.
This was SVN commit r5429.
2007-10-23 06:52:23 +00:00
Matei 6f376f0b0f Changed console net log level to ERROR, to reduce message spam.
This was SVN commit r5423.
2007-10-21 09:40:06 +00:00
Matei 56b38ddd1e # Engine overview doc started.
This was SVN commit r5421.
2007-10-20 18:30:32 +00:00
Matei 41d3ef5fa5 Fix compile on GCC 4.1, where the ArraySize function trick did not work.
This was SVN commit r5418.
2007-10-17 07:36:12 +00:00
Matei e6604e7c0e Fix more DCDT compile errors (in gcc 4.1.2 on Linux).
This was SVN commit r5417.
2007-10-16 08:12:48 +00:00
Matei ddffdba2c3 Changed console character to a _ since the vertical line glyph didn't seem to be available on OS X.
This was SVN commit r5415.
2007-10-13 18:22:20 +00:00
Matei 8a5ba90c53 Removed assert(g_Console) from console logging functions, because g_Console might not exist on shutdown.
This was SVN commit r5414.
2007-10-13 16:59:03 +00:00
Matei 990f603655 Fixed a freeze where a lock was acquired twice (in OpenFile and Activate).
This was SVN commit r5413.
2007-10-13 16:56:05 +00:00
Matei 336573b114 Fix Windows and GCC compile errors.
This was SVN commit r5412.
2007-10-13 16:36:17 +00:00
Matei caeade1b95 Fix struct sockaddr.
This was SVN commit r5408.
2007-10-12 07:41:19 +00:00
Matei 277ed33da6 # OS X fixes.
- Networking no longer tries to use IPV6, ignoring the family type of
CSocketAddr. This address will be replaced when we switch to ENet
anyway.
- The name of the Atlas semaphore now also includes a timestamp, since
the RNG generated the same sequence of names for multiple runs of the
game, causing problems if the games crashed and leaked semaphores, and
making debugging painful.
- get_executable_name now also works if the game is within an app bundle
(useful for packaging it more nicely later on, and since wxWidgets
expects us to be in an app bundle).

This was SVN commit r5407.
2007-10-11 08:00:05 +00:00
Matei 46dd72de18 # Fixed STL debug compile errors on GCC.
This was SVN commit r5406.
2007-10-11 07:55:24 +00:00
Matei fa0a07cdab # Fixed DCDT compile errors on GCC.
This was SVN commit r5405.
2007-10-11 07:54:52 +00:00
Matei 4118e27783 Restored larger window resolution.
This was SVN commit r5402.
2007-10-11 04:36:15 +00:00
Matei ea878fddc6 Field footprint size reduced.
This was SVN commit r5348.
2007-09-16 20:03:37 +00:00
Matei 576a0aa421 # Made units that build a field start auto-gathering it. Also updated field foundation.
This was SVN commit r5347.
2007-09-16 20:01:57 +00:00
Matei 25e55c1657 # Fixed XML bug in field entity.
This was SVN commit r5344.
2007-09-16 19:15:16 +00:00
Matei e732631a68 # Fixed a bug with hitpoints remaining at 0 while a building was built, and an initialization issue that prevented fields from being gatherable.
This was SVN commit r5342.
2007-09-16 17:43:38 +00:00
Matei efd08a21f9 Use #if instead of #ifdef to detect HAVE_X.
This was SVN commit r5323.
2007-09-03 23:32:16 +00:00
Matei 118a7934e1 Disable fancy water by default.
This was SVN commit r5322.
2007-09-03 23:31:34 +00:00
Matei 08d3ff2952 Updates for OS X and gcc 4.0 compatibility.
- Fixed some invalid member function references in wxJS code that gcc
4.0 didn't like.
- Some conversion changes.
- Don't try to construct wxSound from memory in OS X (it's not
available).
- Added dependency on zlib in AtlasUI (something there uses _compress).
- Added Mac code for finding current executable's path.
- Added dummy code for getting display size that does not use X.
- Fixed dir_get_changed_file stub to return ERR::AGAIN (end of files)
instead of INFO::OK.

This was SVN commit r5312.
2007-09-02 16:50:20 +00:00
Matei b65d1f8756 Replaced wxWidgets-devel with wxWidgets, which works better.
This was SVN commit r5311.
2007-08-30 17:52:57 +00:00
Matei 5e39585359 Added Mac build instructions using MacPorts.
This was SVN commit r5310.
2007-08-29 07:45:55 +00:00
Matei 02bcdb5407 # Added field foundation object.
This was SVN commit r5263.
2007-07-18 02:54:08 +00:00
Matei 7db64106a9 Fixed a connection issue: Before, connect was always called in non-blocking mode on Windows, because there was a pending WSAAsyncSelect on the socket so it was never proplerly set into blocking mode..
This was SVN commit r5237.
2007-07-09 05:10:02 +00:00
Matei e62da22784 Sort maps ignoring case.
This was SVN commit r5236.
2007-07-09 04:07:57 +00:00
Matei 3f90bae87a Improved default action selection when a group of units is chosen.
This was SVN commit r5235.
2007-07-09 03:35:01 +00:00
Matei bb517e3daf # Enhanced unit movement smoothness and multiplayer speed.
- Decreased MP turn length to 150 ms.
- Let units move along multiple steps of a path per turn. This means
they no longer "hesitate" between tiles. Especially noticeable in MP
games or at low framerates.
- Joined segments of paths generated by the pathfinder into linear
pieces for better repathing.

This was SVN commit r5224.
2007-07-05 07:33:43 +00:00
Matei 08862db42c # Fixes to Latium random map.
- Replaced calls to Math.max with own function because Math.max wasn't
working properly in latest Spidermonkey (?).
- Fixed some code that could cause weird ridges to appear.

This was SVN commit r5221.
2007-07-04 22:42:53 +00:00
Matei d9702ca590 Added dependency on comsuppw to fix VC2005 build.
This was SVN commit r5216.
2007-06-30 16:45:24 +00:00
Matei 8d323b0675 Fixed crash when exiting Atlas due to adding the same image list as both NORMAL and SMALL.
This was SVN commit r5199.
2007-06-17 01:55:23 +00:00
Matei e6815a0599 Nicer look for the terrain list.
This was SVN commit r5197.
2007-06-17 01:38:37 +00:00
Matei 92578ae553 # Some initial work on networking, fixing session setup, game startup, and command queueing.
- Fixed outdated / buggy networking code in the GUI scripts.
- Finished the API to CNetClient so that it's possible to start a CGame
from it.
- Some enhancements for debugging networking: Enabled updates while the
game is minimized/out-of-focus if it's in a network session. Also
reduced the turn length to something slightly more manageable but still
unplayable (1 sec versus 3 sec).
- Fixed a bug where IssueCommand used to access the order it creates
after queueing it, which is bad if the order gets deleted while being
queued (e.g. in CNetClient).

This was SVN commit r5139.
2007-06-04 07:41:05 +00:00
Matei 2e5c530c03 Modified semantics of HEntity's validity check to count handles to units that are destroyed but not deleted as still valid handles. This fixes some previous code that assumed these semantics, such as code for dealing with exhausted gather targets. It looks like the meaning was changed long ago when the entity flags were added. Also added an IsAlive method in HEntity for the old check, in case any code needs to be switched over to that.
Also removed some debug output from entity_functions.js.

This was SVN commit r5074.
2007-05-16 06:58:49 +00:00
Matei a8f8c74ed2 Fixed Linux build (needed an include).
This was SVN commit r5026.
2007-05-04 06:21:21 +00:00
Matei c6649d4d19 Added #if OS_BSD around BSD-specific functions (bsd.cpp).
This was SVN commit r5003.
2007-04-28 16:36:54 +00:00
Matei cf21949640 Fixed a few issues for Linux build:
- Quick change of _mkdir into mkdir (really, this should be done with a
library function, which Jan is working on).
- Moved CJSComplex::GetScript() implementation into its .h file from its
.inl file to avoid some link errors in release build due to inlining.

This was SVN commit r4994.
2007-04-25 03:10:56 +00:00
Matei e8071fa058 Added fancywater line in config file (but it's false).
This was SVN commit r4990.
2007-04-24 16:29:38 +00:00
Matei b631b9bbf0 Made the default map be latium_generated, for tutorial.
This was SVN commit r4988.
2007-04-24 15:02:51 +00:00
Matei 665030adcf Fixed some CStrW's in Technology.cpp for Linux compile.
This was SVN commit r4986.
2007-04-23 03:47:33 +00:00
Matei 1fea26a0e9 # Update to technologies.
Made CTechnology inherit from CJSComplex, so that properties such as
resources can be added dynamically instead of being hardcoded in it.

Also removed some excessive debug output from GUI.

This was SVN commit r4980.
2007-04-22 01:09:50 +00:00
Matei faf8358b3c # Bug fixes
This was SVN commit r4956.
2007-03-16 02:57:51 +00:00
Matei b18f582d3e Small tweaks to cinematic map.
This was SVN commit r4900.
2007-02-11 06:17:01 +00:00
Matei 925914f686 # Updates to cinematic map.
This was SVN commit r4891.
2007-02-10 18:59:52 +00:00
Matei 41bec4a181 Small cosmetic tweaks to cinematic map.
This was SVN commit r4888.
2007-02-10 18:12:05 +00:00
Matei e1ea1d23de # Animation bug fixes.
- Projectile speed and gravity adjusted to get nicer curves.
- Dying units conform to terrain.
- Cavalry melee attack range increased.

This was SVN commit r4887.
2007-02-10 17:39:20 +00:00
Matei 9e3b554f63 Increased projectile speeds.
This was SVN commit r4883.
2007-02-10 06:01:53 +00:00
Matei a11c12f848 # Fixed a bug with entities disappearing when they die.
This was SVN commit r4873.
2007-02-08 05:38:53 +00:00
Matei 5ca1c8243b Added a damage function to quasientities.
This was SVN commit r4861.
2007-02-05 02:42:24 +00:00
Matei 27e48abb35 Made bushes last slightly longer for cinematic.. though really the units should begin auto-gathering other bushes.
This was SVN commit r4833.
2007-02-02 14:58:19 +00:00
Matei 892fb6ce9e # Fixed some script bugs.
- Loot script was not properly giving loot.
- Some errors were occuring in the GUI every frame when XML files are
lacking certain traits.
- Fixed time on celt female citizen forage gather animation.

This was SVN commit r4832.
2007-02-02 14:53:16 +00:00
Matei 1e195ac519 Changed task unit triggers to use unit ID's properly.
This was SVN commit r4823.
2007-01-30 03:50:28 +00:00
Matei 465c0a037b # Fixed some trigger bugs.
- Conditions were not properly converted to JavaScript (not read from
the XML file correctly either).
- Added an OrderFromTriggers function so that triggers can give orders
which ignore fog of war.
- Fixed some spelling mistakes in TriggerSpecs.xml (parameter vs.
parameters).
- Moved trigger update to CSimulation update, which is more correct.

This was SVN commit r4821.
2007-01-29 22:21:25 +00:00
Matei 5e7baf3a43 # Bug fixes and cleanup of entity kill code.
Put all entity cleanup code in kill(), so the JS function Kill() can
just call kill(), and made the code more correct in both cases. Also
fixed a bug with auras (a unit kept around auras that had been deleted).
Also fixed up some notifier code that was causing crashes (although that
can still happen in some cases).

Fixes #176.

This was SVN commit r4810.
2007-01-25 07:00:31 +00:00
Matei 2c3c1be393 Fixed a bug with units not dying during playtesting in the scenario editor.
This was SVN commit r4801.
2007-01-20 18:35:02 +00:00
Matei 77f9d23d0f Added m_SoundGroupTable in CEntityTemplate to allow the soundgroup file for each animation to be specified in XML.
This was SVN commit r4769.
2007-01-13 20:14:03 +00:00
Matei e505843bb6 Added some example sound definitions in template_unit_infantry.
This was SVN commit r4768.
2007-01-13 20:13:05 +00:00
Matei 2390a122fe Forgot to save some files last time..
This was SVN commit r4767.
2007-01-13 18:45:09 +00:00
Matei d5e5bb5e09 # Updates to the combat damage system.
This was SVN commit r4766.
2007-01-13 18:41:24 +00:00
Matei 91db07faa2 Handle armour differently: Instead of having a value and percents for each type, just have a different value for each type. This makes it easier to upgrade *one* type of armour at once.
This was SVN commit r4758.
2007-01-12 16:18:20 +00:00
Matei 3c8dd6869c Fixed an upgrade bug.
This was SVN commit r4743.
2007-01-06 05:10:48 +00:00