Commit Graph

176 Commits

Author SHA1 Message Date
Torbjörn Andersson
ad8a71783a This is an attempt to fix the actor frames in IHNM. It appears to be at
least partially successful.

svn-id: r19025
2005-10-11 18:11:58 +00:00
Torbjörn Andersson
e44213c832 Cleanups. Mostly whitespace.
svn-id: r19022
2005-10-11 17:39:31 +00:00
Eugene Sandulenko
54449c920b Fix portrait color. I just missed dependency from barometer.
svn-id: r19009
2005-10-11 01:00:56 +00:00
Eugene Sandulenko
6cd35f7507 Now load actors only on demand. That lets select Nimdok (doctor) part. Just
click on him and move mouse away quickly, so it will not try to get actor's
name which is broken ATM.

svn-id: r18984
2005-10-09 01:43:08 +00:00
Eugene Sandulenko
176f32bfa1 _vm->getSceneHeight() --> _vm->_scene->getHeight() and make it return different
scene height for individual panel modes.

svn-id: r18959
2005-10-08 15:20:11 +00:00
Eugene Sandulenko
fe48a00517 Draw acrtors (eriktorbjorn, rejoice).
It:
 o breaks intro, as now everything seems to be shifted.
 o Shows problem at our firt scene where there is no inventory drawn
 o Shows problem with our animation code, actor frames are wrong
 o Draws actors upside down and probably at wrong location
 o Due to incomplete implementation of whichObject() it crashes when
   you hover over characters.

svn-id: r18952
2005-10-07 05:31:13 +00:00
Eugene Sandulenko
62a9b56577 IHNM changes:
o Latest bit of Game Object structure
  o Implemented spiritual barometer
  o Fixed Ethics points data type
  o Implemented sf74 and sf104

svn-id: r18933
2005-10-04 23:38:19 +00:00
Torbjörn Andersson
0719a4e6c2 I misunderstood sev on how sf75() should work. Perhaps this is better?
svn-id: r18932
2005-10-04 18:19:14 +00:00
Torbjörn Andersson
ba306c80f4 Unstubbed sf75() as sfSetPortraitBgColor(), using information from sev. Any
mistake is strictly my own, however.

svn-id: r18931
2005-10-04 17:44:41 +00:00
Torbjörn Andersson
4823f41b15 Experimental IHNM fix: Since it looks like the intro doesn't clear the
cutaway explicitly, perhaps it's done implicitly by sfScriptGotoScene
instead?

svn-id: r18927
2005-10-03 10:01:09 +00:00
Eugene Sandulenko
36f77ad3f9 Fix fonts in intro. It is a very dirty code. Actually we should specify
font Ids in game settings. Also uhnm demo will definitely not work with current
code as it has lesser number of fonts.

svn-id: r18900
2005-09-29 15:57:41 +00:00
Eugene Sandulenko
a7ec941d30 Remov obsolete comment
svn-id: r18899
2005-09-29 15:35:30 +00:00
Eugene Sandulenko
fde99a029a Cleaner code for sfWaitFramesEsc()
svn-id: r18895
2005-09-28 15:49:20 +00:00
Eugene Sandulenko
05ccf63898 Implement sfWaitFramesEsc()
svn-id: r18894
2005-09-28 15:41:21 +00:00
Torbjörn Andersson
1a48b01fef Some more IHNM-related stuff:
* Use the script-specified text area for subtitles, if there is one.

* Fixed a word-wrapping bug that would happen if a new line began with a
  space. I don't know about ITE, but IHNM puts two spaces after periods. Of
  course, the case where I saw this happen will probably go away once we
  start using the right font, but it could still happen elsewhere.

svn-id: r18890
2005-09-28 06:33:13 +00:00
Torbjörn Andersson
3e99ea96a3 Implemented some trivial IHNM opcodes. I'm not sure if the _ethicsPoints[]
array is large enough though.

These opcodes modify what I assume to be the game state, so that
information needs to be stored in the savegames. Not for ITE, though, so
savegame compatibility is not broken by this. (Not deliberately, at least.)

svn-id: r18885
2005-09-26 07:22:32 +00:00
Eugene Sandulenko
d795b8a714 Give more names to IHNM script functions.
svn-id: r18879
2005-09-25 00:08:13 +00:00
Torbjörn Andersson
898ddaf04b The IHNM intro animations run now, albeit in a slightly buggy fashion:
The intro runs a whole series of animations. Each of these use animation
slot 0, like the original. Currently this means we leak a bit of memory for
each new animation.

More noticeably, we have no way of cancelling outstanding animation events,
so unless the animations finish on their own - as some of them do - the
events will just pile up, causing the animations to run faster and faster.

I don't know if implementing the remaining cutaway opcodes will fix this
automagically, or if we need to re-think our approach...

svn-id: r18878
2005-09-24 19:29:55 +00:00
Torbjörn Andersson
ee4b2ccb02 Some more preliminary cutaway work. The backgrounds are displayed now, but
not the animations themselves. Still, it's enough to make the IHNM intro
look fairly interesting.

svn-id: r18874
2005-09-24 10:13:17 +00:00
Torbjörn Andersson
d18ce8e2f0 Whitespace
svn-id: r18854
2005-09-21 10:44:22 +00:00
Torbjörn Andersson
df7f81c905 The intro asks to play song number 0. I'm almost sure that the music that
is supposed to play at this point has resource number 32. _songTable[0]
contains the value 32 at this point, so song 0 is probably a valid music
request, and not a request to stop the music.

At the other end of the list, I believe the song number has to be *less*
than _songTableLen, not less or equal to it.

But feel free to revert this change if I'm messing things up.

svn-id: r18719
2005-08-30 12:25:15 +00:00
Eugene Sandulenko
349ab2007a Implement sfPlayMusic for IHNM
svn-id: r18717
2005-08-30 11:16:11 +00:00
Torbjörn Andersson
d8a96c3032 Allowed IHNM to use the opSpeak opcode. Aborting that code path early meant
that the instruction wasn't fully read, so the next opcode would be wrong.
This is what caused it to crash.

To keep the game from hanging, I also allowed the engine to call the
_actors->direct() function for IHNM. This allows AM's intro speech to be
played in its entirety.

Since this includes the "hate" speech, I've removed that part from the
hard-coded intro. To get the right music playing, I've enabled the
sfPlayMusic() function for IHNM. This is pure guesswork, though. Once the
scene changes, the wrong music plays again. However, this is scene music,
i.e. not scripted.

It doesn't play the background sound. Looks like _fxTable[] isn't generated
for IHNM. More noticeably, until the scene changes it doesn't show any
graphics apart from the subtitles, which are drawn in the wrong colour and
(I believe) the wrong font.

svn-id: r18712
2005-08-26 12:07:31 +00:00
Andrew Kurushin
968e73a93a fix 1258781 & 1253993 bugs
(difficulties of leaving scenes)

svn-id: r18698
2005-08-16 17:59:49 +00:00
Eugene Sandulenko
2230d4b037 More debug output for IHNM
svn-id: r18656
2005-08-11 14:00:26 +00:00
Eugene Sandulenko
da25b8fd4f Improved debug output on stub script functions.
Impelmented sfSetSpeechBox, though it is not yet functional.

svn-id: r18651
2005-08-10 17:39:29 +00:00
Eugene Sandulenko
4e4c1f5b73 Rename event types to comply with our standards.
svn-id: r18647
2005-08-10 15:31:15 +00:00
Eugene Sandulenko
37f2a10ef6 Rename Actor class members to _members.
svn-id: r18645
2005-08-10 14:53:17 +00:00
Eugene Sandulenko
00d676c3d2 EVENT -> Event
svn-id: r18644
2005-08-10 14:11:22 +00:00
Eugene Sandulenko
215a94ae30 WIP on metaResources. Most resources are load. Now we start correct
scene. But there are following problems:

  o Inclomplete support for actors speech, so opSpeak is skipped
  o For some weird reason actors do not appear at all. Actually code seems to
    be trying to read only protagonist frames
  o It crashes on reading sprites due to wrong input

svn-id: r18624
2005-08-07 00:00:43 +00:00
Eugene Sandulenko
ec4f7d3d7c Whitespaces
svn-id: r18595
2005-07-29 17:58:00 +00:00
Eugene Sandulenko
1a1db4611a Show scene substitute image for demo versions of ITE.
svn-id: r18589
2005-07-29 16:37:06 +00:00
Eugene Sandulenko
e8c1f6d1f1 More IHNM differences
svn-id: r18582
2005-07-25 02:38:43 +00:00
Andrew Kurushin
fbc04b1ac7 assign sf94 name
svn-id: r18579
2005-07-24 13:41:49 +00:00
Eugene Sandulenko
a641c3add7 More IHNM differences
svn-id: r18574
2005-07-21 22:13:06 +00:00
Eugene Sandulenko
6c9f6e8def Partially implemented differences in IHNM script functions.
svn-id: r18573
2005-07-21 01:33:28 +00:00
Andrew Kurushin
50c2d8954d finally Resource manager rewritten:
-adds patch file support
-global _vm removed

cleanups

svn-id: r18560
2005-07-19 19:05:52 +00:00
Torbjörn Andersson
51e76c703f Added the puzzle voices from the CD version. I don't know if this breaks
the floppy version, and it's still not flawless. But it's a start.

svn-id: r18544
2005-07-15 15:23:19 +00:00
Andrew Kurushin
528eedb2de font & text related changes:
-rewritten font loading
-actors box text output implemented
-many fixes
-implemented nonactors textoutput

svn-id: r18542
2005-07-14 17:46:21 +00:00
Andrew Kurushin
c2f1691bad gfx rearangement
code cleanups

svn-id: r18523
2005-07-09 16:23:45 +00:00
Andrew Kurushin
866d3e3db3 remove 1pixel dos clipping
svn-id: r18521
2005-07-09 10:34:09 +00:00
Andrew Kurushin
d944bd7793 implemented per scene actors clipping
so last sequence should look much better (not perfect)

svn-id: r18516
2005-07-08 16:56:03 +00:00
Torbjörn Andersson
e25587d74b Fixed stopping sounds. I think that at one point our 'param' used to be
unsigned, but it isn't any more.

svn-id: r18504
2005-07-06 17:55:53 +00:00
Eugene Sandulenko
57858a8757 Hid most of debug output to deeper levels. We're pretty close to official
launch so it should be invisible to users.

svn-id: r18497
2005-07-05 16:58:36 +00:00
Eugene Sandulenko
de14b2337f Implementation of sfShowMap. This was latest unimplemented script function :)
svn-id: r18487
2005-07-03 20:02:56 +00:00
Andrew Kurushin
13b1802a45 implemented sfPickClimbOutPos, sfTossRif
Komodo dragon now works

svn-id: r18480
2005-07-01 17:29:23 +00:00
Andrew Kurushin
353e8586d4 fix animation timings (now Shiala scene not stucks)
svn-id: r18463
2005-06-25 15:55:43 +00:00
Eugene Sandulenko
75d868743c sfShowControls implementation is NOP
svn-id: r18417
2005-06-20 12:17:22 +00:00
Eugene Sandulenko
ecf8da7230 Implement sfPlayLoopedSound, sfFadeMusic and sfPlayVoice.
sfPlayVoice is untested. Please, inform me where you encounter it.

svn-id: r18412
2005-06-19 21:18:00 +00:00
Andrew Kurushin
97337c4623 implemented sfGetNumber
now use MagicHat (be carefull not to exceed overall scene number)

svn-id: r18410
2005-06-19 14:06:20 +00:00