<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://temp.ufopaedia.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Epiceuropean</id>
	<title>UFOpaedia - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://temp.ufopaedia.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Epiceuropean"/>
	<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/Special:Contributions/Epiceuropean"/>
	<updated>2026-05-01T08:35:33Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=User_talk:Seb76&amp;diff=26902</id>
		<title>User talk:Seb76</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=User_talk:Seb76&amp;diff=26902"/>
		<updated>2010-01-12T05:26:02Z</updated>

		<summary type="html">&lt;p&gt;Epiceuropean: /* New and Outstanding Requests */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hey, sorry to pester you again. :) I&#039;ve gotten access to IDA, as you suggested, and with it I&#039;m making some slow progress toward my mod. I wanted to ask, though, do you know of any sort of tutorial or useful intro for it? The user interface is pretty obtuse, the built-in help has nothing useful, and I&#039;ve been struggling just to make comments go where I want them to.&lt;br /&gt;
&lt;br /&gt;
(I mean, I understand that it&#039;s meant for very advanced users, but Jesus, who writes an enterprise-grade utility and doesn&#039;t bother to implement an Undo function?!?)&lt;br /&gt;
&lt;br /&gt;
Thanks again for your help! [[User:Phasma Felis|Phasma Felis]] 23:15, 16 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Okay, a little more progress since I discovered anterior comments. Couple of more specific questions: what&#039;s the difference between a &amp;quot;comment&amp;quot; and a &amp;quot;repeatable comment&amp;quot;? Or any of the several other types of comments, for that matter.&lt;br /&gt;
&lt;br /&gt;
What exactly does &amp;quot;mov cs:word_102F9, ax&amp;quot; do? At first I thought it was just copying the accumulator into the data word at 02F9, but the &amp;quot;cs:&amp;quot; part is confusing. word_102F9 is 0, I think (&amp;quot;seg000:02F9 word_102F9 dw 0&amp;quot;). Does that mean it&#039;s copying AX into the current code segment, offset 0, modifying the code in progress? That seems odd.&lt;br /&gt;
&lt;br /&gt;
Okay, one more and then I&#039;ll go to bed: what does &amp;quot;jmp short $+2&amp;quot; do? It looks like it just means &amp;quot;jump to next instruction&amp;quot;, which is kinda redundant, but it could be &amp;quot;jump &#039;&#039;over&#039;&#039; next instruction&amp;quot;, which...still seems unnecessarily verbose. I dunno. [[User:Phasma Felis|Phasma Felis]] 00:51, 17 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: The last two questions are actually general Intel 16-bit assembly ;)&lt;br /&gt;
&lt;br /&gt;
: The cs in &amp;quot;mov cs:word_102F9, ax&amp;quot; is the 16-bit code segment base, yes.  It *might* be self-modifying code, but more likely there is a C global or static variable that was implemented there and being updated.  The &amp;quot;seg000:02F9 word_102F9 dw 0&amp;quot; is probably from C default initialization, but could be from an explicit initialization to 0.&lt;br /&gt;
::Back in the 16bit days, there were several memory models. My knowledge on this is quite rusty, but IIRC COM executables were using the &amp;quot;tiny&amp;quot; one which means that the code and data use the same segment (I assume you&#039;re working on the music TSR?). Modification of data via the CS segment is not necessarily self-modifying code. Also TSRs were usually signaled using software interruptions so the code most likely sets up an interrupt vector and bails out. e.g.:&lt;br /&gt;
 seg000:0140 mov     dx, 157h&lt;br /&gt;
 seg000:0143 push    ds&lt;br /&gt;
 seg000:0144 push    cs&lt;br /&gt;
 seg000:0145 pop     ds&lt;br /&gt;
 seg000:0146 mov     ax, 2566h&lt;br /&gt;
 seg000:0149 int     21h                             ; DOS - SET INTERRUPT VECTOR&lt;br /&gt;
 seg000:0149                                         ; AL = interrupt number&lt;br /&gt;
 seg000:0149                                         ; DS:DX = new vector to be used for specified interrupt&lt;br /&gt;
 seg000:014B pop     ds&lt;br /&gt;
 seg000:014C call    sub_1067A&lt;br /&gt;
 seg000:014F mov     dx, ax&lt;br /&gt;
 seg000:0151 mov     ax, 3100h&lt;br /&gt;
 seg000:0154 int     21h                             ; DOS - DOS 2+ - TERMINATE BUT STAY RESIDENT&lt;br /&gt;
 seg000:0154 start endp                              ; AL = exit code, DX = program size, in paragraphs&lt;br /&gt;
&lt;br /&gt;
::In this example (from music.com), there is code at 157h but IDA does not detect it. You can get there, type &#039;C&#039; and create a new function. The code there is the most important. HTH [[User:Seb76|Seb76]] 12:10, 17 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
::: There were at least six common memory models.  *.COM not only assumed a single code and single data segment, it assumed their base addresses were the same.  You get four more (with one segment of static data) by 1 or more than 1 of each of code and data segments [near and far pointer distinctions].  The last allowed more than 64K of static data.&lt;br /&gt;
&lt;br /&gt;
::: XCOM most likely used one of the double-far memory models.  -- [[User:Zaimoni|Zaimoni]], 9:31 Jun 19 2008 CDT&lt;br /&gt;
&lt;br /&gt;
: &amp;quot;jmp short $+2&amp;quot; is jump over the next instruction, if the next instruction is 2 bytes.  This probably came from an if-then-else in C (it&#039;s a common idiom in translating C to assembly).  -- [[User:Zaimoni|Zaimoni]], 12:36 Jun 17 2008 CDT&lt;br /&gt;
&lt;br /&gt;
:: I can see several instances of this in music.com for simple &amp;quot;return value&amp;quot; functions. Most likely a &amp;quot;feature&amp;quot; of the compiler. If used for padding, it is equivalent to 2 nop instructions, but takes only one cycle to execute. This was before deeply pipelined processors though ;-) [[User:Seb76|Seb76]] 12:10, 17 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
Yeah, I sidelined off IDA onto general assembly there :) Probably a good thing, means I&#039;m getting used to it. Sort of.&lt;br /&gt;
&lt;br /&gt;
(Holy crap. I just discovered that hitting &amp;quot;P&amp;quot; (Create Function) in the right place is all it takes to enable graph display mode and give me a vast, improbably pretty flowchart of, well, a lot of stuff. I&#039;d been wondering how to make that work.)&lt;br /&gt;
&lt;br /&gt;
Anyway! Seb, you&#039;re correct, I&#039;m working on the music TSR. I&#039;ve pretty much figured out how the entry code works, setting up an interrupt vector and terminating, which I think is decent progress for three days&#039; experience with x86 assembler. I did find a web reference to &amp;quot;jmp short $+2&amp;quot; [http://www.programmersheaven.com/mb/x86_asm/484/484/ReadMessage.aspx here], which suggests that it&#039;s &amp;quot;used to clear the cache, before going in or out of protected mode&amp;quot;. Not entirely sure what clearing the cache does, but it&#039;s good to know.&lt;br /&gt;
&lt;br /&gt;
Thanks to the both of you for your help. Seb, do you mind if I continue to ask questions here? I don&#039;t know where else it should go. Maybe we need a &amp;quot;ridiculous hacking ideas&amp;quot; section of the wiki... ;) [[User:Phasma Felis|Phasma Felis]] 01:10, 18 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Hehe, sounds like fun. When I can find time to write a dll injector, I may add some stuff to it ;-) I&#039;d start with increasing the max number of smoke entries. (Not possible right off the bat because it&#039;s using a static array instead of malloc-ed data :( ). Other ideas: fix the proxmine bugs, or maybe the disjoint base bug. I found the piece of code and it is not a simple &amp;quot;off by one&amp;quot; issue so it cannot just be patched in place... [[User:Seb76|Seb76]] 12:22, 18 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
::Yeah, there&#039;s a lot of bugs and odd behaviors that could be fixed by just using larger arrays somehow. The 80-item limit causes all sorts of problems, the smoke limit, the 20-armed-proxmine limit...I wouldn&#039;t mind having more than 8 bases in the late game...stuff like that. [[User:Phasma Felis|Phasma Felis]] 12:42, 18 June 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Hmm. The loader thing looks wonderful, but as I&#039;m using a dos version in dosbox I&#039;m guessing I&#039;m out of luck for now? Or are you a dos wizard as well? :)&lt;br /&gt;
[[User:Knan|Knan]] 12:35, 9 July 2008 (PDT)&lt;br /&gt;
:Using a loader coupled with dll injection, there is no limit to the size of what you want to patch. You can also use higher level languages instead of plain assembler. However it is windows specific (won&#039;t work on anything pre-XP because of CreateRemoteThread usage BTW). For CD music in DOS, [[User:Phasma Felis|Phasma Felis]] may be your ticket. I&#039;m willing to help but as I said before, my knowledge of DOS is quite rusty. [[User:Seb76|Seb76]] 12:49, 9 July 2008 (PDT)&lt;br /&gt;
::It&#039;s really the equipment screen hack that looks compelling. Figure it might be unreasonably hard to do that in dos. But I can&#039;t seem to get the windows version to run at a reasonable speed these days, always far too fast. That&#039;s why I&#039;m using dosbox. Ah well, have fun modding :) [[User:Knan|Knan]] 14:14, 9 July 2008 (PDT)&lt;br /&gt;
:Well, actually I have the speed issue too. It&#039;s just that setting the laptop to max battery and scroll speed to one is enough to work around the problem ^^. The geoscape has a sleep routine to prevent too fast updates. The mecanism is not present in the tactical part. [[User:Seb76|Seb76]] 14:45, 9 July 2008 (PDT)&lt;br /&gt;
:Edit: might be your lucky day. I made a modification, it should slow down the scroll now. Can you check? [[User:Seb76|Seb76]] 15:42, 9 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Seb76, since you appear to be on a roll with the findings lately, I thought I&#039;d mention this as something to look out for if you haven&#039;t already found it. Can you track down the tables that determine a few other object properties that aren&#039;t stored in obdata.dat? I mean for properties like if it can cast light, what bullet image to use if the object is fired, whether its melee attack/mind probe/psi attacks are available for that item, etc. This would certainly allow for much more robust equipment modding. I&#039;m guessing it&#039;ll be a part of the tactical.exe portion of the game. - [[User:NKF|NKF]] 19:56, 11 July 2008 (PDT)&lt;br /&gt;
:Only flares can cast light currently. It is not a property in obdata, but a hardcoded &amp;quot;objectType=0x1B&amp;quot; check. I can hack in a piece of code to enable light for some other object types, but we&#039;ll need a way to say which ones do (can be done in the ini file but it would not be clean. Maybe we can find an unused bit in obdata.dat and arrange that...). [[User:Seb76|Seb76]] 14:12, 12 July 2008 (PDT)&lt;br /&gt;
:Edit: the routine that populates the item menu has everything almost hardcoded too: stun, mind probe, psi-amp actions, scanner and medkit are all hardcoded by object type. The rest uses known flags from obdata. [[User:Seb76|Seb76]] 15:18, 12 July 2008 (PDT)&lt;br /&gt;
:Edit2: playing with the heavy laser mod, I found the data for bullet image/sound. It is located at offset 0x6D1F8. Each entry is organized like that:&lt;br /&gt;
 struct {&lt;br /&gt;
 	short bulletVisual;&lt;br /&gt;
 	short shootSound;&lt;br /&gt;
 	short impactSound; &lt;br /&gt;
 	short impactAnimation;&lt;br /&gt;
 }&lt;br /&gt;
Entries are sorted per [[OBDATA.DAT]] ID (i.e. the first entry is for pistol, the 0x12th for heavy laser, etc.) [[User:Seb76|Seb76]] 15:31, 2 August 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: Ah, that&#039;ll help with some modding. Although I just remembered something that I was going to ask at the time - but completely forgot about. What controls how the weapon is displayed while in the soldier&#039;s hands? I mean, the pistols are displayed with the weapon extended in the firing position while most other weapons are held across in both hands (mimicking one/two handed items). Would this be hard coded as well in addition to the unique item actions? -[[User:NKF|NKF]] 17:43, 2 August 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
== Error running UFOExtender ==&lt;br /&gt;
&lt;br /&gt;
Hi Seb76.  I&#039;ve tried running your UFOExtender as I want to slow down the scrolling in the tactical view.  However I get the following error message:&lt;br /&gt;
&lt;br /&gt;
 C:\Games\X-com\UFO Defense\UFOLoader.exe&lt;br /&gt;
 This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem.&lt;br /&gt;
&lt;br /&gt;
Any ideas what&#039;s going wrong?  I&#039;m on Win XP running Collector&#039;s Edition of UFO. --[[User:Col w|col_w]] 05:34, 12 July 2008 (PDT)&lt;br /&gt;
:Hum, looks like the error you get when there is a missing DLL. I compiled using Visual Studio 9.0 Express Edition, maybe you don&#039;t have the runtime installed? You can get it [http://www.microsoft.com/downloads/details.aspx?FamilyID=9B2DA534-3E03-4391-8A4D-074B9F2BC1BF&amp;amp;displaylang=en here]. Tools like [http://www.dependencywalker.com/ dependency walker] can help identify missing DLLs. Also what OS are you using (service pack number)? I don&#039;t have Vista here to test so it may only be running in XP SP2. Anybody can report it running on Vista? For sure it won&#039;t work on Win9x. [[User:Seb76|Seb76]] 09:02, 12 July 2008 (PDT)&lt;br /&gt;
::Yeah, visual xyz runtime dlls need to be included with things you compile with visual xyz. A common complaint when running small hacks under Wine on Linux as well, since you usually install just a very few programs on each virtual windows install, so it&#039;s unlikely some other program installs the dlls for you. [[User:Knan|Knan]] 17:08, 12 July 2008 (PDT)&lt;br /&gt;
:Especially since they made up that manifest stuff. Supposed to solved DLL hell... Well, so far it caused me more trouble than it solved issues. The funny part is when you install a new VS service pack on your build servers and have half the development team freak out because their target system won&#039;t boot the latest piece of code... [[User:Seb76|Seb76]] 18:04, 12 July 2008 (PDT)&lt;br /&gt;
Awesome, that fixed it! Now I can enjoy this classic game once again.  Love the language screen joke too :)  Many thanks --[[User:Col w|col_w]] 11:08, 12 July 2008 (PDT)&lt;br /&gt;
:My pleasure man. Glad you enjoyed it ;-) [[User:Seb76|Seb76]] 12:07, 12 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
My problem is the following: if I try to run the loader normally, a console window pops up for a few seconds then I get an &amp;quot;illegal instruction&amp;quot; error from NTVDM (and the window disappears, yet it&#039;s button remains on the taskbar until I kill the process). If I try to run it with DosBox however, I get &amp;quot;illegal command: UFOLOADER.EXE&amp;quot;. Point is, I can&#039;t run this at all.--[[User:Amitakartok|amitakartok]] 11:27, 13 October 2009 (EDT)&lt;br /&gt;
:Looks like you&#039;re trying to use the DOS version here. Only the CE (windows) version is supported. [[User:Seb76|Seb76]] 13:48, 13 October 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== UFOloader and Xcomutil ==&lt;br /&gt;
&lt;br /&gt;
Hey Seb76 awesome work with this patch! Just wondering though if it would be possible to run this together with XcomUtil somehow. Thanks!&lt;br /&gt;
Oh and btw when&#039;s the TFTD version coming out? ;-)&lt;br /&gt;
[[User:J&#039;ordos|J&amp;amp;#39;ordos]] 14:09, 24 July 2008 (PDT)&lt;br /&gt;
:You can try this version: [[Image:UFOExtender-dev.zip ]]. I did not really have time to test it. Use the modified batch and keep me posted ;-) You&#039;ll get a crash if you activate the patch to disable the introduction movie. I checked the equipment screen patches, they were OK. TFTD will wait till I&#039;m satisfied with the XCOM version. Anyway, I&#039;m not in a disassembling frenzy right now :p [[User:Seb76|Seb76]] 15:29, 24 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Hey fast response, thanks! I tried the new version but unless I&#039;m missing something I&#039;ve been unable to get it to include f0dder&#039;s bugfix loaders. I edited the ini file&#039;s Executable= to &#039;xcloader.exe&#039;, xcomutil&#039;s included bugfix loader, and when I run UFOloader.exe directly it works fine, but when using your modified runxcomW.bat it seems to be disregarded. This was not the case with your previous version. (I actually thought of modifying runxcomW.bat like that :-) ) Can&#039;t seem to find any reason for it in runxcomW.bat.&lt;br /&gt;
:The only modification I did to this version is forward the parameters passed to the loader to the XCOM executable (geoscape is passed an argument which tells it if it needs to start from scratch, or use the data from the missdat folder). Also it cannot work with f0dder&#039;s patch the way you tried: doing so, you are patching the xcloader binary itself, which obviously is not what you want.&lt;br /&gt;
:Edit: I added a &amp;quot;Video Pitch&amp;quot; bug fix to compensate for the incompatibility of the 2 loaders ;)&lt;br /&gt;
:: also a minor note, but on a fresh xcom install the console echoes a read error on MISSDAT\saveinfo.dat (I assume this is the work of xcomutil) and minimizes Xcom to the tray. It still works fine though.&lt;br /&gt;
:: while on the subject of minor notes the &#039;Rank In Inventory=&#039; in your ini file actually has the letter O instead of the number 0 by default ;-)&lt;br /&gt;
:Hm, I guess that&#039;s what you get when experimenting stuff at 1:00 am ;-) (GMT+2 here)&lt;br /&gt;
:: edit: I decided to do some testing first by manually disabling directdraw to circumvent the bugfix loader problem. Unfortunately the game crashes as soon as I enter tactical combat (when it should go to the equipment screen) even when all features are disabled. But unless I delete the MISSDAT folder&#039;s contents the next time I run runxcomW.bat I can hear the battlescape music playing. Unfortunately the batch file seems to get stuck in an infinite loop or something as it just keeps starting xcom over and over until it finally kills my system! :-) (all my base really belong to you ;-) )&lt;br /&gt;
:I start the runxcomw.bat batch from a shell and I have to do a &amp;quot;ctrl-C&amp;quot; between phases . Maybe it is because I replied yes to &amp;quot;Do you want to see XcomUtil messages after combat?&amp;quot; &lt;br /&gt;
:: using the previous version I can enter battles just fine, but none of the UFOloader features work.&lt;br /&gt;
:Did you try disabling every XComUtil features? I don&#039;t know how extensively it modifies the main executable. Here it works with the following config: replied &amp;quot;no&amp;quot; to everything while installing XComUtil (so that only executable splitting is done), enabling only equipment screen patches with my loader, and starting via the attached batch file. I can start a new game, down a UFO, go into tactical mode and go back to the geoscape view after taking down all the aliens. Did you try renaming UFOLoader.exe into xcloader.exe? It might work [[User:Seb76|Seb76]] 12:21, 25 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Thanks for your efforts, but still no luck. I downloaded the new version and did a fresh install of xcom. Running the UFOloader without xcomutil works fine (with your directdraw patch I get a ~3sec pause everytime the game zooms in/out on an interception though, which does not occur with f0dder&#039;s patch). Running xcomutil without the UFOLoader also works fine (using ctrl+C). I then did another fresh install and put the both of &#039;em together. I enabled the equipment screen patch and the directdraw fix on UFOLoader and told xcomutil to use f0dder&#039;s loader, answering no to all other questions. Renamed UFOLoader.exe to xcloader.exe and started runxcomW.bat. The game crashed when it should go to the equipment screen. (no ctrl+C possible) Disabling the equipment screen patch and/or enabling xcomutil&#039;s messages after combat yielded the same result. :(&lt;br /&gt;
:About the 3sec pause, it may be related to the musicfix that f0dder&#039;s patch does: it runs the MCI commands in a separate thread to remove the pause due to synchronous calls (with the unpatched version, there is a &amp;quot;slight&amp;quot; pause (~0.5sec on my computer) each time the music changes). Do you have the same pause in the main menu? Also if you activate the PSX music patch (even with no CD in the tray), it should remove the pause (if it is indeed the same problem). For your crash, I haven&#039;t got a clue. Maybe it&#039;s time I release the source code so people with different configurations can try more stuff. I know there are imaginative people out there ;-) [[User:Seb76|Seb76]] 07:02, 27 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Ah that fixed the delays, thanks! Strangely the battlescape now works fine (using ctrl+C) as long as I don&#039;t enable the equipment patch with xcomutil... Don&#039;t know about the other fixes&amp;amp;flags. I&#039;ll do some more testing. [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 10:31, 27 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: edit: quick testing reveals that it actually crashes exactly 1 times in 2, apparently regardless of what fixes are on. (though I did not yet test any xcomutil features) I guess it&#039;s probably related to one of the MISSDAT files? [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 10:37, 27 July 2008 (PDT)&lt;br /&gt;
:: edit2: OK here&#039;s what I have so far: It crashes if the previous mission worked. It works if it crashed on the previous mission. If I delete the contents of the MISSDAT folder it always crashes until I do a mission without xcomutil and/or without the loader. After that the normal rules apply. (i.e. next mission I play with both xcomutil&amp;amp;the loader it&#039;ll crash, as the previous mission worked, but the next one will work again) very strange :s Note that I did not yet try to play out a full mission, I always aborted on the first turn. Hope you can narrow the problem down a bit this way :-) [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 10:50, 27 July 2008 (PDT)&lt;br /&gt;
:Can you give me the address of the error when it crashes? (accessible in the crash window dialog)[[User:Seb76|Seb76]] 11:29, 27 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: There is nothing when it crashes, not even the console remains. Unless you&#039;re talking about a log file?&lt;br /&gt;
:I was talking about the &amp;quot;a program has cause xxx to close unexpectedly&amp;quot; (or whatever it is in the US version) dialog box. This looks more like a silent crash (the worth case). I modified the loader and it looks better. I still have the &amp;quot;ctrl-C&amp;quot; issue however. [[User:Seb76|Seb76]] 12:38, 27 July 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;3 don&#039;t know what you did but the latest version works perfect! Just did 3 missions in a row, restarted xcom and did another 2 (only actually completed one of &#039;em tho :) ) without any crashes at all! *crosses fingers* I enabled all the settings I wanted in both xcomutil and the UFOLoader without problems. Thanks Seb, excellent work! ;-)&lt;br /&gt;
:: oh and the ctrl+C thing is a problem in the xcomutil batch file, it&#039;s not your program&#039;s fault. The Xcopy commands in the runxcomW.bat file are missing a /Y parameter. Here&#039;s a link to the xcomufo.com forum thread discussing it for anyone interested: [http://www.xcomufo.com/forums/index.php?showtopic=242025489]&lt;br /&gt;
:: Whew, was quite a ride... Now, where&#039;s my ammo clip fix? ^^&lt;br /&gt;
:Thanks for the feedback, it is good to know that it is possible to have this work with xcomutil. BTW, the fix I did in the test version is also in the latest package with the ammo clip hack ;-) [[User:Seb76|Seb76]] 16:16, 27 July 2008 (PDT)&lt;br /&gt;
:::After spending an hour with reading through this double discussion and trying to find the right batch file in the old archives and make the game work, I decided to put your &#039;&#039;&#039;Xcomutil + UFOloader solution&#039;&#039;&#039; here: [[Image:RunXcomW.zip]] with a simple explanation. Hope you don&#039;t mind.--[[User:Kyrub|Kyrub]] 15:43, 8 September 2008 (PDT)&lt;br /&gt;
::::Actually you don&#039;t need the modified runxcomw.bat file, the way I do it is I tell xcomutil to use f0dder&#039;s loaders and then I simply replace xcloader.exe (xcomutil&#039;s included f0dder patch) with UFOLoader.exe! [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 05:01, 9 September 2008 (PDT)&lt;br /&gt;
: Hey there, I&#039;ve read about this project and I&#039;m wondering if I can ran it with XComUtil but I play with the DOS versions (through DosBox) and thus use RunXCom. [[User:Hobbes|Hobbes]] 16:27, 13 September 2008 (PDT)&lt;br /&gt;
::Sorry there, this project uses modifications of the binary so it&#039;ll work only on the windows version. Why do you have to stick to the DOS version BTW? [[User:Seb76|Seb76]] 04:29, 14 September 2008 (PDT)&lt;br /&gt;
:::DOS version was the first I played and I prefer its sounds (specially the alien death cries). I also prefer the DOS bugs (some on CE are too annoying). Thanks anyway :) [[User:Hobbes|Hobbes]] 11:26, 14 September 2008 (PDT)&lt;br /&gt;
:::Hmm, something I remembered: IIRC, XComUtil splits the binary of CE into Tactical and Geoscape, in order for it to run with CE. I think I&#039;ll download your program and give it a try [[User:Hobbes|Hobbes]] 11:34, 14 September 2008 (PDT)&lt;br /&gt;
::::No success, doesn&#039;t surprise since I have the barest clue of what I should be doing. [[User:Hobbes|Hobbes]] 11:44, 14 September 2008 (PDT)&lt;br /&gt;
::There&#039;s no way it could work like that, windows binaries cannot run in DOS environment; split binaries or not. If you&#039;re pissed about a particular bug, just tell. I may be able to fix it ;-) Concerning the sounds, I don&#039;t know exactly what is the problem about CE version. If someone can give some details, I may have a look at that too. [[User:Seb76|Seb76]] 12:09, 14 September 2008 (PDT)&lt;br /&gt;
:Hey Seb is it possible the latest versions of your extender don&#039;t work with xcomutil anymore? Did you drop support? Love the new features but I rather miss xcomutil&#039;s automatic re-equipping :) [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 12:58, 26 April 2009 (EDT)&lt;br /&gt;
::Yeah, it is possible ^_^ But you now, it was never officially supported, it worked more or less by chance ;-) As I said on the forum, it might be possible the older version of the loader still works (you can use the old loader with a recent patcher DLL, it should be OK), but I got little feedback so I don&#039;t know if I&#039;m correct... [[User:Seb76|Seb76]] 16:13, 27 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Heavy Laser Mod ==&lt;br /&gt;
&lt;br /&gt;
Hey Seb, I&#039;ve been trying the new heavy laser. It&#039;s a cool idea, adds some new options during battle :) But I think currently the full auto option is overpowered. I hardly use the burst mode at all. I&#039;d suggest lowering the accuracy and/or (if possible) reducing the amount of shots fired? Currently when I see a single alien I use full auto (can&#039;t miss with 10 shots), when I see a terror unit I use full auto (2x2 + 10 shots = dead terror unit :) ), and when I see a group of aliens I also use full auto (10 shots &amp;gt; 5 shots). A few units still standing? Bring on the next heavy laser.&lt;br /&gt;
Also because these new fire modes don&#039;t mind line of fire restrictions cover won&#039;t help aliens at all (unless the cover is strong enough to withstand HL power). Just use full auto to blast through any house that&#039;s in the way and in most cases it&#039;ll still kill the alien as well. (do need to make sure no agents/civilians are standing in the line of fire though) &lt;br /&gt;
Should note that ATM I&#039;m still only dealing with sectoids and the occasional floater. Will let you know how it fares against the later races.&lt;br /&gt;
[[User:J&#039;ordos|J&amp;amp;#39;ordos]] 05:44, 31 August 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
OK, it&#039;s cool but it really is overpowered. Accuracy must be lower in Auto modes than in Snap, that&#039;s basic in the game. If you assume the Heavy Laser is somehow better optimised for autofire than the Laser Rifle, and set the TUs for normal Auto at say 30% (vs 34% with Laser Rifle) that would let you get off 3 bursts, which would be better. (I could live with the idea that you can also only fire 3 snap shots). Then your &amp;quot;Full Auto&amp;quot; mode would be 100% TUs for 10 rounds and your &amp;quot;Burst Mode&amp;quot; could be 50% TUs for 5 rounds, and that would be consistent with the &#039;standard&#039; Auto mode. But the accuracy per shot needs to be much lower. I would suggest the base Accuracy per shot is reduced to 33% (one third less than Snap, similar to a Laser Rifle). You are still making the weapon MUCH more effective this way. [[User:Spike|Spike]] 12:47, 1 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: On further analysis, even this is too powerful. The stats I just cited would give firepower only a fraction less than a Heavy Plasma - with much lower cost, unlimited ammo and easier-to-reach technology. That&#039;s not balanced. Unfortunately, you can&#039;t really go above 6 shots per turn without unbalancing the game, as none of the 2 handed weapons fire more than 6 shots/turn. So the TUs for Auto need to be 34%-40%, and you can&#039;t really have it fire more than 6 shots per turn even in the Full Auto mode. I would suggest Auto = 35%, Burst = 75%, Full Auto = 80%. Burst and Full Auto only fire 6 shots. Burst Mode fires 2 shots each at 2 waypoints, and a further 2 rounds spread in between the 2 waypoints. Full Auto fires one each at 2 waypoints and 4 shots spread between the waypoints. And maybe the Burst Mode should be the more expensive one as it is more &#039;concentrated&#039; fire. The reason you can&#039;t really exceed 6 shots per turn, even if you reduce the accuracy drastically, is because otherwise you create a super-effective shock weapon at point blank range (and a super effective terrain-clearing weapon). Somehow the &#039;shock power&#039; in particular seems inappropriate for something as clumsy as a Heavy Laser. To rationalise it, think of it this way - it&#039;s not a machinegun, it&#039;s an energy weapon. The &#039;cyclic rate of fire&#039; is limited by the energy circuitry as much as anything else. So squeezing six shots per turn out rather than 3 (the limit with Snap fire) is a pretty good improvement. With the Auto Mode I&#039;ve suggested here, you have still double the &#039;shock&#039; firepower of the Heavy Laser at short range, and increased its firepower by two thirds at longer ranges. Not a bad way to put some life back into a weapon that otherwise has very limited uses. Probably in the &#039;Area&#039; modes (Burst / Full Auto) the Accuracy should drop, say to 25% (vs 33% in standard Auto). [[User:Spike|Spike]] 13:48, 1 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
Ok I finally shut down my NeXCom Workstation and turned out the lights in the Bean Counter&#039;s Department at X-Com HQ - and headed down to the Armoury. I checked out one of the new, experimental Super Heavy Auto Lasers and ducked onto an Avenger heading into a hot LZ. &lt;br /&gt;
&lt;br /&gt;
Seb, let me tell, you, it was SPECTACULAR! You are the Ayatollah of Rock-and-Rolla! I was like Jesse Ventura in Predator, carving up the jungle with his minigun. I love your gun. It is too cool. It must not be nerfed. So I have another suggestion for your coding skillz: &lt;br /&gt;
&lt;br /&gt;
See if you can get the &amp;quot;hidden item&amp;quot;, Gatling Laser, working. Add your Super Heavy Auto Laser as a new item, using the Gatling Laser image and OBDATA entry. I don&#039;t know if you can add a new Research option or a new Manufacturing option. If you can&#039;t, maybe you can offer it to Purchase (once Heavy Laser is researched, or perhaps Laser Cannon). Given the power of the weapon (as spec&#039;d above), the cost to buy or manufacture should be similar to a Heavy Plasma: around a total cost of $164K to manufacture (including &#039;&#039;all&#039;&#039; costs) or around $225K to buy. As a quick hack, for the time being, if you are still using the Heavy Laser object for the Super Heavy Auto Laser (with 10 shot Full Auto), increase the manufacturing costs and buy/sell prices to roughly the same as the Heavy Plasma. [[User:Spike|Spike]] 13:29, 3 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Thanks for the nice feedback! The initial idea for this mod came when watching a Laser Squad speedrun (never played the game myself) and seeing the guy waste several baddies with one auto-shot sweep (in this game you can also select the number of shots when auto-firing). I chose to try a modification of the heavy laser for 2 reasons: everybody agrees to say that the default one sucks and second, since it uses no ammunition there is no need to handle out-of-ammo conditions. I personally see this weapon more as a recipe for new doors than a direct way to kill aliens. Several things could nerf it a bit but I didn&#039;t try them yet:&lt;br /&gt;
:*make accuracy lower and lower during a burst (to account for the laser lens deformation caused by overheating). This would restore the advantage of cover and make people thing twice before firing when a friendly unit stands in front&lt;br /&gt;
:*reduce accuracy even further when shooting out of sight (this was mentionned in another post)&lt;br /&gt;
:*change the damage model and reduce the probability that terrain is destroyed when shot&lt;br /&gt;
:*have a cooldown period where the weapon is not useable (not sure if it&#039;s feasible though)&lt;br /&gt;
&lt;br /&gt;
::Yeah cooldown periods! Then restore functionality of the melee HIT command. Hey it worked for incubation: time is running out. ^^ [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 16:27, 7 September 2008 (PDT)&lt;br /&gt;
:::Hm, I already cannibalized the unused &amp;quot;open&amp;quot; and &amp;quot;close&amp;quot; actions for the heavy laser mod, there is no more room for a new &amp;quot;hit&amp;quot; command. Unless... ;-) [[User:Seb76|Seb76]] 11:28, 8 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:OK, here is the last draft before I finalize:&lt;br /&gt;
:*Shooting the HL will cost ~50 energy so you won&#039;t be able to abuse it (the shooter will be a sitting duck)&lt;br /&gt;
:*Each shot of a burst will reduce the accuracy (amount not determined yet)&lt;br /&gt;
:*The [[User:Seb76#Range_Based_Accuracy|Range Based Accuracy]] will always apply to the HL&lt;br /&gt;
:If everybody likes it, I&#039;ll got with that. Any comment? [[User:Seb76|Seb76]] 09:16, 22 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
Sounds good to me. [[User:Spike|Spike]] 17:25, 22 November 2008 (CST)&lt;br /&gt;
:OK, here we go. I won&#039;t tell you exactly what I did, just give me your feedback ;-) [[User:Seb76|Seb76]] 05:24, 23 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
It&#039;s been a while, but recently tried your newest version and it seems the heavy laser is bugged? No matter which firing mode I choose it is extremely inaccurate and a lot of shots after travelling in one direction suddenly &#039;deflect&#039; into another direction for some reason. It&#039;s a miracle none of my own guys were hit :) [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 12:41, 28 February 2009 (CST)&lt;br /&gt;
:It may have been broken by other stuff indeed. I&#039;ll have a look [[User:Seb76|Seb76]] 17:29, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
Hey, is it just me or is full auto not affected by range based accuracy, while burst is? I am using the RB accuracy mod on all weapons, and maybe that is affecting it. All I know is, even at long distance, full auto shows full accuracy. Not sure if the burst mode is showing the RB decrease I programmed or not though.&lt;br /&gt;
--[[User:Talon81|Talon81]] 06:01, 14 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:The heavy laser and range based accuracy stuff were developped in parallel and merged later. It is almost sure that things will go wrong if you activate both ;-) I could reproduce some issues and will try to fix them. BTW, I got no feedback for the &amp;quot;shortcuts&amp;quot; patch. Is it broken that badly that nobody wants to have it fixed? [[User:Seb76|Seb76]] 17:00, 18 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
I just used an unpatched version (CE, as I always use), and used your patch on it. The only things I even activated in the patch are the video fix so it was playable, the heavy laser mod, and the accuracy mod. Still have the same problem, so yeah... they don&#039;t work well together at the moment. But... I am hooked on the accuracy mod, so I guess Ill just deal with it and not use full auto. As far as shortcuts go... I had enabled it at one time, but I found that I just never used them. Maybe I will try to use it a bit to give you some feedback. I added a comment for alien bases, too, btw. --[[User:Talon81|Talon81]] 15:18, 19 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Wish List please please please ==&lt;br /&gt;
&lt;br /&gt;
=== New and Outstanding Requests ===&lt;br /&gt;
&lt;br /&gt;
* Remember soldier load outs from last mission and re-equip accordingly. Or maybe just prevent units from taking more than they can carry. Removing grenades first, then magazines and ammo and lastly guns.&lt;br /&gt;
: &#039;&#039;&#039;Save Equipment&#039;&#039;&#039; is under development, still some bugs&lt;br /&gt;
&lt;br /&gt;
* Make it so you can drop more than one screen worth of stuff in the pre-mission equipping phase.&lt;br /&gt;
&lt;br /&gt;
* Allow human side soldiers to reaction fire in their currently saved Reserved Fire mode - eg to take Autofire or Aimed reaction shots. That would be very, very cool. It would also be a balanced trade-off, if these Reacting soldiers were not allowed to &#039;switch&#039; to Snap fire after they no longer have the TUs left to use their Reserved mode. &lt;br /&gt;
&lt;br /&gt;
: Has this been completed via the &amp;quot;Save Reserve Mode&amp;quot; feature? Not entirely I guess as Reaction fire is still always in Snap. To be honest that&#039;s not a bad thing. [[User:Spike|Spike]] 08:54, 23 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
* Implement your &#039;Area Fire&#039; (as per Heavy Laser) for &#039;&#039;&#039;all&#039;&#039;&#039; large automatic weapons (AutoCannon, Heavy Plasma) or maybe just for all automatic weapons, period. It would be very handy for Autocannon bursts to cover a wider area, firing a narrow burst is often not what you want at all in many tactical situations. There might be a problem implementing this for Plasma weapons, if you couldn&#039;t persuade the Aliens&#039; AI to use the Area modes - it wouldn&#039;t be fair. &lt;br /&gt;
&lt;br /&gt;
* Close down Exploits. (I&#039;ve just been reorganising the Exploits pages so it&#039;s on my mind.) Maybe this is pointless for those who have the willpower just to abstain from using Exploits. But as these are actually bugs I think it would be good to fix them. The worst exploits in my opinion are:&lt;br /&gt;
** [[ExploitsA#Free Manufacturing|Free Manufacturing]]. Probably needs to add a check that the manufacturing project has &amp;gt;0 units before allowing it to start. &lt;br /&gt;
** [[ExploitsA#Free Wages|Free Wages]]. Pay wages regardless of whether staff are in transit. They are on the payroll after all. This has a drawback that you pay twice (1.5x) for staff you hired very near the end of the month, which would affect some styles of gameplay.&lt;br /&gt;
** [[Tactical Exploits]]: The worst ones are the Collision Detection bugs, those I imagine are &#039;&#039;&#039;hard&#039;&#039;&#039; to fix. &lt;br /&gt;
** Eliminate &amp;quot;infinite fuel&amp;quot; exploit for conventional aircraft.&lt;br /&gt;
* Side-arm throws for grenades: It would be nice if the game could first check for a direct fire solution (side-arm throw or straight throw) for a grenade attack, if the target is in range for a straight throw, Range for straight throws would be reduced (to 1/4 or so of the parabolic range). It would only go on to attempt the indirect fire solution (parabolic vertical throw) if the direct fire attack returns &amp;quot;no line of fire&amp;quot;. This would avoid a lot of the &amp;quot;hit the ceiling&amp;quot; issues with grenade indirect fire.[[User:Spike|Spike]] 08:54, 23 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
* With View All Locations, put some kind of indicator or (better yet) counter on the Geoscape screen when there are UFOs in flight. In case the UFO is on the other side of the world from where you are currently looking. &#039;&#039;&#039;-OR-&#039;&#039;&#039;&lt;br /&gt;
* Make the world rotate at normal speed (i.e. once per 24 hrs. Rotation starts after say 12 or 24 hrs of looking at the Geoscape and not touching anything. Stops again if you touch the globe controls.&lt;br /&gt;
* Make Aliens able to pick up a weapon if they are empty handed! Or just make them pick up anything Alien in their square, if that&#039;s easier. Maybe move them towards a weapon if they have no weapon - much harder to do I suppose. But at least, if they are empty handed and happen to walk over an Alien weapon, pick it up! See discussion [[Wish List#Alien AI|here]]. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* [[Wish List#Prior Recon of Battlefield|&amp;quot;Eye in the Sky&amp;quot;]]. Map (set to visible) all terrain features on Turn 1 (but do not sight any hostile units). Ideally this should be only the exterior of buildings but that&#039;s probably too tricky. Assume we have something like a FLIR on the Skyranger that can do basic imaging of the inside of buildings.  &lt;br /&gt;
&lt;br /&gt;
* Grenades that [[Wish List#Warm Grenades|function normally]].&lt;br /&gt;
&lt;br /&gt;
* Fix Base Storage display problems that lead to storage weirdness. Discussion and recommendations [[Talk:Base Stores#Base Stores Anomalies|here]].&lt;br /&gt;
&lt;br /&gt;
* Enable native alien melee attacks within Alien Pets.  The Floaters are pleading.  (At the moment, Alien Pets+Big Brother means a crashed Superhuman Floater Large Scout costs 6-8 X-COM agents; corresponding crashed Sectoid Superhuman Large Scout is only worth 3-5 X-COM agents.  Floater Large Terror Ship on just Big Brother : only one agent, and that was due to the top-of-stair pinning bug providing enough TU to do something.) -- [[User:Zaimoni|Zaimoni]] 12:39, August 12 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
* Do something to help out the psi aliens as well within Alien Pets, as above. -- [[User:Zaimoni|Zaimoni]] 12:39, August 12 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
* Would it be possible to change the master volume level in the game, or at least have a no sound option? [[User:Epiceuropean|Epiceuropean]] 00:26, 12 January 2010 (EST)&lt;br /&gt;
&lt;br /&gt;
=== A few more ===&lt;br /&gt;
&lt;br /&gt;
Do any of these take your fancy:&lt;br /&gt;
&lt;br /&gt;
* Draw the Radar detection radii onto the map as a circle(s) around the base (also for moving aircraft?)&lt;br /&gt;
&lt;br /&gt;
* Show All UFOs (Ultrawave Detector - like Show All Locations, but doesn&#039;t show Alien Bases, you still have to hunt for those).&lt;br /&gt;
&lt;br /&gt;
* Sensible Ammo Recovery = add up all remaining rounds of ammunition at the end of a mission (in the ship, if Aborting), and recover a number of (full) clips equal to that number divided by the clip capacity (rounded down maybe).&lt;br /&gt;
: There&#039;s a reason I didn&#039;t turn Clip Recovery on, and it&#039;s that I guessed that it didn&#039;t work exactly as it&#039;s suggested here. If it did work like this, I would use it. [[User:Stubbs|Stubbs]]&lt;br /&gt;
&lt;br /&gt;
* Implement tactical time limits for UFO Assaults/Recoveries. After a random period (within a pre-defined upper and lower time limit), the aliens leave. Pop up warnings appear at the end of each turn, saying the UFO engines are powering up. When the aliens leave, all aliens/items/equipment inside the UFO is gone - no loot, no score. Any soldiers still inside the UFO are considered MIA. The soldiers are &#039;&#039;captured&#039;&#039; in fact - score penalty worse than MIA? There must be one conscious alien inside the UFO for it to leave or attempt to leave. Maybe any live aliens outside are &#039;beamed&#039; or &#039;tractored&#039; inside the UFO, complete with their equipment? (E.g. the mission ends and you don&#039;t get score for them or their equipment either - just for the corpses and dropped loot).&lt;br /&gt;
&lt;br /&gt;
* No Milk Please: After XCom withdraws from an Alien Base, randomise the base&#039;s location and make it hidden again. Just like what happens to the aliens after they fail to assault an X-Com base. Though you would probably still need to locate it within the same country or region so finding it again wouldn&#039;t take long I guess. Would it mess things up to move the base to a random part of the world?&lt;br /&gt;
&lt;br /&gt;
* [[User:Spike#Tank mods|Tank Armour and Equipment Mods]]&lt;br /&gt;
&lt;br /&gt;
But I should probably code this up myself, looking at your source code it doesn&#039;t look &#039;&#039;&#039;too&#039;&#039;&#039; hard. [[User:Spike|Spike]] 14:46, 24 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 14:46, 24 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
* Burning Zombies&lt;br /&gt;
&lt;br /&gt;
It&#039;s more or less impossible to prevent Zombies from hatching into Chryssalids by killing the Zombies with fire, since fire does such a small amount of damage, and the requirement is that the actual killing point of damage is done by an incendiary. Apart from hitting them with an incendiary and running away, then waiting about ten turns for them to die (probably repeating the attack once or twice), this is only ever going to happen by blind luck. &lt;br /&gt;
&lt;br /&gt;
It would be much more viable if the rule was (also?) that a Zombie which is &#039;&#039;&#039;on fire&#039;&#039;&#039; at the time of death would not hatch into a Chryssalid. This is not exactly easy either, but it is at least possible. It requires hitting the Zombie repeatedly with incendiary weapons until it catches on fire, then killing it right away with regular weapons (before the fire goes out). &lt;br /&gt;
&lt;br /&gt;
A much easier version of this approach would be to say that if the Zombie is killed while it is &#039;&#039;&#039;in fire&#039;&#039;&#039;, it does not hatch. But that is probably too easy. &lt;br /&gt;
&lt;br /&gt;
A way to do this by hacking game files, without code changes, would be to increase the Zombie susceptibility to fire, to 200%. This would make incendiary weapons a viable way of killing them, as well as increasing the likelihood that the killing shot was an incendiary shot. &lt;br /&gt;
&lt;br /&gt;
An alternative approach would be for the Zombie to have a chance of not turning into a Chryssalid, proportional to the percentage of health damage that had been caused by incendiaries. But that&#039;s probably too hard to track, it would require an extra/unused field in UNITREF.DAT. &lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 13:12, 7 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
* Fear of Fire&lt;br /&gt;
&lt;br /&gt;
Apparently there is no morale effect from [[Incendiary#Damage|Incendiary damage]]. If anything, for humans, and maybe be for other humanoid aliens, fire should probably have a greater morale effect than ordinary damage, not none. A basic fix would treat fire damage the same as normal damage when reducing morale. A more complicated fix could add a weighting to this morale effect: multiply by the creatures susceptibility to fire (or reduce by its resistance to fire). Any creature or soldier that is immune to fire should not have its morale affected. Actually the affects of fire vary quite a lot (different aliens, different human armour types). Maybe this is why the designers didn&#039;t get around to implementing morale effects for fire, as it&#039;s a bit complicated. &lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 13:40, 7 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
=== Multi Stage Missions ===&lt;br /&gt;
&lt;br /&gt;
Between each stage of a multi-stage mission:&lt;br /&gt;
&lt;br /&gt;
* Send all artefacts (non-usable items), corpses and recoverables back to base&lt;br /&gt;
* If possible, remember the score for these items, and apply it to the score at the end of the mission&lt;br /&gt;
* Alternatively, pop up a score window between the mission stages, and apply the score then?&lt;br /&gt;
* Gather all loose usable equipment into the &amp;quot;equipment pile&amp;quot; for the next stage&lt;br /&gt;
* Or possibly re-run the Equip Screen between mission stages, again gathering all loose usable items into the equipment pile first.&lt;br /&gt;
* Keep an 80 item limit on what you can take into the next stage&lt;br /&gt;
* Prune down to the 80 item limit using some sensible rules, not sure what exactly.&lt;br /&gt;
&lt;br /&gt;
This is of limited use in X-Com EU but would be much more use for TFTD, one day. EU has only one multi stage mission, and it ends the game, so only some of these points above will be relevant. &lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 20:54, 2 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
=== Even More ===&lt;br /&gt;
&lt;br /&gt;
Tremendous work, you&#039;ve pretty much made the game worth playing again.  Best work since Xcomutil.  As with everone else, I have a few requests. [[User:KingMob4313|KingMob4313]] 23:59, 12 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
: Ability to change damage modifier.  Right now the damage runs from 0-200% of damage values on the weapon.  I&#039;d love to see a way to change it to 50-150%, 75-125% or the like. &lt;br /&gt;
&lt;br /&gt;
: A modifier to increase or decrease the explosion radius modifier.  Right now the radius is either keyed to the explosive or to the explosive damage.  I&#039;ll investigate it further.  But it would be nice to have a very small radius, but high powered explosive for use as a breaching charge. &lt;br /&gt;
:: There is a &amp;quot;crimping&amp;quot; function on some of the explosions already so it might be possible to exploit that. Check the [[Explosions]] page. [[User:Spike|Spike]] 14:46, 24 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
: A modification of the range based accuracy.  One handed weapons have a shorter range, to the point that even their aimed shots have an effective range, two handed weapons have a further range (and no aimed shot effective range) and really heavy two handed weapons have an even further range. &lt;br /&gt;
&lt;br /&gt;
: A modification so that on the alien&#039;s side first turn, they do not have their full time units in reserve for reaction fire. Nothing like getting shot 3 times from the same sectiod after missing ONE shot on them.&lt;br /&gt;
&lt;br /&gt;
:: You could always wait a turn before you open the door. :) [[User:Spike|Spike]] 14:46, 24 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
=== More Exploits to Close ===&lt;br /&gt;
&lt;br /&gt;
* [[Exploiting Mind Control#Exponential Mind Control|Exponential Mind Control]]&lt;br /&gt;
&lt;br /&gt;
Probably the worst single exploit in the game. What is needed is to disable any mind control actions for a Psi Amp, if the unit holding the Psi Amp is currently mind controlled. &lt;br /&gt;
&lt;br /&gt;
Also a general mind control bug/exploit fix for:&lt;br /&gt;
&lt;br /&gt;
* [[Exploiting Mind Control#Exponential Mind Control|Civilian Traitors]]&lt;br /&gt;
* [[Exploiting Mind Control#Exponential Mind Control|Resurrect Zombified Agents]]&lt;br /&gt;
* [[Exploiting Mind Control#Exponential Mind Control|Zombie&#039;s Permanent Control of Aliens via Stunning]]&lt;br /&gt;
: Above 3 bugs are fixed by &#039;&#039;&#039;Hostile Civilians&#039;&#039;&#039; fix.&lt;br /&gt;
&lt;br /&gt;
* Probably many other missing/MIA-type bugs&lt;br /&gt;
&lt;br /&gt;
These probably all arise from the daft decision to save a single byte (or even bit), by not recording separately the current vs default &amp;quot;side&amp;quot; a unit is on. The game only tracks the &amp;quot;current side&amp;quot;. Consequently when mind control ends, the game often makes dumb decisions as to what side to &amp;quot;restore&amp;quot; the unit to. We could use an unused byte to track the default &amp;quot;side&amp;quot;, but that would require overloading a presumed &amp;quot;unused&amp;quot; field and that could be risky. But actually we can always deduce the &amp;quot;default side&amp;quot; from the unit type: XCom for soldiers and tanks, Neutral for Civilians, Alien for everything else. So what is needed is just an end-of-turn check to restore everything to its correct side, based on its unit type. Actually it&#039;s slightly complicated by alternating turns. You need to update all (originally) Alien units at the end of the Alien turn, all originally XCom units at the end of the XCom turn. You might also need a special end-of-game update, to avoid the MIA-type bugs. [[User:Spike|Spike]] 12:22, 26 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
: AlienSWP.py implements turnswapping via mind control, like XCOMUtil.  Handling the alternating turns, as you described, is necessary to make mind control work properly (a mind-controlled alien remains with X-COM during the alien turn, and so on).&lt;br /&gt;
&lt;br /&gt;
: I would assume that the original programming team had a coding policy forbidding both bitfields, and emulating them with bitwise shifts.  That&#039;s really the only way I can explain most of the idiosyncrasies of the file format.  [[User:Zaimoni|Zaimoni]] 12:07, 26 August 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
=== See Also ===&lt;br /&gt;
&lt;br /&gt;
*[[Wish List]]&lt;br /&gt;
*[[Known Bugs]]&lt;br /&gt;
*[[Exploits]]&lt;br /&gt;
&lt;br /&gt;
== Completed Items - Thanks Seb! ==&lt;br /&gt;
&lt;br /&gt;
See also the lists at: [[User:Seb76#Mods]] and [[User:Seb76#Bug_Fixes]]&lt;br /&gt;
&lt;br /&gt;
* Add 1-2 UFO Navigation to the haul after a successful Alien Base Assault. &lt;br /&gt;
:The game actually has specific code to remove these from the recovered items, it&#039;s just a matter of bypassing it. Next version will have an option to do so. [[User:Seb76|Seb76]] 07:19, 7 September 2008 (PDT)&lt;br /&gt;
:: Completed with the &amp;quot;Keep Base Navigation Tables&amp;quot; option. &lt;br /&gt;
&lt;br /&gt;
* Random chance (1-2%, and only for Scouts) per mission that a UFO accidentally crashes - like the &amp;quot;Roswell Incident&amp;quot;. Crash site would be automatically detected &amp;amp; UFO would have random damage. &lt;br /&gt;
:Sounds like a nice idea. I&#039;m working on it but I still have some crashes, and the routine to check if a ship is over water does not seem to work properly :( [[User:Seb76|Seb76]] 07:19, 7 September 2008 (PDT)&lt;br /&gt;
:Update: feature almost complete, time to bake a new version ;-)&lt;br /&gt;
&lt;br /&gt;
:[[Image:Roswell.png]]&lt;br /&gt;
&lt;br /&gt;
:There are probably some bugs lurking (the most likely problem would be unfreed CRAFT.DAT entries), but I don&#039;t think I&#039;ll change the code much now. [[User:Seb76|Seb76]] 07:47, 13 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Got an idea while I was at work today that I thought I&#039;d throw onto the wish list. Some means to completely fast-forward the base defense screen. Either by making all the firing sequences happen in an instant, or completely skip the screen altogether. I always advise against making impenetrable bases if only to preserve your sanity. I mean you eventually get sick of being interrupted to watch the defense module firing screen for the umpteenth time. If you never got the interruptions then an impenetrable base would be quite satisfactory. You shouldn&#039;t be getting any points for a failed base attack so you won&#039;t be gaining from it. About the only problem would be when an undefended base gets destroyed, unless you can make a dialog box pop up to announce it. -[[User:NKF|NKF]] 03:10, 2 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: Fixed with &amp;quot;Faster base defence sequence&amp;quot; option. [[User:Spike|Spike]] 06:40, 14 December 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Multiple Radar - Fixed. &lt;br /&gt;
&lt;br /&gt;
Can I ask what algorithm you used for Multiple Radar? The algorithm in my BaseFixer.py Python script is actually much better than the fairly lame one described on my User page. [[User:Spike|Spike]]&lt;br /&gt;
:As I said, I used about the same as in you BaseFixer script:&lt;br /&gt;
 float shortDetection=pow(0.9f,smallRadars);&lt;br /&gt;
 float largeDetection=pow(0.8f,largeRadars);&lt;br /&gt;
 &lt;br /&gt;
 *(short *)(&amp;amp;base[0x10])=(short)((1.0-shortDetection*largeDetection)*100.0);&lt;br /&gt;
 *(short *)(&amp;amp;base[0x12])=(short)((1.0-largeDetection)*100.0);&lt;br /&gt;
:However I keep the computed value even for the one small/one big radar combo ;-) [[User:Seb76|Seb76]] 07:19, 7 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
* Accuracy reductions for long range snap and auto fire - Fixed. &lt;br /&gt;
* Aircraft always ready for mission despite re-fuel/re-arm status - Fixed&lt;br /&gt;
* Stack up base build orders in advance - Implemented&lt;br /&gt;
* More smoke and fire - Fixed&lt;br /&gt;
* Blaster drift and waypoint bug - Fixed&lt;br /&gt;
* Stats visible during Equip phase - Implemented&lt;br /&gt;
* Melee combat (bludgeoning) with any weapon - Fixed&lt;br /&gt;
* With &amp;quot;Council Funding Only&amp;quot;, allow items to be sold for money if they are &#039;&#039;purchasable&#039;&#039; (i.e. conventional weapons). Buying and selling these is loss making, and there is no source of them on the Battlescape, so it does not create any &amp;quot;income&amp;quot; (except at the start of the game perhaps). But it does help to manage a tight budget. And you need all the help you can get with &amp;quot;Council Funding Only&amp;quot;. Check offset 18 of [[PURCHASE.DAT#Structure|PURCHASE.DAT]] If byte 18 is true then it&#039;s ordinarily Purchasable, so it&#039;s ok to sell that item. - OK, here is your christmas gift ;-) You can sell what you can purchase now. [[User:Seb76|Seb76]] 08:28, 28 December 2008 (CST)&lt;br /&gt;
* Close Down Exploits&lt;br /&gt;
** [[ExploitsA#Robotic Manufacturing|Robotic Manufacturing]] / [[ExploitsA#Cybernetic Laboratories|Cybernetic Laboratories]] - Fixed&lt;br /&gt;
&lt;br /&gt;
* More video options. In particular, an option to put padding at the top and the bottom of the screen to preserve the aspect ratio on a 4:3 monitor. Maybe it&#039;s just me, but stretching the original height of the game to fit a 4:3 screen makes the Battlescape look weird. (Actually, if you update the source code link, I could try to do it myself. The current source doesn&#039;t seem to include your more recent changes. --[[User:Mikawo|Mikawo]] 20:30, 12 August 2009 (EDT))&lt;br /&gt;
** Thanks for uploading the new source code. I managed to add the letterboxing that I wanted. If you wanted to make it an official feature I could upload the updated files. And I don&#039;t think I said this before, but thanks for the great loader! --[[User:Mikawo|Mikawo]] 18:40, 14 August 2009 (EDT)&lt;br /&gt;
:Go ahead and upload/PM me the file (d3d.cpp I presume?), I&#039;ll gladly incorporate your modification. [[User:Seb76|Seb76]] 19:14, 14 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Fix the [[Tactical Exploits#Fire|bug]] where all units in smoke/fire take stun/fire damage, whenever any smoke/fire hex is hit with an [[Incendiary]].&lt;br /&gt;
&lt;br /&gt;
:: Boy oh boy this is a tough one. First we need to figure out how Incendiary actually works. Zombie is getting in to some heavy testing over on [[Talk:Incendiary]]. Right now, the more we learn, the more we know we &#039;&#039;don&#039;t&#039;&#039; know. With this &#039;Funky Fire&#039; bug, presumably what is going on is that during an Incendiary explosion, the game engine loops through all units that are in fire(and on fire?). This is wrong. What it should be doing is testing to see if they are within the Area of Effect of this particular IN round. The game definitely has working code to correctly select units within an area of effect, since that&#039;s what happens for HE and Stun explosions. But in this case it does not apply the correct selection criteria. What is looks like it does is scans the Unitref table (copy in memory) for every unit standing on a tile with fire in it, and maybe also with the &#039;on fire&#039; flag set. Both of these lookups are actually irrelevant to an exploding IN round. These looks would make exact sense for the end-of-turn processing of fire damage, but not for the instantaneous effect of an IN round. They should use the HE/Stun routine instead, to select the units for processing. Then when the units are selected, it should apply the IN effects - still to be determined. So yes, I think what&#039;s happened is the coders mistakenly used the &amp;quot;end of turn&amp;quot; criteria to select units for instantaneous damage/effect when an IN round explodes. Anyway, once Zombie has sorted out the facts, maybe you could take a look at these IN explosion routines? I guess one difficulty is that the HE routine is performing 2 functions - it&#039;s doing damage to terrain, and also flagging units to apply damage to. It may also be setting smoke. Similarly, the IN routine ought to have 2 functions - to apply fire/burning time to the tile, but also to apply IN damage effects to the occupants of the tiles. This really could be coded badly and just hard to fix. [[User:Spike|Spike]] 19:17, 11 March 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
OK I&#039;m pretty sure this is the whole problem with the Funky Smoke/Fire bug. What&#039;s going on is the Incendiary Explosion routine is calling the whole end-of-turn smoke/fire processing routine, every time an IN round explodes anywhere on the map. That&#039;s why you get smoke induced stun as well as fire-induced damage. All you need to do is find this IN Explosion routine and make it return unconditionally before it calls the end-of-turn routine. That will substantially solve the bug. What the IN Explosion routine ought to do is:&lt;br /&gt;
&lt;br /&gt;
# In area of effect&lt;br /&gt;
##add fire to tiles&lt;br /&gt;
##&#039;&#039;&#039;possibly&#039;&#039;&#039; do 33% check for units to catch fire - &#039;&#039;&#039;unless&#039;&#039;&#039; this is performed by the end of turn routine (probably)&lt;br /&gt;
# IF a unit was hit directly&lt;br /&gt;
## check to see if it catches fire&lt;br /&gt;
## &#039;&#039;possibly&#039;&#039; do &amp;quot;impact&amp;quot; damage. &lt;br /&gt;
# Return, &#039;&#039;&#039;without&#039;&#039;&#039; calling the end-of-turn smoke/fire routine&lt;br /&gt;
&lt;br /&gt;
And it&#039;s entirely possible there was never supposed to be any &amp;quot;impact&amp;quot; damage, all that was intended was to set tiles and units on fire, with any damage only coming at the end of turn. You can easily imagine a last minute and ill-considered coding decision to run the end of turn routine upon every IN explosion, as an attempt to increase IN lethality, without thinking through the implications properly. So the &amp;quot;impact&amp;quot; damage could just be a side effect of the funky fire bug - applying the 5-10 &amp;quot;on fire&amp;quot; damage right away, when it was meant to be applied at end-of-turn. &lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 22:11, 11 March 2009 (CDT)&lt;br /&gt;
:Hey, that&#039;s a nice piece of supposition:) There is actually what I called an ApplyFireAndStunDamage function which is indeed called after IN explosions and at the end of the turn... It basically damages/stuns every unit on fire/in smoke and makes units standing in firing tiles possibly take fire. The function is called 5 times, one of which is at the end of the turn so patching the 4 other locations should remove the bug; but also weaken the IN rounds...[[User:Seb76|Seb76]] 16:22, 12 March 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
::Thanks! :) But now you&#039;re scaring me - why would there be &#039;&#039;&#039;4&#039;&#039;&#039; calls to this function, apart from end-of-turn? Why wouldn&#039;t there just be one piece of common code, one call, for IN explosions? I&#039;m racking my brains. I guess there could just be 4 different situations when an IN round could explode. Maybe - direct impact, impact with terrain, reaction fire, large units, auto fire... guesswork! Reaction fire is a good guess - we already know lots of things that are bugged with reaction fire, which suggests the code for reaction fire may be a separate loop. There are hints that auto fire may be handled differently for IN - only hints. I&#039;d be worried patching out all 4 calls. But, if you can do it, I&#039;m very happy to test for unintended consequences. &lt;br /&gt;
&lt;br /&gt;
::It will be interesting to see if patching out all 4 calls eliminates &amp;quot;impact&amp;quot; IN damage from direct hits - suggesting it was only ever an unintended effect of the bug. It may not be possible, but &amp;quot;impact&amp;quot; damage might be the one thing to retain, to avoid making IN weapons too weak. Still it might not be an option. Interesting stuff! &lt;br /&gt;
&lt;br /&gt;
::Any chance you could do 5 separate config file flags to mask out the 5 calls? Then I could determine by experiment what each one does. [[User:Spike|Spike]] 18:27, 12 March 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Replace the batch file that runs xcomutil. Make it so the loader will call an outside program at certian points. Add a section to the config file that will allow the user to pick a program to be run.&lt;br /&gt;
[Utilities]&lt;br /&gt;
Run Utilities=0|1&lt;br /&gt;
Run before battle=&amp;quot;xcomutil ...&amp;quot;&lt;br /&gt;
Run after battle =&amp;quot;xcomutil ...&amp;quot;&lt;br /&gt;
Run before base screen=&amp;quot;xcomutil ...&amp;quot; &lt;br /&gt;
:The above works perfectly. [[User:KingMob4313|KingMob4313]] 00:05, 13 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
* Allow scrolling the map with the keyboard. &amp;quot;WASD&amp;quot; as default maybe, since you used the arrow keys and most people have thier left hand free anyway. Allow moving units one square at a time with the numpad. First tap changes facing if not looking that way, second one moves you in that direction.&lt;br /&gt;
:Fixed via Keyboard Shortcuts - and configurable too.&lt;br /&gt;
&lt;br /&gt;
== Warm Grenades ==&lt;br /&gt;
&lt;br /&gt;
It would be nice to have a Mod where grenades / HE  explode a set number of half-turns after you drop/place them. &lt;br /&gt;
&lt;br /&gt;
This could be implemented by an extra bit of logic that increments the &amp;quot;Turn When I Will Explode&amp;quot; field by +2 if the grenade is being held/worn when the Explode check happens. &lt;br /&gt;
&lt;br /&gt;
For me this is a more natural way for grenades to work: set the fuse, then the fuse only starts when you release the spring or set the HE pack in position. Certainly hand grenades should behave this way. I guess people could argue that HE packs should behave in the standard way. In which case, you could check the weapon type and use different logic for HE.  &lt;br /&gt;
&lt;br /&gt;
Hopefully the Alien AI would not be confused by any of these changes. I suspect the AI cheats anyway? Or always sets to 0 and throws right away? [[User:Spike|Spike]] 02:00, 2 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
== Facility maintenance cost bug ==&lt;br /&gt;
&lt;br /&gt;
Could you fix that? [[User:Spike|Spike]] 16:15, 3 September 2008 (PDT)&lt;br /&gt;
:I&#039;m a bit confused about this one. Some says that the fund graph is OK but not the amount of money taken. I had a look at the code and found that what is shown on the graphs is exactly the same amount as removed (the graph data is updated at the same place and the computation is done once for both). I think I remember also someone saying that the bug does not exist at all... Can someone clarify? [[User:Seb76|Seb76]] 02:31, 15 September 2008 (PDT)&lt;br /&gt;
::The graph is ok and the amount of money taken is ok (tested). What is wrong is the maintenance displayed in the &#039;Base overview&#039; screen (in every respective base you go to &#039;overview&#039; and something like &#039;maintenance&#039;). The wrong way is very well described here [[Base_Facilities#Displayed_Base_Maintenance_Cost_Bug]], I think you will guess what exactly is wrong in the code. --[[User:Kyrub|Kyrub]] 15:34, 17 September 2008 (PDT)&lt;br /&gt;
:Thanks, I found the code and it is indeed completely f*cked up. I&#039;ll try a fix tomorrow. [[User:Seb76|Seb76]] 16:53, 17 September 2008 (PDT)&lt;br /&gt;
:Edit: Done. What&#039;s next? ;-) [[User:Seb76|Seb76]] 01:15, 18 September 2008 (PDT)&lt;br /&gt;
::Blimey. Seeing the work you have put in (below), it is impressive beyond measure. And... what next? Well... Could you possibly fix a game harming BUG of the blind spots? How come he sees you, and you do not see him, and vice-versa? There must be some strange way the line of sight is implemented in the code... See here: [[http://www.ufopaedia.org/index.php?title=Line_of_sight]], &amp;quot;Blind spots around the corner&amp;quot;.&lt;br /&gt;
Just how bad was the mess up? Curios minds demand to know! By the way, my mind was wandering while at the office and one thing came to mind to add to your already useful inventory display: Armed grenade status. Ever drop one you&#039;ve just armed and lose it in a pile of other unarmed grenades on the ground? &lt;br /&gt;
:Well, from the look of it, I think they were trying to compute the maintenance cost using an array. Obviously something was wrong.&lt;br /&gt;
:*they first try to clear an array of 0x11 entries at the begining of the function (there are 0x11 base elements types, hangar count as 1). Note that there is already a bug here and the array is not cleared as expected, only the first entry is cleared 0x11 times...&lt;br /&gt;
 mov     esi, 11h&lt;br /&gt;
 ...&lt;br /&gt;
 loc_44004C:&lt;br /&gt;
 dec     esi&lt;br /&gt;
 mov     word ptr [esp+3Ch+elementsArray], 0&lt;br /&gt;
 jnz     short loc_44004C&lt;br /&gt;
:*ecx is initialized to point to the maintenance cost data (nothing wrong here)&lt;br /&gt;
 mov     ecx, offset baseElements.maintenance&lt;br /&gt;
:*then they loop on each base element, but the inner loop is nonsense (at this point ax contains the base element type. edi is the total maintenance cost):&lt;br /&gt;
 movsx   eax, ax&lt;br /&gt;
 inc     word ptr [esp+eax*2+44h+elementsArray]  ;increment the array entry corresponding to the base element type&lt;br /&gt;
 lea     eax, [esp+eax*2+44h+elementsArray]      ;get the address of the array entry we just incremented&lt;br /&gt;
 xor     eax, eax                                ;discard the address we just computed (!)&lt;br /&gt;
 mov     al, [ecx]                               ;get the maintenance cost from ecx; the element type is not used here (!)&lt;br /&gt;
 lea     eax, [eax+eax*4]&lt;br /&gt;
 lea     eax, [eax+eax*4]&lt;br /&gt;
 lea     eax, [eax+eax*4]&lt;br /&gt;
 lea     edi, [edi+eax*8]                        ;totalMaintenaceCost+=elementMaintenanceCost*1000&lt;br /&gt;
:we see that they increment the array element, but the content of the array is discarded and the maintenance cost (edi) is computed simply from [ecx].&lt;br /&gt;
:*then after each row, we have this:&lt;br /&gt;
 add     ecx, 10h&lt;br /&gt;
:which explains why the cost changes for each row.&lt;br /&gt;
:I don&#039;t see what kind of C code could produce such disassembly; maybe there is a bug in the compiler,at least the address calculation should have been removed (optimized out).&lt;br /&gt;
:The fix required two patches:&lt;br /&gt;
:*remove the incrementing of ecx for each row&lt;br /&gt;
 char nop[]={0x90,0x90,0x90};&lt;br /&gt;
 PatchInPlace(0x44066E,nop,3);&lt;br /&gt;
:*make a working inner loop:&lt;br /&gt;
 char patch[]={&lt;br /&gt;
   0x03, 0xc0,                  // add eax,eax&lt;br /&gt;
   0x8a, 0x04, 0xc1,            // mov al, BYTE PTR [ecx+eax*8] ;get the maintenance cost for the *specific* base element&lt;br /&gt;
   0x0f, 0xb6, 0xc0,            // movzx eax, al&lt;br /&gt;
   0x90, 0x90, 0x90, 0x90, 0x90 // nop the remaining&lt;br /&gt;
 };&lt;br /&gt;
 PatchInPlace(0x440651,patch,13);&lt;br /&gt;
:this takes care of the nonsense code&lt;br /&gt;
 inc     word ptr [esp+eax*2+44h+elementsArray]  ;increment the array entry corresponding to the base element type&lt;br /&gt;
 lea     eax, [esp+eax*2+44h+elementsArray]      ;get the address of the array entry we just incremented&lt;br /&gt;
 xor     eax, eax                                ;discard the address we just computed (!)&lt;br /&gt;
 mov     al, [ecx]                               ;get the maintenance cost from ecx; the element type is not used here (!)&lt;br /&gt;
&lt;br /&gt;
Very interesting stuff! By the way I&#039;m playing a &amp;quot;Roswell&amp;quot; game at the moment and loving it - thanks Seb! [[User:Spike|Spike]] 10:31, 20 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
==Grenade Status Indicator==&lt;br /&gt;
&lt;br /&gt;
Is it possible to include an indicator on the end of the grenade&#039;s name string to show whether the grenade has been armed? Or perhaps even show how many grenade ticks are left to go? &lt;br /&gt;
:Hmm, I&#039;ll see if I can find something&lt;br /&gt;
&lt;br /&gt;
== Keyboard Support ==&lt;br /&gt;
&lt;br /&gt;
Would it be possible to introduce some keyboard shortcuts for simple tasks? -[[User:NKF|NKF]] 00:48, 19 September 2008 (PDT)&lt;br /&gt;
:sSuch as? [[User:Seb76|Seb76]] 02:52, 19 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Hmm, perhaps a few keys like they had in Apocalypse for ending the turn and raising/lowering the elevation with the page up and down keys would be a good start, or jumping to the inventory screen. Perhaps keys in the Geoscape for setting the time compression settings. I can already see a bit of an obstacle with adding a key capture function in the Geoscape, you&#039;d have to know when you&#039;re entering strings or every other time when you&#039;re just toggling the Geoscape overlay. I&#039;ve always admired this game for relying on a two button mouse for pretty much everything except when entering strings, but if it&#039;s within the realm of possibility I think it would be great to have some keyboard shortcuts. -[[User:NKF|NKF]] 12:39, 19 September 2008 (PDT) &lt;br /&gt;
&lt;br /&gt;
Well, since it has been a little while now, and nobody has said anything, let me be the first. Thank you for the shortcuts on the geoscape. As I mentioned before, I had the shortcuts on battlescape on, but personally I never used them because it is not timed. But the geoscape, being that there is no pause, I have found a lot of use in shortcuts. Works perfectly for me, too. Secondly, the obdata editing feature is fantastic. If only it worked on accuracy, too....&lt;br /&gt;
Thanks again, my friend. --[[User:Talon81|Talon81]] 17:19, 22 May 2009 (EDT)&lt;br /&gt;
:I&#039;ve put a new version with support for more settings, give it a shot ;-) [[User:Seb76|Seb76]] 06:25, 23 May 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
First off have to say that this is outstanding work Seb, sincere thanks for what you have done here. I have started playing this again after years thanks to your hard work. I was going to suggest the old smoke limit problem but before I could you fixed it!! I have some other ideas, I know there are a lot but I thought I would throw them in anyway. Don’t mind if you think there all rubbish, you’ve done loads already. &lt;br /&gt;
:Thanks. Don&#039;t hesitate to suggest stuff, if it is not too difficult I&#039;ll try to make something :)&lt;br /&gt;
BTW is there a separate loader with your new Laser weapon? Can’t see it listed in the extender file (not researched it in my current game yet).&lt;br /&gt;
:There is a special [[Image:UFOExtender-dev.zip|dev version]] for the HL mod. It is not in the normal package since it is still too experimental. &lt;br /&gt;
A suggestion for a mod would be the following; I understand that if you defeat an alien assault on your base with base defense measures, then the aliens will continue to attack that base with more battleships until defeated inside the base (they then have to ‘find’ your base again before launching another attack). Can this be altered so that if their battleship is destroyed then they have to find your base again before dispatching anther battleship? Or a chance that they have to find it again. &lt;br /&gt;
:I&#039;d gladly work on that, but I need a savegame to reproduce the problem. I have one but when the battleship is destroyed, no other comes back later so there must be something wrong with it.&lt;br /&gt;
Another suggestion is that I also understand that when the aliens use psi attacks they always go for your guys with the most chance of failing the attack and going nuts. Is it possible to make those pesky aliens attack random soldiers, regardless of their psi skill/strength? &lt;br /&gt;
:At one time I had the idea of having aliens target only visible units, but then I thought that the scout units would be doomed. Maybe targeting any unit randomly would be better. I&#039;ll give it a try.&lt;br /&gt;
If you psi control a human in a terror mission, they become enemies when you lose control (meaning you have to kill the poor idiots to finish the mission). Any chance that they could revert to friendlies/non enemies again when you lose control? &lt;br /&gt;
&lt;br /&gt;
Men who are under alien control when you win become MIA, any chance they could be saved (you will have killed all the aliens after all).&lt;br /&gt;
:These two are on my secret todo list ;-)&lt;br /&gt;
::I was doing a Terror mission and getting creamed by Sectoids and Cyberdisks. Had a couple of guys left and got them back into the Skyranger only to find a civilian cowering at the back (must of walked in at some point). When I took off the civilian was counted as being killed by the aliens. Would it be possible to count any civilians in x-com craft at end of Terror as recued if you have to blast off? I think this would work interestingly with the civilians psi control issue above if they no longer became enemies after you control them. :-)--[[User:Mal310|Mal310]] 09:23, 22 September 2008 (PDT)&lt;br /&gt;
80 item bug on base defense mission&lt;br /&gt;
:May be hard to pull off. IIRC there is a 170 objects limit in the battlescape, and we must leave some room for the aliens...&lt;br /&gt;
I have noticed that sometimes you can shoot through hard objects, for example, recently I had a soldier up on the roof of a house overlooking a large scout craft. When a Sectiod moved through one of the inner doors of the UFO, my man shot him straight through the intact ufo roof!  &lt;br /&gt;
:I think this is a known issue with LOS, not sure though&lt;br /&gt;
I don’t know if this is already implemented in the game? When the aliens attack your base and you defend it with base defense measures does the following occur and if not a mod maybe? When you hit the battleship with your weapons but it still gets through (e.g. you hit the battleship with some missiles before it lands) can the number of attackers be reduced accordingly. For example if you hit it with some missiles then maybe they could have a couple less soldiers attacking (could be random small amount) or when you hit with loads of stuff like plenty of fusion balls and the battleship just makes it then their attack could be reduced to a few aliens (all others got killed in the defense). As I say not sure if this is already there to some degree (not played in a long time and I’m not at that stage yet this time round). &lt;br /&gt;
:I don&#039;t think this is done already. It may be possible to modify the number of units according to the damage done to the attacking ship, I&#039;ll have to take a look&lt;br /&gt;
This one is way out there. Alien v Alien battles outwith main game, just ramdom battlescape maps. Sectoid and their terrorists against Floters and theirs etc. One side human controlled the other computer . Choice of ships involved etc. &lt;br /&gt;
:Hmm, you do know I don&#039;t have the original source code available, don&#039;t you? :p&lt;br /&gt;
Any plans to work on Terror from the deep? &lt;br /&gt;
:I had a look and reidentifying the specific patch locations is quite tedious, and I&#039;m quite lazy... The loader source is available however, if anyone feels like giving it a shot ;-) [[User:Seb76|Seb76]] 16:38, 19 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
Thanks for the reply. If I get a suitable saved game re the base attack I’ll let you know. Great to hear that a couple of the ideas are on your list already. I have been playing around with the smoke bombs since your fix. I have not noticed any problems, seems to be working fine. --[[User:Mal310|Mal310]] 12:10, 21 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
== Inventory screen ammo weight bug ==&lt;br /&gt;
&lt;br /&gt;
I think there is a small bug. The weight of loaded weapons is not initially calculated. The base weight of the weapon is used but the weight of the ammunition is ignored. However if you reload the weapon in the inventory screen, the correct weight is then calculated. I have seen this repeatedly with AutoCannons. I am using XcomUtil to &#039;remember&#039; the equipment loads - maybe this might be part of the problem? [[User:Spike|Spike]] 09:24, 21 September 2008 (PDT)&lt;br /&gt;
:Yeah, I noticed this one already but flagged it as minor :) I&#039;m using a function that I found in the executable to calculate the weight (the one that&#039;s actually used by the game to see if a soldier is overburdened) so it is an original bug. Anyway, this calls for a fix ;-) [[User:Seb76|Seb76]] 09:47, 21 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Is this the same bug that is present when calculating the throwing range of a loaded weapon? (NKF)&lt;br /&gt;
:Does not ring any bell. Any link?&lt;br /&gt;
&lt;br /&gt;
== Equipment issue ==&lt;br /&gt;
Also, something that I was reminded of while in the rifle vs. laser pistol discussion. It&#039;s not related to the weight bug but it is inventory related: The weird pistol arming bug where sometimes no one arms any pistols, or only one guy will arm one pistol and then fill every available inventory slot with the respective pistol clip. I&#039;m sure it was thrown in so that pistols were always the last to be armed, but is it possible to make the game ignore this and arm the pistol like every other weapon? -[[User:NKF|NKF]] 15:20, 26 September 2008 (PDT)&lt;br /&gt;
:There is a lot of possible work to do with how the soldiers are equiped (equip stuff on shoulders first instead of belt, keep equipment from last battle à la xcomutil, stop having one guy get stuffed up with every ammo available, etc). Since obviously all that is tightly intertwined, it requires some thought before getting into it... Plus this is a part of code that I did not analyse yet ;-) [[User:Seb76|Seb76]] 03:40, 27 September 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
== Request For UFO PS Explosion Offset ==&lt;br /&gt;
&lt;br /&gt;
Hi Seb, in the [[Talk:Explosions#UFO_Power_Source_Explosions|Explosions Talk page]] you mention the following:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;i&amp;gt;Looks like before the first turn, the engine will look for every tile in the map (it scans the MAP.DAT data linearly) ; when it finds a power source (it checks if the MCD special property is set to 2), there is a 25% chance that it will leave it alone. Otherwise, it&#039;ll generate an explosion at the UPS location with a strength of 180+RND*70. Whether the UPS blows up on top of that or is just destroyed, I do not know. Can someone hack the MCD data and see if it&#039;s possible to generate an explosion on a tile that is not a UPS just by messing with the special property? PS: I am almost certain of the 75% probability of explosion vs 70% that is often stated here. [[User:Seb76|Seb76]] 09:31, 12 February 2008 (PST)&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
I&#039;m just wondering where the power source explosion is coded in the executable. If you could tell me that, I&#039;d be able to edit it down so that units don&#039;t take quite so much damage. This is a whole heck of a lot better than editing unit stats to near maxed-out levels as the number of trials needed to find the average would be cut by a few orders of magnitude. Also, if you have an email address where I could contact you directly, it would be appreciated (email me with it). Thanks! --[[User:Zombie|Zombie]] 23:58, 2 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
== Great new features ==&lt;br /&gt;
&lt;br /&gt;
Hi Seb! I just saw you uploaded a version with lots of new features. It was a great idea to add some of the [[Making the Game Harder]] scenarios. I look forward to trying all the new features out (some previous ones I&#039;ve missed as well). Cheers! [[User:Spike|Spike]] 16:37, 19 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
:OK I dusted off my Windows version of XCOM and installed your latest loader. I have to say I love it! The range-based accuracy is great. I use about half the default values, I might try returning them to the default levels as it makes snap&amp;gt;auto for everything above point blank. But it&#039;s definitely working as designed. And I love the %Acc indicators over the target square. Not to mention the (primed) indicator on grenades. &lt;br /&gt;
&lt;br /&gt;
:I played with Alien Pets and Big Brother and View All Locations and found a few strange bugs:&lt;br /&gt;
:* If you use the left and right arrows in the Inventory screen to try to move to a different Alien unit, you only see human units&lt;br /&gt;
:* The character graphic displayed on the Inventory screen is a human, not the appropriate type of Alien&lt;br /&gt;
:* For some reason if you check on turn one the aliens weapons are not loaded and not in their hands. This was in a Roswell scenario, so might be more to do with Roswell. - No, I also got it on my base defence mission. Hang on, silly me, this is just normal for Aliens under mind control isn&#039;t it? &lt;br /&gt;
:* In night missions, even with Big Brother &amp;lt;strike&amp;gt;and View All Locations&amp;lt;/strike&amp;gt; set, I could only see what my guys had illuminated &amp;amp; seen. &lt;br /&gt;
:* View All Locations showed the incoming Battleship before my radars detected it on the half-hour, which gave me a brief chance to prepare my base for attack. Not exactly a bug, more a feature - different. Sadly I wasn&#039;t quick enough so ended up defending with loads of ammo clips and not enough weapons. :)&lt;br /&gt;
::The &amp;quot;Hack&amp;quot; section is really not to be used for gameplay; there I put patches that are useful to test my stuff, nothing more. I only make them available in case it can help someone with her analyse of the game. All the strange things you mention are expected behaviors ;-) [[User:Seb76|Seb76]]&lt;br /&gt;
:* With Alien Bases and View All Locations, the X-COM bases show up as pink.&lt;br /&gt;
:* It wasn&#039;t obvious to me that I needed to set e.g. &amp;quot;Initial Alien Bases=20&amp;quot; rather than just &amp;quot;Initial Alien Bases=1&amp;quot;. I is dumb! [[User:Spike|Spike]] 17:20, 25 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
:Now I need to check the notes on this page to get it working with XComUtil. The one thing that really p____s me off about playing without XComUtil is having to allocate equipment to my guys before every mission. It&#039;s really tedious! Especially as I tend to take 14 guys on each mission. &lt;br /&gt;
:I have not developed Heavy Laser yet, &amp;lt;strike&amp;gt;nor beaten up any aliens in melee,&amp;lt;/strike&amp;gt; but I will let you know how that goes. Thanks for all your amazing work! [[User:Spike|Spike]] 19:00, 23 November 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
:: Awesome. I just completed a mission by my Captain pistol-whipping a Floater Navigator into unconsciousness. How cool is that? But - possible bug - it cost my guy only 8 TUs per attack when he has about 58 total TUs. Is that intended, or is that an error? [[User:Spike|Spike]] 19:38, 23 November 2008 (CST) &#039;&#039;(Later)&#039;&#039; I&#039;m regularly beating up aliens, it&#039;s a giggle. The close quarters combat feels much more authentic now, I love it. &lt;br /&gt;
:::The small TU usage for the pistol is normal (it goes with small stun damage). I liked the idea of having to bash an alien for a while before he falls. Did you not experience reaction fire from the alien? [[User:Seb76|Seb76]]&lt;br /&gt;
::::The TU costs are percentage based instead of fixed(this has been clarified on the main page).  15% of 58 is 8.7 TUs, which truncates to 8.  [[User:Arrow Quivershaft|Arrow Quivershaft]] 14:15, 24 November 2008 (CST)&lt;br /&gt;
: I&#039;m having so much fun and doing so well I got a Base Defence on Superhuman on Jan 12th.  And with the old, sucky starting base layout (hangars take 25 days to move!). I&#039;ve never seen so many Floaters and Reapers at one time. I knew there was a reason to hang on to those Incendiary rounds - bad doggie, down! Loads of fun, however one or two bugs have cropped up:&lt;br /&gt;
::Glad you&#039;re having fun :-) [[User:Seb76|Seb76]]&lt;br /&gt;
&lt;br /&gt;
::* The game crashed as a soldier walked down the stairs from Living Quarters. This is probably a bug in the game and not a bug in your loader. &lt;br /&gt;
: Let me know what details I can give you. [[User:Spike|Spike]] 20:43, 23 November 2008 (CST)&lt;br /&gt;
::Can you provide me with a savegame that reproduces the crash? I think it is the bug that makes defence missions crash around turn 5-6 sometimes (it crashes during the alien turn). I could not reproduce it. [[User:Seb76|Seb76]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Base Disjoint Bug Fix ==&lt;br /&gt;
A Base Disjoint has occurred, despite enabling your Based Disjoint bug fix. &amp;lt;strike&amp;gt;It may be an usual one because it&#039;s not on the bottom nor the right edge of the map (isn&#039;t that where Disjoints are supposed to happen?)&amp;lt;/strike&amp;gt;. It&#039;s the normal, bottom of the map edge kind. Here is a [[Media:BaseDisjointGenStores.ZIP|screenshot]] (anyone got a freeware TGA converter?).&lt;br /&gt;
: Hum, the code was badly f***ed up. Can you retry with the last version? [[User:Seb76|Seb76]]&lt;br /&gt;
&lt;br /&gt;
I downloaded the latest version but unfortunately no effect. It didn&#039;t fix the saved Base Defence scenario. I also restarted from 3 hours before the attack and so created a new Base Defence mission, twice, but no change - still bugged. I&#039;ll post the [[Media:IncomingRetaliation.zip|savegame from 3 hrs before]] in case that helps. [[User:Spike|Spike]] 14:24, 25 November 2008 (CST)&lt;br /&gt;
:Kinda weird, it works here. Maybe I made a faulty delivery... [[User:Seb76|Seb76]] 15:34, 25 November 2008 (CST)&lt;br /&gt;
:Edit: nope, took the patcher from the delivery and it worked. Are you sure you enabled the fix? [[User:Seb76|Seb76]]&lt;br /&gt;
Yes I doubled checked a couple of times. I set the flag as&lt;br /&gt;
&lt;br /&gt;
 Base Disjoint=1&lt;br /&gt;
&lt;br /&gt;
Is that correct? I&#039;ll try again anyway. [[User:Spike|Spike]] 17:20, 25 November 2008 (CST)&lt;br /&gt;
: Oops my fault. I updated the .exe but not the patcher.dll. (I didn&#039;t want to overwrite my UFOExtender.ini - very lazy of me.) Doh!&lt;br /&gt;
&lt;br /&gt;
== A couple of bugs to report ==&lt;br /&gt;
&lt;br /&gt;
Two things so far. With wreck analysis enabled I am getting analysis reports even after raiding alien bases. On one occasion this seemed to have fairly random strings inserted into the variables, resulting in the message &amp;quot;The Alien Food UFO was on an Damage Capacity mission in Power Sources.&amp;quot; All things considered, this is just a cosmetic problem as the actual UFOs are being properly analysed. However, this has got me curious as to what enables you to perform these analyses? It doesn&#039;t happen right from the beginning of the game, at least for me. From the description of the feature I thought maybe it was after researching UFO navigation, but then the messages started popping up before that.&lt;br /&gt;
&lt;br /&gt;
The other bug I have encountered is more severe. After building my first Firestorm I was completely unable to send it out for interception. Clicking on the craft in the list simply returned me to the Geoscape screen without allowing to pick a target, and the game continued to play normally. Disabling the feature for crafts to always be ready despite rearming, repairs and refueling fixed this. [[User:Crowley|Crowley]] 15:52, 3 January 2009 (CST)&lt;br /&gt;
:Been out for a while... I&#039;ll have a look at these two. [[User:Seb76|Seb76]] 11:04, 2 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
Another case of erroneous wreck analysis, this time from an actual UFO: I followed a battleship on an alien base mission and assaulted it when it landed on its own. After the battle the analysis claimed it was on a raiding mission. Perhaps this has something to do with how alien bases are created the moment the battleship appears? [[User:Crowley|Crowley]] 15:52, 3 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
:I use the data from [[MISDATA.DAT]] to get the mission details. Perhaps it is not correctly set at the time I retrieve the information. I&#039;ll investigate further. As for the firestorm problem, do you have a savegame just before the craft is finished so I can reproduce the bug easily? [[User:Seb76|Seb76]] 18:23, 3 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
::Unfortunately not, but I did make a separate save shortly after the craft was finished. I tested it, and turning on the &amp;quot;crafts always ready&amp;quot; option still disables Firestorms with all my saves. With more testing I found out this also affects Lightnings, but not Avengers. [[User:Crowley|Crowley]] 08:36, 4 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
Instead of MISDATA.DAT, maybe grabbing the first byte out of [[LOC.DAT]] might be more accurate? I&#039;m not entirely positive if offset 76 of MISDATA is for just crash sites or all sites in general. BB would know for sure. --[[User:Zombie|Zombie]] 20:25, 3 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
:&amp;quot;Raiding&amp;quot; &#039;&#039;is&#039;&#039; what you&#039;re supposed to get if you&#039;re not lucky enough to get both the mission type &#039;&#039;and&#039;&#039; the zone, as in the .ini file: &amp;lt;pre&amp;gt;Zone Discovered=Intel found out that the %s UFO was raiding %s&amp;lt;/pre&amp;gt;If I remember correctly, difficulty level and the number of recovered navigation modules determine the chance of finding out both pieces of information, so it can&#039;t be Christmas every day ;)&lt;br /&gt;
&lt;br /&gt;
:Regarding the &#039;Craft always ready&#039; option, I had some Interceptors not launching as described by Crowley above but turned out they had 0% fuel, thanks to the [[Known_Bugs#Fuel_dump_on_transfer|transfer bug]] (shuffled them around ages ago to make room for Avengers and forgot about them ;) ). Maybe Crowley&#039;s Firestorms were also transferred around? In any case enabling this option is a bit tricky, if you happen to have craft with the fuel bug sitting around without realising it (or knowing about the bug to begin with); all I can think of right now is to have this option enforce the transfer bug fix &#039;&#039;and&#039;&#039; somehow have buggy craft (0% fuel but ready) update their status to &#039;refuelling&#039;... Wouldn&#039;t be surprised if there&#039;s a global &#039;update interval&#039; in Geoscape when all craft marked as &#039;refuelling&#039; get their fuel level increased; if so, it might be possible to change that status check to use fuel level instead (much like what this option already does, for the selected craft only) [[User:Goran|Goran]] 00:09, 4 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
::Repairing interception craft repair one point of damage capacity per hour (XX:00), refuelling interception craft are granted an amount of fuel each half hour(XX:00 and XX:30) dependent on craft, and rearming interception craft are given an amount of ammo each hour(XX:00) dependent on the weapon being loaded. [[User:Arrow Quivershaft|Arrow Quivershaft]] 05:12, 11 January 2009 (CST)&lt;br /&gt;
:Being busy with work ccurrently so I&#039;ve not much time for the loader. I already use the fuel level instead of the status. I used a value of 30 as a threshold for readyness which is OK for standard fuel ships, but for elerium ships it&#039;s too high: even when fully refuelled, they don&#039;t exceed it. Reducing the value should be enough to fix the problem. [[User:Seb76|Seb76]] 05:22, 11 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
Some more comments:&lt;br /&gt;
# Limited Military = 1 gives you only 1 soldier. OK, I guess it&#039;s meant to do that, but it was not obvious. User error! But maybe it&#039;s time to add &amp;quot;usage&amp;quot; comments to the .INI file?&lt;br /&gt;
# Personnel Overflow works ok, even when the extra personnel are transferred in from another base (instead of being Recruited) - good job!&lt;br /&gt;
[[User:Spike|Spike]] 13:20, 2 January 2009 (CST)&lt;br /&gt;
:What&#039;s wrong with the info from readme.txt? [[User:Seb76|Seb76]] 05:13, 3 January 2009 (CST)&lt;br /&gt;
 *Limited Military: you start with this specified amount of soldiers and cannot recruit any more during the game&lt;br /&gt;
&lt;br /&gt;
:: User Error ^2 - I didn&#039;t read the readme.txt either :) [[User:Spike|Spike]] 12:17, 3 January 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
Errr.... why do Launchers do more stun damage than the Stun Rod? ... Electrocuting someone should do more than just hitting them with a large object? ... for that matter, stun damage of 80 is a LOT... remember that being shot with a rifle does 30, and a grenade does 50. (IMHO, the stun rod is likely to use VERY high voltage... it is much larger than a normal stun gun, and X-com doesn&#039;t mind doing permanent damage to the aliens)&lt;br /&gt;
Here&#039;s a challenge for your coding skills, and a logical one too: make melee do more damage based on Strength stat. My 80 strength goliath should do more damage than my 10 strength rookie wimp... [[User:Jasonred|Jasonred]] [[User:Jasonred|Jasonred]] 18:40, 26 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
== Glitches with Alien Pets ==&lt;br /&gt;
&lt;br /&gt;
OK I know that Alien Pets is a Hack and we should expect side effects. I just want to list them here for information purposes - please do not feel under any obligation to fix them!&lt;br /&gt;
&lt;br /&gt;
* If Alien Pets is set to 1 at the start of a Battlescape mission, Aliens generate with all their equipment in slot 2, i.e. no clips in weapon, no weapon in hand. They remain in this state until they spot a human in their own turn, at which point they lose 19 TUs drawing and loading the weapon. Furthermore, they are incapable of reaction fire until they have seen a human, drawn and loaded their weapon as a result, and survived the experience. From [[Talk:Alien Inventory Use|discussions]] it seems likely that there is a pre-battle routine which moves a weapon from slot 2 on each alien, and arms it, prior to the start of Battlescape turn 1. This routine bypassed - possibly because Alien Pets flags the alien units as human-controlled, and so this &#039;arming&#039; routine ignores those units?&lt;br /&gt;
* It is possible to get to an Inventory screen for large terror units. Normally this is blocked (even when using the Alien Inventory &#039;trick&#039;). This has these effects:&lt;br /&gt;
** Large terror units can pick up and drop items. To pick up, position the topmost/northwest corner of the unit over the item. The Cyberdisc makes a great cargo vehicle!&lt;br /&gt;
** Terror units can also equip weapons in their &amp;quot;hands&amp;quot;. Move the weapon to the left hand slot and it will appear in the Battlescape display. However the weapon can&#039;t actually be used. Using the left weapon will cause the unit&#039;s built-in ranged weapon to be used instead. (But test with Reapers or when the built-in is out of ammo?)&lt;br /&gt;
* I also saw some very weird TU and Weight/Encumbrance behaviour. Aliens at 200% encumbrance, unable to do anything and losing TUs each round. I need to characterise this more clearly. &lt;br /&gt;
&lt;br /&gt;
This might or might not be unrelated (might be due to me using Bomb Bloke&#039;s object editor wrongly):&lt;br /&gt;
&lt;br /&gt;
* When an Alien loads a clip into a weapon and fired it, the ammo count goes negative. This clip (or even single rocket/bomb) then becomes an infinite ammo supply. Probably a signed vs unsigned integer error? &lt;br /&gt;
&lt;br /&gt;
Now regardless of all these minor points, Alien Pets has been very helpful for me doing research on the Alien AI and Inventory handling, so thanks very much for this useful hack!&lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 19:04, 5 March 2009 (CST)&lt;br /&gt;
:My pleasure. It was the very reason I allowed it in the loader in the first place!&lt;br /&gt;
:FYI: the weapons are not handed in a hidden turn but while the aliens are spawned. Also I think reaction fire is completely disabled for the aliens when the hack is activated [[User:Seb76|Seb76]] 13:37, 6 March 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
:: Alien reaction fire works fine for me within Alien Pets. -- [[User:Zaimoni|Zaimoni]] 12:41, August 12 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
I dropped by after three months or so (you&#039;ve inspired me to start an disassembly work on another oldie strategy -&amp;gt;&amp;gt; no time), and I am really astonished, Seb. Behold, incredible work with one of my old wishes, the decreasing accuracy. Fantastic for the gameplay!&lt;br /&gt;
So - ehm - I&#039;ll try to wish for one more, hope you do not mind. There is the last, very (game-wise) frustrating issue: the AI fires a weapon and then sidesteps the alien just out of your view. I am bored to death to make that one step forward and always find the bad guy and shoot him in the back. If you could make this &amp;quot;retreating&amp;quot; a somewhat random thing (random APs, random where to), it would thicken the atmosphere (where he is??) and make the game 10x better. I guess you can&#039;t make them &#039;search cover&#039;, but make them running away RANDOMLY will do the job for me. I&#039;ll be very thankful to you. --[[User:Kyrub|Kyrub]] 20:26, 1 April 2009 (EDT)&lt;br /&gt;
:Thanks for the support, I&#039;m bored of the &amp;quot;the stuff does not work with ET&amp;quot; thing ;-) I can have a look but the alien AI is one of the points I&#039;m clueless about, I don&#039;t really know what to look for. When I study the parts that interact with ROUTE.DAT data, I cannot figure what the hell is going on... Do you know if the backing alien has ran out of TUs? Maybe the game tries to keep some for reaction fire but no-one realized that turning your back on danger is not the best tactic for reaction shots ^_^ [[User:Seb76|Seb76]] 15:46, 2 April 2009 (EDT)&lt;br /&gt;
::The situation happens always a) in the open b) during the alien turn c) when the enemy spots you, fires and then retreats out of view. I think he even turns back to face you sometimes, but not sure. But the main (gameplay) problem is that you are totally safe to advance 1 step and shoot because you have full TUs, no reaction fire, no support from other aliens. Perhaps the program determines the quadrant with human, via substracting the positions and finding the angle with a pre-made table in the exe (I have the same thing in my disassembling game)? Or it just loops next fields until it finds the one without eye-contact? -- I am almost sure that this was repaired in the Ufo Tftd. The aliens are very nasty and retreat totally out of view... -- BTW, the aliens do well in the vessels in UFO-eu, they search cover in the next room!--[[User:Kyrub|Kyrub]] 16:22, 2 April 2009 (EDT)&lt;br /&gt;
:Hum, too bad I never got to disassemble TFTD then ;-) BTW, which game do you work on? [[User:Seb76|Seb76]] 17:22, 2 April 2009 (EDT)&lt;br /&gt;
::Master of Orion I, correcting the bugs and improving AI. (Hey, noticed the doors&#039; thing. Another great one.) --[[User:Kyrub|Kyrub]] 20:09, 2 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== TFTD Door problem ==&lt;br /&gt;
&lt;br /&gt;
Seb, there seems to be a problem using the TFTD Doors with the Proximity Mine bug fix. I do have several other patches to my game, and it is possible that they are complicating the matter, but simply by turning off the PM fix I can suddenly open doors again. --[[User:Talon81|Talon81]] 06:02, 14 April 2009 (EDT)&lt;br /&gt;
:Hi Talon81, what do you mean by &amp;quot;other patches&amp;quot;. Are you using ET or xcomutils? Or are you just enabling other patches from the loader? Also what are the symptoms exactly. Can&#039;t you open any door? [[User:Seb76|Seb76]] 14:24, 6 April 2009 (EDT)&lt;br /&gt;
:Edit: Nevermind, I could reproduce the problem. Can you try the new version I just uploaded? [[User:Seb76|Seb76]] 15:08, 6 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Yeah, I tried it, and it works fine. As you no doubt have already figured out, it wasnt working on any kind of door, as far as I could determine. The other things I am using should not interfere. They are minor patches such as Zombie&#039;s combo patch for terrain, etc, CE to DOS sound editor, and the aimed accuracy adjustment patch. I am not using Xcomutil or ET (would like to use ET, but I know that it doesnt work well with your patch).&lt;br /&gt;
&lt;br /&gt;
If it means anything to you, I would like to say that your work has meant a LOT towards making this game what it should have been. I fell in love with this game in 94, and never have more than a couple years gone by without me playing it. Your patch is the best thing to come along since it was made. ;-)&lt;br /&gt;
--[[User:Talon81|Talon81]] 06:02, 14 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
: I second that, wholeheartedly. [[User:Spike|Spike]] 16:44, 14 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:Thanks guys! This game is the best and I try not to divert it from its spirit with my patches... Actually the fix for the doors *might* increase compatibility with ET, but it&#039;s a wild guess. [[User:Seb76|Seb76]] 16:56, 18 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Initial Alien Bases ==&lt;br /&gt;
&lt;br /&gt;
OK, so I was having some problems getting alien bases to work, so I created a new folder of X-Com with nothing but your video patch on, and alien bases. I am still having the same problems I was having on my more heavily patched version. For example, I created one with 3 alien bases. Looks fine. I run it with the show all locations patch and sure enough, no alien bases. I make a new game with the show all patch on and there are the alien bases, shown until the point that I place my own base. Then they disappear and my base now looks like an alien base. There are some other minor bugs associated, too; however, that seems to be the main problem. In short, I have yet to get an alien base to survive past the placement of my base. I thought it could be a glitch in the show all patch, but scouting the areas where the alien bases were shown prior to base placement has returned nothing. --[[User:Talon81|Talon81]] 15:23, 19 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
By the way, Seb, are you the same as Strife67? --[[User:Talon81|Talon81]] 13:13, 24 April 2009 (EDT)&lt;br /&gt;
:Nope, never heard of that guy. What&#039;s he doing? [[User:Seb76|Seb76]] 15:13, 24 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Nothing anymore. He created a sound patch a year ago or so, and there were some things he said that reminded me of you, not to mention in my head I was thinking you were Seb67 instead of Seb76. I just now noticed my mistake. --[[User:Talon81|Talon81]] 20:16, 24 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:OK, I uploaded a new version. Can you confirm it fixes the problem on your rig? [[User:Seb76|Seb76]] 07:57, 26 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Seems to have solved the problem to me. The alien bases now appear after placement of mine instead of before like they previously did. X-Com bases are correctly shown, as well. --[[User:Talon81|Talon81]] 13:34, 28 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Won&#039;t work on my rig Vista+CE version ==&lt;br /&gt;
&lt;br /&gt;
Nice work! I really want to play this, it&#039;s not working on my PC though. I may be stuck with the Dos version in Dosbox forever.&lt;br /&gt;
&lt;br /&gt;
My screen flashes between the squashed look of the unpatched EXE and the OK version. On screens without animation it changes back and forth as I move the mouse. On the Geoscape it just flashes and gives me a headache. Sorry about the big images, to lazy to cut them down.&lt;br /&gt;
&lt;br /&gt;
* http://darksun.lunarpages.com/XCOM/Scrambled%20P1010264.JPG&lt;br /&gt;
* http://darksun.lunarpages.com/XCOM/Fine%20P1010265.JPG&lt;br /&gt;
--[[User:SaintD|SaintD]] 19:09, 19 April 2009 (EDT)&lt;br /&gt;
:Hum, looks like another Vista problem... Do you have the problem when using [http://appaholic.co.uk/2007/10/16/dxwnd-force-almost-anything-into-a-windowed-mode/ DXWnd]? I use the following settings (but I&#039;m under XP...):&lt;br /&gt;
&lt;br /&gt;
[[Image:Dxwnd.png]]&lt;br /&gt;
&lt;br /&gt;
[[User:Seb76|Seb76]] 14:57, 20 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Awesome. That worked. My 1440x900 regular resolution means that the window is really tiny though. You should really get the upscaler working now. Heheh. Dxwnd makes Internet Explorer crash on vista. Does that happen to you?&lt;br /&gt;
&lt;br /&gt;
http://darksun.lunarpages.com/XCOM/xcomWindowed.png --[[User:SaintD|SaintD]] 00:34, 21 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
[edit] I didn&#039;t realize you can just drag the Dxwnd window bigger. I still miss the advinterp3x from dosbox.&lt;br /&gt;
&lt;br /&gt;
:I dunno exactly how DXWnd works but I think it may screw up aero stuff... I played with scale2x a bit and got that but it only works with DXWnd:&lt;br /&gt;
:[[Image:Scale2x.png]]&lt;br /&gt;
&lt;br /&gt;
:When I try fullscreen, it looks like DirectX won&#039;t allow me to go to 640x400 resolution :( Any DX guru out there? [[User:Seb76|Seb76]] 14:36, 21 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
::Can I get a copy of the new version? :) I can only use Dxwnd anyway. If you can boil the problem down I might be able to get some Direct X help. I know a couple guys who have been playing with XNA a lot. Can you create a stand alone sample program to illustrate your issue maybe?&lt;br /&gt;
:I uploaded this: [[Image:UFOExtender-dev.zip]]. It works only in window mode on my laptop, maybe you can give it a try? You&#039;ll most likely have to alt-tab out of the black screen though... [[User:Seb76|Seb76]] 11:08, 26 April 2009 (EDT)&lt;br /&gt;
:Edit: version updated with support for HQ4x (in 1280x800). Feedback appreciated... [[User:Seb76|Seb76]] 09:55, 3 May 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
The above version works perfectly on my PC but only through DXWmd. I&#039;d also like to note that using DXWnd eliminates fast speed issues in Battlescape for some reason. I&#039;m really excited Seb is pulling this off. &amp;lt;3&lt;br /&gt;
:Uploaded a new version, you need to add a &amp;quot;HQ4x=1&amp;quot; line under the &amp;quot;Mod&amp;quot; section to enable it. [[User:Seb76|Seb76]] 15:36, 6 May 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Works perfect without the use of DXWnd, but there&#039;s some sort of frameskip feeling. Great work, this is getting better and better. :-)&lt;br /&gt;
&lt;br /&gt;
Now the question is, how do you use DXWnd with the loader?&lt;br /&gt;
[[User:KingMob4313|KingMob4313]] 11:02, 12 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
==Works but won&#039;t multitask==&lt;br /&gt;
&lt;br /&gt;
Target system: prefab HP Vista with global data execution prevention.  Problem is the same native, with D3D, and/or with HQ4X.  (The two do combine nicely, visually, but a bit laggy for my tastes).&lt;br /&gt;
&lt;br /&gt;
ALT-TAB terminates all further screen display on restore; the sea of blackness continues until Task Manager is used to kill the application, at which point D3D admits that it has &amp;quot;lost the device&amp;quot;.  (This is after the improved error reporting patch.  Before, 0xc0000005 as Data Execution Prevention takes over.)&lt;br /&gt;
&lt;br /&gt;
-- [[User:Zaimoni|Zaimoni]] 12:27, 12 August 2009 (CDT)&lt;br /&gt;
&lt;br /&gt;
==Heavy laser mod==&lt;br /&gt;
My heavy laser only has the two new firing modes. Also, when I fire, the beams don&#039;t go where I point. They seem to be grouped correctly, just off in the wrong direction. [[User:SaintD:SaintD]]&lt;br /&gt;
&lt;br /&gt;
:Yeah, it is a problem when you enable range based accuracy at the same time. I&#039;ll try to fix that when I get some time... [[User:Seb76|Seb76]] 14:25, 23 April 2009 (EDT)&lt;br /&gt;
:Made a new version. Can you try it and let me know if the problem is gone? [[User:Seb76|Seb76]] 09:19, 26 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
::I tried it. The new modes now work, but Snap Mode is still missing from my HL. Also it&#039;s not clear the difference between burst and full auto since they both have the same accuracy and TU cost.--[[User:SaintD|SaintD]] 19:25, 29 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
::: Hmmm, on mine the burst and full auto have different accuracies (80% and 60%, respectively); and they fire 5 and 8 rounds, also respectively. I believe the snap shot was taken out on purpose to coincide with the idea of the heavy laser as being more suited to being a support weapon. Of course the last part is conjecture on my part, but I am pretty certain it is not supposed to be there. --[[User:Talon81|Talon81]] 23:51, 29 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
I am not the original poster in this heading, and I have not had the same problems with the heavy laser that others had (only one I had was about the Range Based Acc not affecting full auto), so I cannot confirm whether this patch has solved that. But I will tell you what you probably already know: everything is fuzzy, kinda like [ Mok&#039;s 2xSaI]. It is also a little bit jumpy. Due to that, I can&#039;t take advantage of the Funky Fire fix, or any other future fix, unless I am willing to deal with the fuzziness, or unless you create 2 runs; 1 with the Heavy Laser fix, and one without. --[[User:Talon81|Talon81]] 13:42, 28 April 2009 (EDT)&lt;br /&gt;
:Hum, I&#039;m not sure I understand. What has the fuzziness to do with the HL fix? [[User:Seb76|Seb76]] 14:15, 28 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Wow, to think I almost didnt bother to post because I was sure you would already be aware of it. As soon as I updated your loader from 6 April (TFTD door fix) to 26 April (funky fire fix), everything got fuzzy. After that, I tried the update without funky fire (HL fix). Still fuzzy. Then I rolled back to the previous one (Initial Alien Base fix). No more fuzzy. I even went back to HL fix, then back again to Alien Base fix. Same deal. I will try using it on a fresh X-Com install without my other patches. But yeah, you should seriously install the patch I linked to in my above post. Will only take a minute to try. Looks VERY much like it (I know that many people have the fuzzy problem with that patch). --[[User:Talon81|Talon81]] 02:17, 29 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
OK, it is indeed still fuzzy on a fresher copy of X-Com. It is not a genuine fresh install as I no longer have the disk, it is just the original files copied on my computer in another location. Furthermore, I forgot to mention there is also slight video garble (yes, even with the garble fix on) at the bottom of the menu screens. That in itself is not a problem as it is not throughout the game, and is only a few pixels in height. I can&#039;t wait to see if anyone else has these problems or if its just me. --[[User:Talon81|Talon81]] 02:27, 29 April 2009 (EDT)&lt;br /&gt;
:I have a crash with Mok&#039;s patch so I cannot check the problem. By fuzzy you mean something like the image is bilinearly filtered and all smoothed? [[User:Seb76|Seb76]] 17:20, 29 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
I am a total programming/graphics newb, so I don&#039;t know if that is a good description or not. The UFO&#039;s for example, instead of being crosses, are blurbs that slightly change shape as they fly, and everything has softer transitions that make it look like it is done with pastels or something. I can tell you I tried to take a screen capture but it did not reflect the screen as it appears in game. In any case, unless other people have this same problem, I would not worry about it for my sake. If it is something you want to tackle anyway, just tell me what I can do to help you. --[[User:Talon81|Talon81]] 23:51, 29 April 2009 (EDT)&lt;br /&gt;
:Hum, are youe using the &amp;quot;dev&amp;quot; version instead of the official one? It features a scale2x filter that craps the image up.[[User:Seb76|Seb76]] 14:40, 30 April 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Not sure what you mean by &amp;quot;dev&amp;quot; version, but I am guessing you are referring to my version of CE. I do not know for sure, because it has been years since I got it, but I am guessing the answer is yes because mine runs in full screen without any mods. --[[User:Talon81|Talon81]] 12:22, 1 May 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Your newest version seems to have gotten rid of my problem. --[[User:Talon81|Talon81]] 12:32, 1 May 2009 (EDT)&lt;br /&gt;
:That&#039;s great ;-) By dev I was refering to the &amp;quot;dev&amp;quot; version of the loader linked on this page. It is an experimental version that uses scale2x with 640x400 resolution. [[User:Seb76|Seb76]] 12:53, 1 May 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== REng UFO with IDA ==&lt;br /&gt;
&lt;br /&gt;
Hi Seb =)&lt;br /&gt;
&lt;br /&gt;
I&#039;ve just started working with IDA in an attempt to understand the inner workings of TACTICAL.EXE. I have never used IDA or related tools before, nor do I really know what I&#039;m doing ;) I have removed the DOS/4GW loader and am examining the LE code currently.&lt;br /&gt;
&lt;br /&gt;
So far my only progress (using DOSBox debugger) has been to isolate the calls in main() which display the equip screen and handle the interative section of the mission. You could say progress has been slow, as this has taken a couple days (including time spent figuring out the basics of IDA/DOSbox debug).&lt;br /&gt;
&lt;br /&gt;
Would it be possible to see your notes? You will no doubt have discovered most (all?) functions and exactly what they do. If I could see this data (such as comments, renamed funtions, cleaned up code) it would take months off of the time I would need to understand the underlying assembler code.&lt;br /&gt;
&lt;br /&gt;
I also recently discovered a plugin called HexRays for IDA. Do you use this? I&#039;m really a newb so would love to get some input on which tools are best for this job.&lt;br /&gt;
&lt;br /&gt;
My long, long-term goal will be to implement TACTICAL as a native windows program, as it would be a great project to have whilst learning to program (I should say I have some basic programming already, but nothing beyond a simple Windows game in Delphi).&lt;br /&gt;
&lt;br /&gt;
Any advice is deeply appreciated mate =)&lt;br /&gt;
&lt;br /&gt;
XCom forever!&lt;br /&gt;
--[[User:K9wazere|K9wazere]] 09:51, 17 June 2009 (EDT)&lt;br /&gt;
:Hi k9,&lt;br /&gt;
:Slow progress at the start is a normal thing. In the windows version I got help from the developers because they left a few error messages around to guide me during my initial analysis ^_^ I don&#039;t know about the DOS version, maybe they are also present.&lt;br /&gt;
:For the DB, just PM me an email address where I can send you the file (~1.7MB)... I gave a shot at HexRays (early versions), but I didn&#039;t find it that much useful in helping to understand what&#039;s going on. Well, if you&#039;re not used to asm, it may be interesting for you ;-) Still, for re-engineering a function it may prove useful. All in all, I&#039;m just using a standard 5.2.0.908 version, it got everything I need. Also for debugging, I use DXWnd because breakpoints and fullscreen DX apps don&#039;t live well together...&lt;br /&gt;
:Good luck with your project,&lt;br /&gt;
:[[User:Seb76|Seb76]] 14:15, 17 June 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:::Thanks for that, Seb! I&#039;m trying to understand how your loader and patcher works...&lt;br /&gt;
&lt;br /&gt;
 void InsertCall(int dst, void *func)&lt;br /&gt;
 {&lt;br /&gt;
 	DWORD oldProtect;&lt;br /&gt;
 	DWORD *pOffset=(DWORD *)(((char *)dst)+1);&lt;br /&gt;
 &lt;br /&gt;
 	VirtualProtect((void *)dst,5,PAGE_EXECUTE_READWRITE,&amp;amp;oldProtect);&lt;br /&gt;
 	*(char *)dst=(char)0xE8;&lt;br /&gt;
 	*pOffset=(int)func-(int)dst-5;&lt;br /&gt;
 	VirtualProtect((void *)dst,5,oldProtect,&amp;amp;oldProtect);&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
::: This calculation here is interesting:&lt;br /&gt;
&lt;br /&gt;
 *pOffset=(int)func-(int)dst-5;&lt;br /&gt;
&lt;br /&gt;
:::I assume 0xEA is assembler for CALL ... but then the reason for subtracting &#039;dst&#039; from &#039;func&#039; is not apparent. All in all I&#039;m a bit confused as to how code in one area of memory (UFO Defense) can call code in another area of memory, belong to a different process (UFO Loader).&lt;br /&gt;
:The 0xEA is indeed the CALL opcode, but it is a relative jump so you must feed it the delta between source and destination (the 5 is the size of the CALL instruction itself that must be removed).&lt;br /&gt;
:The beauty of the thing is that the loader injects the code in the address space of the main executable image so you can call functions from/to it with no trouble :)&lt;br /&gt;
&lt;br /&gt;
:::Can you suggest some good reading material to better understand this? Cheers!&lt;br /&gt;
:::--[[User:K9wazere|K9wazere]] 14:36, 20 June 2009 (EDT)&lt;br /&gt;
:You can search for DLL injection methods on the web, that&#039;s the name of the trick. In a nutshell I spawn the &amp;quot;UFO Defense&amp;quot; process in a suspended state, then use the CreateRemoteThread/LoadLibrary trick. HTH, [[User:Seb76|Seb76]] 14:48, 21 June 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== D3D ==&lt;br /&gt;
&lt;br /&gt;
If I select the D3D option, UFO Defense and patcher.dll crash and generate a Windows Error Report. It won&#039;t let me copy and paste the contents unfortunately. My XCom machine is an old laptop, Win XP Pro 2003, Pentium III 851MHz, 376Mb RAM. I&#039;m not sure what version (if any) of DirectX it has. &lt;br /&gt;
&lt;br /&gt;
I&#039;m still checking out the Save Equipment / Auto Flares mods. Very welcome! Once these are working there will be no reason for most people to use XComUtil. I will get back to you when I have specific feedback - but thanks again, Seb. [[User:Spike|Spike]] 12:59, 18 July 2009 (EDT)&lt;br /&gt;
:You need DirectX 9 installed (couldn&#039;t easily locate any older SDK, I&#039;m sure I could&#039;ve gotten away with DX7...), maybe I should make the code more robust and exit gracefully instead of crashing... [[User:Seb76|Seb76]] 13:04, 18 July 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Hmm. I&#039;ve installed DirectX version 9 (March 2009 version) and with D3D enabled the Loader just fails silently; no error message, nothing in the event log. Maybe the install didn&#039;t work properly. I&#039;ll see if I can find some kind of DirectX test/verification utility somewhere. [[User:Spike|Spike]] 21:23, 19 July 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
OK I ran the &amp;lt;b&amp;gt;dxdiag&amp;lt;/b&amp;gt; utility which comes with DirectX 9.0c. This tests DirectDraw and Direct3D levels 7/8/9. There were no problems and no issues detected, apart from my laptop does not support hardware sound buffering (software only). I can send you the full dxdiag.txt report if it will help. When the Loader fails, all I see is a little black square in the top left, which I think is a normal part of the loading sequence (some kind of command window), and then nothing. [[User:Spike|Spike]] 21:39, 19 July 2009 (EDT)&lt;br /&gt;
:Might be related to using none power of two textures. Maybe your hardware does not support it? I&#039;ll add some more checks to make sure that&#039;s the problem.&lt;br /&gt;
:Edit: Can you try the latest version? I added some more error handling, can you tell me if you have an error message at some point? [[User:Seb76|Seb76]] 19:18, 20 July 2009 (EDT)&lt;br /&gt;
Unforunately I don&#039;t have access to the original laptop now, I won&#039;t do for a few months. I have tried on another PC (XP 2002 Professional SP3, DirectX9.0c, dxdiag tests all ok) and I also get a crash. Instead of dropping out right away, I see the smallish black square in the top left for a while, then I go to a full screen black or grey-black screen. This lasts for minutes. It doesn&#039;t eat up CPU and I can task switch out of it. I don&#039;t see any popup error messages and nothing in the event logs. When I kill UFO Defense the black full screen goes away. Sorry I know that&#039;s not much help. [[User:Spike|Spike]] 17:59, 22 July 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
D3D mode isn&#039;t working for me either, I simply get a black screen. When I alt+tab out of it though I can see an error box titled &#039;D3D error&#039; which tells me it &#039;Cannot create texture&#039;. [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 19:09, 8 August 2009 (EDT)&lt;br /&gt;
:edit: forgot to mention, I have directx 9.0c installed and dxdiag reports no problems. I have a Geforce2 MX *blushes*&lt;br /&gt;
:Do you know if this card supports non power of two textures? [[User:Seb76|Seb76]] 05:10, 9 August 2009 (EDT)&lt;br /&gt;
::no idea, but since your new version works fine with the D3D option on I assume it doesn&#039;t :) [[User:J&#039;ordos|J&amp;amp;#39;ordos]] 11:38, 9 August 2009 (EDT)&lt;br /&gt;
:That&#039;s great. Spike, does it fix your problems too? [[User:Seb76|Seb76]] 16:04, 9 August 2009 (EDT)&lt;br /&gt;
::Sorry for the late reply - yes that fixes my problems too, D3D is working fine now. Thanks, [[User:Spike|Spike]] 15:55, 26 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Save equipment ==&lt;br /&gt;
&lt;br /&gt;
Hi Seb. I&#039;ve tried out the Save Equipment and Auto Flares (good idea by the way). I&#039;ve seen some quirks. I had a few weapons (a Rifle and maybe a Pistol) that weren&#039;t loaded. Normally the game loads all weapons unless there isn&#039;t sufficient ammo. I moved some stuff around so this might have been due to me. So I restarted. Then I got a situation where:&lt;br /&gt;
&lt;br /&gt;
*1 soldier had no weapons, just a grenade in a belt, even though there were Rifles and Auto Cannon (both with ammo) not allocated. Actually this soldier was showing 54/40 encumbrance from one grenade. Carrying a lot of &amp;quot;invisible&amp;quot; equipment!&lt;br /&gt;
*Heavy weapons (Auto Cannon, Heavy Cannon, Rocket Launcher) were allocated only once each. Spare heavy weapons were not allocated. The soldiers allocated the heavy weapons carried 3 spare ammo clips and were overloaded. Also, a weak soldier (strength 21 or so) was selected to carry the Auto Cannon and 3 spare clips. &lt;br /&gt;
*The mission appeared to be a night mission but no flares were allocated. (the previous mission, the Auto Flares worked fine). Maybe it was a Dusk mission? It looked dark out there.&lt;br /&gt;
*Also the game crashed when I moved the first guy out of the transport. Of course this is not necessarily related to using Save Equipment. &lt;br /&gt;
&lt;br /&gt;
Actually, making sensible automatic rules for weapon and ammo allocation is hard to do, and a matter of personal taste, and this is really a different goal than just saving equipment allocations that have been picked manually by the player. So I&#039;m probably being really unfair. Maybe it would be easier not to allocate any weapons other than what the player has picked? &lt;br /&gt;
&lt;br /&gt;
Anyway I have a save game file for the 2nd game if that is any use to you for debugging. Cheers, [[User:Spike|Spike]] 18:53, 18 July 2009 (EDT)&lt;br /&gt;
:Thanks for the feedback, it got in the dev version for 2 months and nobody sent any comment so I figured I might as well put it in the official version ;-) I&#039;m not surprised with the kind of problems you encountered, I got lots of &#039;em while making this... The crash at the start is most likely due to reaction fire.&lt;br /&gt;
:The autoflare feature should trigger at the same time as the visibility reduction caused by the night. Were you able to see up to 20 tiles away?&lt;br /&gt;
:As for the auto-allocation, I&#039;m afraid there is no other easy option that I can see: when the mission starts, everybody is already equiped with the default stuff. I have to remove everything to be able to reassign items properly :( The default reequiping rules are quite simple: strength is not taken into account, and you require a set amount of free clips to be able to equip a weapon.&lt;br /&gt;
:I had a look at your savegame, but one just before the mission would be better. Also can you attach your ini file? Maybe some problems are caused by incompatibilities between mods. [[User:Seb76|Seb76]] 04:08, 19 July 2009 (EDT)&lt;br /&gt;
::OK uploaded what I hope is the right .ini file. Unfortunately that was my first savefile of the game, I don&#039;t have any earlier one. All I did was bought some guns &#039;n ammo and landed on the first (Roswell) crash site. The weirdest thing was the female soldier (Martha Stewart? or am I hallucinating?) with 54/40 encumbrance but only carrying one grenade. Could this be connected to [[Known_Bugs#Weightless_Loaded_Ammo|the problem you discovered in the game&#039;s weight routine]]? Anyway I will try and recreate the problem with more savefiles so you have a &amp;quot;before&amp;quot; and &amp;quot;after&amp;quot;. [[User:Spike|Spike]] 07:15, 19 July 2009 (EDT)&lt;br /&gt;
:In your savegame I indeed see that the Maria chick is overweight, but if I bail out of the mission and go on a new one, she only have a grenade and a weight of 3... Another strange thing is that in the equip.ini file of the savegame, she&#039;s marked as having a large rocket loaded in the weapon that she&#039;s holding, but she has no weapon... Did you equip her with the rocket launcher and changed your mind afterward? [[User:Seb76|Seb76]] 11:27, 19 July 2009 (EDT)&lt;br /&gt;
::OK I restarted from a new game. I took lots of savegames after each step. Everyone has your default basic loadouts - loaded pistol or rifle, one reload, one grenade. I see a couple of anomalies. Look for Jacques. He is overweight despite only carrying a Rifle. Also, he is carrying a grenade that shows as Primed - it isn&#039;t. I even threw it to make sure - no explosion. Like Maria before him, Jacques is the last soldier in the equip.ini list. Also like Maria, Jacques is carrying more guns &amp;amp; ammo in equip.ini than are shown in the inventory screen. He has 5 items but they don&#039;t add up to the 54 or so Encumbrance he is showing. Like Maria, he is carrying ammo (type 13) in a slot1 (left hand) weapon that doesn&#039;t exist, and it seems to weigh about 20! The crazy encumbrance persists into the next turn and it is still there after I restore a savegame. I will upload a full set of play-by-play savegame files. I did move some equipment around for some guys in the later saves. But never for Jacques. [[User:Spike|Spike]] 21:10, 19 July 2009 (EDT)&lt;br /&gt;
:OK, I&#039;ll have a look at this, thanks for the effort.&lt;br /&gt;
:Edit: I could not reproduce the problem staight away: I see the crapped up weight if I load your tactical games, but when using the &amp;quot;i/b&amp;quot; one, Jacques is alright... Does this problem happens 100%  of the time on your PC? Maybe it&#039;s a problem with the ini file handling (W2K3?), who knows... I&#039;ll keep trying. Feedback from XP/Vista users could be useful on this one. BTW are you using split binaries? [[User:Seb76|Seb76]] 15:44, 20 July 2009 (EDT)&lt;br /&gt;
::I&#039;ve uploaded another save game, this time on a different PC (better XP version, CPU, RAM). Same symptoms - the last man has phantom equipment. Actually I notice the last TWO men have 2 items of equipment on them, but only visible one item shown in equip.ini. Also I keep forgetting to send the UFO Extender.ini file. My games don&#039;t use split binaries. I don&#039;t think it&#039;s a problem parsing the equip.ini file because the problem appears right away, if I save as my first action when the battlescape appears - the equip.ini already has the weirdness, and on the battlescape the soldier already has the weirdness. Although - let me check this - but I don&#039;t think the phantom equipment weirdness is there during the Equip Screen, it only appears when the actual Battlescape starts. So, if you pass the equipment information from the Equip screen to the Battlescape via the equip.ini file, that&#039;s a possibility. [[User:Spike|Spike]] 17:21, 20 July 2009 (EDT)&lt;br /&gt;
::Uploaded another New game, same/similar symptoms. This time the last guy is carrying weapons. But still, he is too heavy. The effect is NOT present in Equip Screen; his weight only increases once on the Battlescape. He is carrying a Rocket (object type 13) inside an invisible second weapon. So this could be a problem parsing the equip.ini file. [[User:Spike|Spike]] 17:38, 20 July 2009 (EDT)&lt;br /&gt;
::Last note tonight. The guy is overweight by 13 x 2 = 26  units. His equip.ini shows him carrying a phantom type 13 object (in a nonexistent 2nd weapon). Is this a coincidence? Maybe check the other savefiles and see if the last man was also overweight by 26 units, or by 2 x the index of the phantom item. [[User:Spike|Spike]] 18:00, 20 July 2009 (EDT)&lt;br /&gt;
:I uploaded a new version, can you check it out? [[User:Seb76|Seb76]] 19:16, 20 July 2009 (EDT)&lt;br /&gt;
:: Re tried with New game after your fix. Still seeing last 2 characters with incorrect weights. The weights were the same on the Equip screen as on the Battlescape. Excess weights are 6 and 3 units. Uploaded the save game. [[User:Spike|Spike]] 14:14, 21 July 2009 (EDT)&lt;br /&gt;
:Actually you&#039;re now hitting another bug: when putting a loaded gun to the floor, the ammo stays assigned to the soldier so its weight is still taken into account... [[User:Seb76|Seb76]] 15:21, 21 July 2009 (EDT)&lt;br /&gt;
::Yes you are right. In fact the weight errors were not 6 and 3 but 6 and 5 - the weight of heavy cannon ammo and auto cannon ammo, respectively. When I dropped the loaded heavy cannon and the loaded auto cannon, the encumbrance weights drop by 18 and 19 respectively. This is the weight of the unloaded weapon, not the correct weight of the loaded weapon. (Though normally, due to the buggy weight routine in the game, that *is* the actual (but incorrect) weight of the loaded weapon if you haven&#039;t yet unloaded it). So this is just a matter of ignoring the ammo weight from the soldier&#039;s encumbrance when dropping a loaded weapon. And it does look like the original problem has been fixed. [[User:Spike|Spike]] 18:18, 22 July 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Hmm more problems with Save Equipment. Ammo of all types seems to disappear. Eg I have 6 pistols and 6 pistol clips on the craft, but the Equip screen just gives me 6 empty pistols. Other weapons are short of ammo too. Is the Save feature perhaps &amp;quot;remembering&amp;quot; empty weapons (or loaded weapons) and somehow eliminating the clips. [[User:Spike|Spike]] 20:34, 18 August 2009 (EDT)&lt;br /&gt;
:This looks like an issue with &#039;&#039;UnloadClips&#039;&#039;(). I noticed that the clip object&#039;s &#039;&#039;loaded_into&#039;&#039; is set to 0xff, but the &#039;&#039;not_loaded&#039;&#039; remains as 0. The game may see this as the clip still being loaded in an object, so the clip effectively disappears. --[[User:Mikawo|Mikawo]] 11:05, 19 August 2009 (EDT)&lt;br /&gt;
::This is possible. The wiki is wrong on these 2 fields BTW: it is in fact just one field (loaded_into signed extended to 16bit). I&#039;ll have a look at that. [[User:Seb76|Seb76]] 14:33, 19 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
I think Mikawo is right. UnloadClips() should look something like this:&lt;br /&gt;
&lt;br /&gt;
 void UnloadClips()&lt;br /&gt;
 {&lt;br /&gt;
 	obpos_dat *pObPos=pObpos_dat;&lt;br /&gt;
 &lt;br /&gt;
 	for(unsigned char i=0;i&amp;lt;170;i++)&lt;br /&gt;
 	{&lt;br /&gt;
 		if(pObPos-&amp;gt;itemType != 0xff &amp;amp;&amp;amp; pObPos-&amp;gt;not_loaded == 0  &amp;amp;&amp;amp; IsXComItem(i))&lt;br /&gt;
 		{&lt;br /&gt;
 			pObPos-&amp;gt;loaded_into=0xff;&lt;br /&gt;
 			&amp;lt;big&amp;gt;&#039;&#039;&#039;pObPos-&amp;gt;not_loaded=0xff;&#039;&#039;&#039;&amp;lt;/big&amp;gt;&lt;br /&gt;
 		}&lt;br /&gt;
 		pObPos++;&lt;br /&gt;
  	}&lt;br /&gt;
 } &lt;br /&gt;
 &lt;br /&gt;
Quite a few other functions in &#039;&#039;&#039;equipment.cpp&#039;&#039;&#039; use this check &#039;&#039;&#039;pObPos-&amp;gt;not_loaded == 0xff&#039;&#039;&#039; so it is important to set this flag just for UFOExtender, regardless of whether the game needs it set (which it probably does). Eg items unloaded by UnloadClips will thereafter fail to be found by GetFreeItem, during execution of LoadSoldierEquipment. That probably explains the problems observed.&lt;br /&gt;
[[User:Spike|Spike]] 15:24, 26 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:I did some rework based on that. Do you have other problems? [[User:Seb76|Seb76]] 16:08, 30 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
::Thanks Seb. This seems to be working mostly ok now. Some remaining smaller issues I have seen:&lt;br /&gt;
&lt;br /&gt;
::* The weight calculation is so accurate, it is more accurate than the unmodified game. So the &amp;quot;weight free ammo&amp;quot; (the first clip loaded into a weapon, before the user takes any action in the Equip screen) is no longer weight free. Not sure if you want to &amp;quot;fix&amp;quot; this or not? It is debatable. Really, you have fixed a bug. But the normal game behaviour has changed. Maybe make the &amp;quot;weight free ammo&amp;quot; optional?&lt;br /&gt;
::* There is a weird glitch. If I unload a weapon, put it and the clip on the ground seperately, that works fine. But if I pick up the clip &#039;&#039;&#039;directly from the ground&#039;&#039;&#039; and load it straight into the weapon, then drop the weapon, the weight of the clip is still shown on the soldier. And actually the same thing happens with a clip that is first moved into the soldier&#039;s equipment. So in fact the problem is that a clip loaded into a weapon, doesn&#039;t get removed from the soldier weight when the weapon is dropped onto the ground. It happens even if the clip is pre-loaded by your routine.&lt;br /&gt;
::* Still outstanding - you can&#039;t use the right arrow to move onto a second screen of equipment. So you can&#039;t have more than one screenload of equipment on the ground. Or maybe you can, if you start the Equip screen with more than one screenload on the ground - I didn&#039;t check that.&lt;br /&gt;
&lt;br /&gt;
::[[User:Spike|Spike]] 13:10, 1 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
The Save Equipment feature is a good idea, but as far as i can see soldiers are recognized based on their names? I was wondering if this is deliberate or simply the best solution available. Might i suggest that you recognise soldiers based on their initial stats which are fairly unique (billions of combinations) and constant. &lt;br /&gt;
&lt;br /&gt;
--[[User:Necuno|Necuno]] 15:49, 9 December 2009 (EST)&lt;br /&gt;
&lt;br /&gt;
== Glitch with Alien Pets and Big Brother? ==&lt;br /&gt;
&lt;br /&gt;
Hi Seb. I was trying to do some initial research on the idea of [[User:Spike#Tank mods|Tank mods]] but it looked like these 2 useful features of your Loader, Alien Pets and Big Brother, have both stopped working. Can you test this, on the latest version? I&#039;m using a very recent version (last 2 weeks) but not the absolute latest as I have internet download problems. &lt;br /&gt;
&lt;br /&gt;
Also, have you seen this new Wiki article: [[Enemy Unknown Extended]]. It is a package including your loader plus a few other odds and ends.&lt;br /&gt;
&lt;br /&gt;
cheers,&lt;br /&gt;
[[User:Spike|Spike]] 11:16, 17 August 2009 (EDT)&lt;br /&gt;
:My mistake, I commented out that part of code a while ago and only recently noticed that. It was corrected one or two versions ago.&lt;br /&gt;
:The article is a good idea, it should allow less techies an easy start. [[User:Seb76|Seb76]] 13:51, 17 August 2009 (EDT)&lt;br /&gt;
:: OK cool yes the Hacks are back in place, thanks. [[User:Spike|Spike]] 20:34, 18 August 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Alien Bleeding ==&lt;br /&gt;
&lt;br /&gt;
Test results:&lt;br /&gt;
&lt;br /&gt;
* 1-unit and 4-unit aliens can be healed by anyone (alien or human) holding a Medkit&lt;br /&gt;
* 4-unit aliens can be healed by standing in any of their 4 squares&lt;br /&gt;
* 4-unit aliens can only be healed while they are stunned. Pointing to their &amp;quot;control&amp;quot; square does not seem to work.&lt;br /&gt;
* 1-unit aliens can be healed either while conscious or while stunned&lt;br /&gt;
* Wounds on aliens can be correctly seen with Medkits&lt;br /&gt;
* The Medkit display shows a human silhouette regardless of the alien type, of course&lt;br /&gt;
* Healing aliens with Medkits, stops them from dying of wounds (not 100% tested but seems to be true)&lt;br /&gt;
* Aliens (large and small) seem to lose the correct amount of Health per turn from Wounds&lt;br /&gt;
* Aliens with wounds that are not treated, eventually die (not 100% tested but seems to be true)&lt;br /&gt;
* A Mind Probe can see if an alien has Wounds.&lt;br /&gt;
&lt;br /&gt;
Anomalies:&lt;br /&gt;
&lt;br /&gt;
* I had a lot more reports of Reapers dying than I would expect. I would not have expected any to die, and I had 3 reports of death by wounds. Even heavily wounded Reapers take a long time to die. In my test I was only shooting them with Pistols. Maybe there is a problem with the reporting? Maybe the death of the same Reaper was reported more than once? More testing needed on this. &lt;br /&gt;
:I wonder if Reapers are receiving wounds on all 4 sections when hit by explosives (I don&#039;t know which weapon you were using). They really shouldn&#039;t, although I&#039;m unsure how you&#039;d get around this. If possible, put a cap on the maximum number of wounds something can ever have (perhaps 6). You could argue their multiple hearts really empty their blood out quickly, but I don&#039;t think fatal wounds should ever become more dangerous than burning alive.&lt;br /&gt;
&lt;br /&gt;
:: Well, why not: hit four times by one explosive, check for incurring fatal wounds four times.  -- [[User:Zaimoni|Zaimoni]], 13:49 Sept. 6 2009 CDT&lt;br /&gt;
&lt;br /&gt;
* Question: should the death of an alien by wounds be reported, or should it die silently? Did I only see these messages because I was using Alien Pets, and so they were on &amp;quot;my&amp;quot; side?&lt;br /&gt;
:Regarding death reports, I enabled the dialog for aliens/civilians (it usually only shows up for xcom operatives) to help in testing. The final version will not show them. [[User:Seb76|Seb76]] 14:10, 3 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Caveats:&lt;br /&gt;
* I used the Alien Pets, Big Brother, and Alien Inventory hacks to do this test. I also hacked a save game to give me Pistols, Medkits, PsiAmps and Mind Probes. [[User:Spike|Spike]] 16:03, 3 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
To Do:&lt;br /&gt;
* Test if aliens (small, large and mechanical) suffer from [[Fatal Wounds#Other effects of Fatal Wounds|other effects of wounds]], e.g. penalties to Energy, Accuracy, Time Units&lt;br /&gt;
* Do Cyberdisks, which have no legs or arms and probably no head, only ever receive Torso wounds?&lt;br /&gt;
&lt;br /&gt;
=== Mechanical Bleeding ===&lt;br /&gt;
&lt;br /&gt;
* Question: Do Cyberdiscs and Sectopods receive Fatal Wounds? I&#039;m wondering whether an unconscious Cyberdisc is safe to be around. Even if they didn&#039;t explode, Fatal Wounds would be stupid for a robot. If XCOM tanks can&#039;t end up leaking fuel and sparking dangerously, neither should enemy robots. [[User:Stubbs|Stubbs]]&lt;br /&gt;
: I think you can make a case for tanks and robots having &amp;quot;wounds&amp;quot;, i.e. damage that gets progressively worse by itself. You can even make a case for them being &amp;quot;stunned&amp;quot; - temporarily non-operational. You can even make a case for it applying to alien robots but not to X-COM tanks, since alien robots all have some degree of organic component (which is why they can be Mind Controlled). But I still think you are right, neither effect should apply to machines, whether alien or human. As for your question, see the tests below:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Cyberdisk Bleeding Test Findings:&lt;br /&gt;
* Cyberdisks take Wounds (with Alien Bleeding option enabled)&lt;br /&gt;
* Cyberdisk wounds can be healed (though only after unit is stunned)&lt;br /&gt;
* Cyberdisks lose health from wounds&lt;br /&gt;
* Cyberdisks can die from wounds&lt;br /&gt;
* Cyberdisks don&#039;t seem to explode when they die from wounds (&amp;quot;has died from wounds&amp;quot; popup)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Cyberdisk Bleeding TestTest Caveats:&lt;br /&gt;
* Same caveats as previous tests (above), plus:&lt;br /&gt;
* The Cyberdisks were modified from Reapers using xcomutil :rpl&lt;br /&gt;
* Some Pistols were changed to Laser Rifles using xcomutil :chg&lt;br /&gt;
* (xcomutil was not installed in the game directory however, it was used from another location)&lt;br /&gt;
* The stats (Armour 34 all round, Health 120) appeared normal for Superhuman&lt;br /&gt;
* However the Cyberdisks seemed to fall too easily to Laser Rifle fire (e.g. 1 hit)&lt;br /&gt;
* Also, they seemed not to explode as often. This was because they were often stunned.&lt;br /&gt;
* Hard to tell in-game whether a Cyberdisk is dead or stunned. The graphic is the same, you can&#039;t use a Mind Probe, nor look on the ground, nor even check by changing sides.&lt;br /&gt;
* Actually there is one way to tell: stand over it and use a Medkit. Didn&#039;t think of that. [[User:Spike|Spike]] 08:22, 5 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:Thanks for finding out, Spike. Autopsy text shows you are right about the Sectopod( but not about the Cyberdisc) having biomechanical components, but it&#039;s not like there are gallons of blood pumping around the thing to gush out. One thing: did you check both conscious and unconscious death-by-wounds for the Cyberdisc? [[User:Stubbs|Stubbs]]&lt;br /&gt;
::No problem Stubbs. I didn&#039;t deliberately test this, but I had numerous deaths-by-wounding while unconscious and I think at least a few while conscious. I believe those that died while conscious, exploded. (I think this is the basic rule for Cyberdisks. If they are stunned, they don&#039;t explode. This typically happens with stun weapons but can also happen with regular weapons, if you are lucky.) [[User:Spike|Spike]] 20:54, 5 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Seb76: maybe robots receiving wounds was an oversight, or maybe you really do want robots to take wounds. In either case, it would be nice to have a separate option for this. My arguments against robot wounds are pretty simple: tanks do not receive them, the bled-out dialogue &amp;quot;X has died from a fatal wound&amp;quot; sounds silly for a robot that was never alive, and finally that a Medkit should not be able to heal a robot.&lt;br /&gt;
: It&#039;s reasonable that alien mechanisms (Sectopod, Cyberdisk) would not suffer from wounds. Possibly also Zombies should remain immune to wounds? From a note Seb made elsewhere, I think the UNITREF.DAT &amp;quot;can be wounded&amp;quot; flag is the same as the &amp;quot;can be stunned&amp;quot; flag. Wounding is probably prohibited globally for aliens, by an override somewhere in the executable. Seb has probably removed this override, unconditionally. To remove the override more selectively, I suspect Seb would need to put a logic test in the code, to check the alien type. .[[User:Spike|Spike]] 20:54, 5 September 2009 (EDT)&lt;br /&gt;
::There was a check for ownership that I simply removed. Next version will have an explicit check for robots/chryssies/zombies not to bleed. [[User:Seb76|Seb76]] 12:29, 6 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
* If you want a sense of &amp;quot;the Sectopod&#039;s leg got damaged&amp;quot; or even &amp;quot;the tank&#039;s track was broken&amp;quot;, perhaps robotic units could be &#039;wounded&#039; by damaging max TUs. &lt;br /&gt;
* If, however, the above won&#039;t let weapon usage TU %s recalculate as TUs are lost (i.e. the units lose firing ability as well as walking), then certain values of Energy with the correct Energy usage modifier could emulate loss of speed without losing firing ability. Since Energy is returned at a rate of 1/3 of TUs, these units could have an Energy value of (slightly less than) exactly 1/3rd of their TUs. Their energy usage modifier is then changed to allow this small energy value to usually suffice. Now, when Energy is damaged, the units will be permanently slowed, but their weapons won&#039;t be affected. [[User:Stubbs|Stubbs]]&lt;br /&gt;
&lt;br /&gt;
=== Zombie Bleeding ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Zombies that bleed to death don&#039;t seem to turn into Chryssalids. As discussed above, it might be better to disable wounding for Zombies. (Death by wounding for Zombies was already possible, without this fix, if the Zombie was mind controlled, wounded while mind controlled, then released back to Alien control.) [[User:Spike|Spike]] 21:07, 5 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Hostile Civilians ==&lt;br /&gt;
&lt;br /&gt;
This fix also seems to prevent:&lt;br /&gt;
* [[Exploiting_Mind_Control#Zombie&#039;s_Permanent_Control_of_Aliens_via_Stunning|Permanent Control of Aliens via Stunning]] Exploit - as was hoped for. &lt;br /&gt;
* [[Exploiting_Mind_Control#Resurrect Zombified Agents|Permanent Control of a Chryssalid/Tentaculat]]&lt;br /&gt;
&lt;br /&gt;
It does not fix:&lt;br /&gt;
&lt;br /&gt;
* Various Mind Control bugs: &lt;br /&gt;
** [[Known_Bugs#Mind_Controlled_Soldiers_go_MIA]]&lt;br /&gt;
** [[Known_Bugs#Mind Controlled Aliens Count as MIA if you Abort]]&lt;br /&gt;
&lt;br /&gt;
(Probably because fixing both of these requires special, end-of-mission processing)&lt;br /&gt;
&lt;br /&gt;
Still To Be Fixed:&lt;br /&gt;
&lt;br /&gt;
* [[Exploiting_Mind_Control#Exponential Mind Control|Exponential Mind Control]]&lt;br /&gt;
&lt;br /&gt;
(This requires a check in UNITPOS to ensure that the unit attempting Mind Control is not, itself, already mind controlled.)&lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 16:16, 3 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Fixed Funky Fire and Zombies ==&lt;br /&gt;
&lt;br /&gt;
Fixed Funky Fire still permanently kills Zombies, when the killing damage comes from (end of turn) fire damage. [[User:Spike|Spike]] 21:02, 5 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== Research Tree ==&lt;br /&gt;
&lt;br /&gt;
I&#039;ve found a way of modding the research tree and was wondering if people are interested in an updated version. I&#039;ve read of stuff like enabling hovertanks from cyberdisc autopsies or flying suits with floater research, but I think there is more that can be done. The limitations from the original game is that having researched a topic cannot unlock more than 4 new topics, and cannot unlock the production of more than 4 new item types. Any ideas? [[User:Seb76|Seb76]] 12:40, 6 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
* Another one I mentioned was: Mind Probe before Psi-Amp, although I&#039;m going to retcon that to &amp;quot;Mind Probe before Psi-Lab&amp;quot; (which then leads to Psi Aimp as per usual). The logic behind this is that the first step of a psi-attack must be scanning for enemy brainwaves to pick them out of the other signals. Before you can teach soldiers to do this, you&#039;d have to have studied the mind probe to see how the non-psychic aliens are managing to find targets. You&#039;ve got to walk before you can run, after all.&lt;br /&gt;
* I&#039;m unsure if the next suggestion is possible, given what you have said. I&#039;d like some kind of necessity to research at least some corpses/aliens - is it possible to require, say, any 6 alien &#039;live&#039; or &#039;autopsy&#039; reports finished before Alien Origins unlocks? You might also make it dependent on difficulty (6/7/8/9/10 needed). You could also include alien missions in this count.&lt;br /&gt;
* My only other suggestions are: you should have to research Elerium before you can build anything that requires Elerium to build. You should have to research Alien Alloys before you can build anything that uses those (which is true only for some things currently. It doesn&#039;t seem to be a prerequisite for building alien weapons). Is it possible for a manufactured item to require two separate research entries to be manufactured?&lt;br /&gt;
* Question: is there also a limit of 4 prerequisites for a research item? [[User:Stubbs|Stubbs]]&lt;br /&gt;
:There is no limit on prerequisites, it&#039;s the code that shows &amp;quot;you can now build/research xxx&amp;quot; that has a 4 entries limitation. [[User:Seb76|Seb76]] 15:05, 6 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
A boring suggestion but how about making sure that for all weapon research, you need to do the pistol before the rifle before the heavy weapon, etc. And similarly with the ammo types. Apart from that, I&#039;ll think on it. [[User:Spike|Spike]] 17:42, 6 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
Another boring suggestion: each specific laser weapon should take a little longer to research - force you to use the starting weapons for a little longer. You could also rebalance the Plasma research times so that the rifle took a little longer and the Heavy Plasma took significantly longer. It might then be more viable to research them from weakest to strongest, without forcing your hand as Spike suggested. [[User:Stubbs|Stubbs]]&lt;br /&gt;
&lt;br /&gt;
:Yep that&#039;s a good alternative. &lt;br /&gt;
&lt;br /&gt;
You could make the Stun Launcher a little harder by requiring (as well as Alloys and Elerium), perhaps a live Medic to be researched before the Stun Launcher (since it&#039;s usually Medics that carry them and presumably understand how to operate them), and an Engineer for a Blaster Launcher. It&#039;s not much extra but it helps to make these powerful weapons a little harder to get. If you wanted to make Blaster Launcher quite a lot harder to get you could add something like UFO Navigation (something to do with plotting all those waypoints, alien-stylee), or at least a Mind Probe for similar reason. &lt;br /&gt;
&lt;br /&gt;
But, what are we trying to do here? Make things harder in general? That&#039;s one option. Or &amp;quot;rebalance&amp;quot;, i.e. make things that are relatively too easy to get, relatively harder to get? Or make things more &amp;quot;logical&amp;quot;? There&#039;s lots of ways to play this. &lt;br /&gt;
&lt;br /&gt;
It&#039;s a shame there&#039;s not a distinction in the game between using, and manufacturing, alien weapons - as is done in XcomUtil. Really, there should be a world of difference between figuring out how to use scavenged alien weapons, and actually being able to manufacture them. But that&#039;s not really a research tree topic, &#039;&#039;&#039;unless&#039;&#039;&#039; - would it be possible to create new topics? Could you separate out the using of an item from the manufacturing of it? (If not, it would be good to have a game variant in which nothing that can be scavenged, is allowed to be manufactured).&lt;br /&gt;
&lt;br /&gt;
UFO Navigation might also be a good prerequisite for Hyperwave Decoder. I&#039;m sort of rambling here, but what are the most powerful technologies, that are kind of easy to get... which ones need to be made harder. (Are there any that need to be made easier?)&lt;br /&gt;
&lt;br /&gt;
Powerful technologies:&lt;br /&gt;
* Psionics (Psi Lab == Psi Amp). Adding the Mind Probe, as suggested, would be a good idea. Maybe a psionic Commander capture required for each. &lt;br /&gt;
* Blaster Launcher - maybe require an Engineer and a Soldier research, as well as Elerium &amp;amp; Alloys. Mind Probe or  UFO Navigation for the &amp;quot;plotting&amp;quot; element? A separate Engineer capture to produce the ammo? What else?&lt;br /&gt;
* Stun Launcher - Medic and an Engineer? Maybe a full set of autopsies - but that&#039;s too onerous. &lt;br /&gt;
* Heavy Plasma - stretching the research time would be good, though this can already be done. Additional pre-reqs - maybe add a live Engineer requirement (maybe for &#039;&#039;each&#039;&#039; Plasma weapon type?). If you keep making these requirements you probably need to add a hint in the UFOPaedia along the lines of &amp;quot;we will need to interrogate alien technical experts to further understand this weapon technology&amp;quot;. (OK that&#039;s hardly a hint.)&lt;br /&gt;
* Laser Cannon (?) - But I&#039;m not sure this Laser Cannon factory thing is a big deal. Arguably building a new intercept base is a better cash cow than building a 50-Engineer Laser Cannon factory.&lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 16:34, 8 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== 64 bit compatibility ==&lt;br /&gt;
&lt;br /&gt;
Any way to make the loader compatible with 64-bit operating systems, like 64-bit XP/Vista/7? [[User:Jwilcox25|Jwilcox25]]&lt;br /&gt;
&lt;br /&gt;
: I&#039;m using it on Windows 7 and it&#039;s working fine. Not sure if that&#039;s 64 bit though. [[User:Spike|Spike]] 07:26, 9 September 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
:: If you&#039;re not sure, you are probably running the 32-bit version of Windows 7. Starting from XP, Windows comes in both 32-bit and 64-bit flavors. Most 32-bit programs are backwards compatible, but apparently not X-COM from my experience. [[User:Jwilcox25|Jwilcox25]]&lt;br /&gt;
&lt;br /&gt;
== Music bug ==&lt;br /&gt;
&lt;br /&gt;
When enabled &amp;quot;MIDI freeze&amp;quot; bugfix, after entering first combat the music stops playing completely, for the remaining game session.&lt;br /&gt;
&lt;br /&gt;
Also, when using Extender, for some reason music is playing at really low volume, i have to manually reduce my main sound channel and crank up the volume to hear it. When just starting normal UFO CE volume levels of music and sfx are about equal. I have SB Live &amp;amp; WinXP.&lt;br /&gt;
&lt;br /&gt;
== Fire Speed bug ==&lt;br /&gt;
&lt;br /&gt;
Sometimes, for no apparent reason, fire speed setting jumps to 3, instead of what you had it set on.&lt;br /&gt;
&lt;br /&gt;
== Reserve TU for x-Shot ==&lt;br /&gt;
&lt;br /&gt;
Not sure if this has been addressed or fixed, but if you reserve Time Units for any shot type, all you get is Snap Shots for the reaction phase - never aimed or auto. Is there any way you could enable these two unused types for reaction shots? --[[User:Zombie|Zombie]] 22:51, 25 October 2009 (EDT)&lt;br /&gt;
&lt;br /&gt;
== TFTD ==&lt;br /&gt;
&lt;br /&gt;
I know you&#039;re hoping to perfect the current version before taking on any new projects, but I just want to add my plea to the others requesting a TFTD version.  Even some of the basic functionality would be awesome and probably completely portable, such as the stats on the equipments screen, default new base, etc.&lt;/div&gt;</summary>
		<author><name>Epiceuropean</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Talk:Explosions&amp;diff=26899</id>
		<title>Talk:Explosions</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Talk:Explosions&amp;diff=26899"/>
		<updated>2010-01-11T17:07:04Z</updated>

		<summary type="html">&lt;p&gt;Epiceuropean: /* UFO Power Source Explosions */ Elerium spawning&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Zombie, even gas station explosions don&#039;t hurt anybody nearby? - [[User:MikeTheRed|MikeTheRed]] 18:37, 3 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:I&#039;m pretty sure I&#039;ve gotten civilians killed by stray shots blowing up gas pumps before.  [[User:Arrow Quivershaft|Arrow Quivershaft]] 19:59, 3 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
::Friendly units are not affected by any explosions caused by battlefield objects on UFO (on TFTD and some of my mod terrains this does not apply). There&#039;s some sort of quirk however concerning explosions that only generate smoke: I&#039;ve seen often aliens/civilians get killed because of those explosions: I think (not confirmed) one factor might be if those units are already standing on smoke and the game wrongly allocates them damage everytime a barrel explodes. [[User:Hobbes|Hobbes]] 02:07, 4 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:On that note, I&#039;ve most certainly killed aliens by blowing up fuel barrels in the Hangar during base defense missions.  [[User:Arrow Quivershaft|Arrow Quivershaft]] 07:48, 4 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Just to throw a spanner in the works, sometimes I&#039;ve seen aliens that weren&#039;t near the bowser or fuel drum die after it explodes. For Quite the explosive odd ball out. - [[User:NKF|NKF]]&lt;br /&gt;
&lt;br /&gt;
: Ok, this is what I know. MapView lists those &amp;quot;explosive&amp;quot; objects as having a damage type of smoke, not high explosive. This checks out on the battlescape as when you shoot one of these objects, the explosion doesn&#039;t damage terrain and it produces a dense smoke cloud just like a Smoke Grenade does. Moving X-COM soldiers near the fuel bowser and then shooting it doesn&#039;t do them any harm - that&#039;s basically a given. &lt;br /&gt;
&lt;br /&gt;
: However like NKF and Hobbes mentioned, Civilians and aliens can &amp;lt;i&amp;gt;sometimes&amp;lt;/i&amp;gt; die after you shoot one of the objects. It doesn&#039;t happen all the time though and a quick round of testing reveals they normally don&#039;t take damage from the explosions either. This leads me to believe it is a bug of some sort. I did have a civilian die last night after shooting a fuel bowser: it was about 6 tiles away and wasn&#039;t standing in a smoke cloud. But, I did shoot a couple pumps out in the previous rounds which may be incorrectly allocating damage to nearby non-human units like Hobbes points out. Still, more testing needs to be done before we can come to a logical theory. Right now we have nothing to stand on other than our words. ;)&lt;br /&gt;
&lt;br /&gt;
: A main problem with the civilians is that they never get close enough to a fuel bowser on a terror mission to test this out properly and you can&#039;t use MC on them as that changes their ownership flag. I might do a little map editing and intentionally force civilians to spawn surrounding the pumps, and also give the civilians no energy or TU to force them to stay put instead of wandering off. Then , if the pump gets shot out and they all survive we&#039;ll know that thay don&#039;t take damage &amp;lt;b&amp;gt;normally&amp;lt;/b&amp;gt;. (By normally, I mean no other object explosions happened on the map in previous rounds). After this I can go nuts and shoot off a whole bunch of pumps to see what happens. If the civilians die when standing in smoke, then we can come to a conclusion. --[[User:Zombie|Zombie]] 08:06, 6 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
: I have seen aliens killed and objects damaged when the purple tables explode. This is most visible in the command centers of bases, where the whole place goes up when a blaster bomb is fired,even if the back blast shouldn&#039;t hit the rearmost segments with enough force.--[[User:(name here)|(name here)]] 10:07, 18 November 2007 (PST)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;b&amp;gt;Update:&amp;lt;/b&amp;gt;[[Image:Bowser.png|right]]&lt;br /&gt;
&lt;br /&gt;
I managed to construct a testing scenario for civilians against a fuel bowser explosion the other day. The gas station map was edited so that the fuel bowsers were inside a large structure with some lighting sources (lamps) aroung the perimeter for giggles. Since I didn&#039;t have access to the internet and since Daishiva&#039;s MapEdit doesn&#039;t allow you to change the spawn points, I ended up decoding the RMP structure and editing the spawn points myself. Of the 16 normally occurring spawn points on the gas station map, I changed all of them to be civilian with a spawn priority of 10 (meaning a high probability of a civilian showing up there) and clustered 8 of them around 2 fuel bowsers with links which circled the pump to keep the civilians from wandering off. Then I kept going on a terror mission until the structure showed up with enough civies spawned around a pump.&lt;br /&gt;
&lt;br /&gt;
First thing I did was to edit all civies to have 200 health. After this, I shot a pump with 3 civilians standing around it and checked to see if any of them were harmed. Only one was injured. The picture at the right details the scenario. G stands for the gas pump (er, fuel bowser, whatever you call it), C1, C2, and C3 are the civilians and S is the soldier. The solder shot at the pump with a Laser Rifle and the civilian injured in the blast was #3 (red square). No other civilians were ever injured. I didn&#039;t have time to check out anything else but the orientation of the shot and the location of the civilians play a role in who will get hurt. &lt;br /&gt;
&lt;br /&gt;
Just for the heck of it, I decided to see how much damage was inflicted to civilian #3. After writing down about 20 numbers I realized that this would be a perfect job for BB&#039;s logger and AutoHotKey. I wrote a script, automated the whole process and then came back an hour later. Now, the fuel bowser has a listed damage potential as 46, so I half-guessed the damage would be between 23 and 69 (1/2 and 3/2 the ave damage). Wrong. It was between 0 and 120! This is more like a normal ammunition type than an explosion. After sitting there in disbelief for a while, it hit me that the Laser Rifles damage potential was probably being wrongly allocated to the civilian. When I changed the weapon to the Heavy Laser, the civilian got between 0 and 170 points of damage - exactly what would be predicted with ammo having 85 average damage. And no, the Laser Rifle shots were not missing the target and hitting the civilian directly, I can&#039;t stress this enough.&lt;br /&gt;
&lt;br /&gt;
The only conclusion I can draw so far is that the more powerful of weapon that you use to shoot the fuel bowser, the more damage will be dealt to someone standing near it. Of course, more testing is in-order here, but at least we have a workable theory on damage. --[[User:Zombie|Zombie]] 18:40, 9 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:You can edit the .rmp files with Map View but you seemed to have managed quite well by your own :)&lt;br /&gt;
:What you described is the effect when a weapon&#039;s hit completely destroys a terrain feature it transfers the excess damage to units (and objects?) closeby. Or, the shot destroys the target and carries on. At least that&#039;s what it seems to me on the rare occasions that i witness that behaviour, since it&#039;s hard to get it with either bullets against human buildings or plasmas against UFO walls. &lt;br /&gt;
:Still that leaves the question about far away aliens dying from gas pump explosions. One thing I remember that can help is that the smoke is generated on the alien&#039;s square before it dies. - [[User:Hobbes|Hobbes]] 22:44, 9 August 2007 (PDT)&lt;br /&gt;
--------&lt;br /&gt;
I think he means if you destroy a terrain feature that subsequently blows up, the explosion damage to nearby units would be the calculated in the same way as if they had been shot directly.&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 19:45, 10 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Correct, BB. @Hobbes - I&#039;m still a little confused on who gets hit. See, if the  &amp;quot;bullet&amp;quot; were to &amp;quot;kill&amp;quot; the bowser and then continue on, the civilian damaged should be #2 (not #3). Unless the line of fire was screwed up in the intermediate effect somehow. Also, the amount of damage to the civilian is exactly what is predicted if you shot it directly. If the bowser were to &amp;quot;absorb&amp;quot; some of the damage, I&#039;d see that reflected in the log file. And for the time being, this is only true for civilians. I haven&#039;t got around to testing if aliens suffer the same fate. --[[User:Zombie|Zombie]] 15:35, 12 August 2007 (PDT)&lt;br /&gt;
::Well i was *convinced* that shots would continue after destroying its target until I ran a couple of limited tests to verify this: on the first one I tried firing at soft walls with an unarmored xcom unit behind it. The unit suffered no damage at all. But then I remembered how sometimes objects when hit aren&#039;t replaced with their wrecked version (like crates....they just disappear). The crate supposedly would be replaced with the wreck but instead it simply disappears, which would mean that the wreck that replaces it gets the excess power of the shot and is obliterated as well. I can&#039;t really explain it but I feel this might be related to the dying civvies/aliens. -- [[User:Hobbes|Hobbes]] 17:22, 12 August 2007 (PDT)&lt;br /&gt;
------------&lt;br /&gt;
If you shoot a piece of terrain, the &amp;quot;armor&amp;quot; of that tile is subtracted from the damage the shot did. If the result is still positive, the tile is destroyed, or replaced with the &amp;quot;damaged&amp;quot; version.&lt;br /&gt;
&lt;br /&gt;
In that later case, the armor of the new tile is again subtracted from the remaining damage total, and so on until you run out of &amp;quot;damage&amp;quot; or you run out of tiles to replace with.&lt;br /&gt;
&lt;br /&gt;
(This is how my damage testing tileset (which shows the shot power against a given floor tile, on that floor tile): By drawing a number on each, giving them an armor of 1, and setting them to change to the next numbered tile when toasted).&lt;br /&gt;
&lt;br /&gt;
In this situation, you see one &amp;quot;damage&amp;quot; figure used to destroy multiple tiles (I&#039;ve done no testing to see whether the damage can then be passed on to units). Each tile takes a reduced amount of damage as the ones before it suck it up.&lt;br /&gt;
&lt;br /&gt;
In the case of Zombies test, a new damage figure is calculated for every unit (or one for all?) that is harmed by the explosion of the tile (assuming it can explode): and that&#039;s based on the weapon used to damage that tile in the first place, not on what the tile was. The units take full weapon damage (not explosive damage, or it wouldn&#039;t be a random value).&lt;br /&gt;
&lt;br /&gt;
That said, if I ever feel the need to pass on damage after destroying terrain I find an autoshot works quite nicely. But then, I always use autoshot, so go figure. ;)&lt;br /&gt;
&lt;br /&gt;
Also worth a mention (whether or not it&#039;s relevant I dunno) is the IN (or was it HE?) bug. If you shoot a unit with an IN bullet of some sort, all units standing in fire (and smoke?) will take the damage of the shot (regardless as to whether they were in range of the blast).&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 06:37, 13 August 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
===UFO Power Source Explosions===&lt;br /&gt;
&lt;br /&gt;
Months ago, I was working on the probability that UPSs and their Elerium would survive a crash. This involved the individual chance of engine explosion upon crashing, the blast damage of an exploding engine, and the configuration of UFOs (and whether blast damage could spread to other engines). But Arg, I&#039;ve looked all around and can&#039;t find that work on the wiki. Or maybe it was in a forum? Anyone recall? :P - [[User:MikeTheRed|MikeTheRed]] 09:23, 9 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
: I think it was in a forum.  Abstract:&lt;br /&gt;
:* Individually, each power source has a measured probability of 70% explode, 30% intact.&lt;br /&gt;
:* If a power source is in the range of the explosion of another power source, it is destroyed and does not explode.&lt;br /&gt;
:* I don&#039;t recall the calculated damage off-hand.  It is possible for the navigation consoles on a Medium Scout to survive their power plant explosion, but far from certain.&lt;br /&gt;
:* Power sources are checked in coordinate lexicographical order.  E.g., for the terror ship the order of checking is N, W, E, S.  [This also entails that for a Terror Ship, all four explode or none explode.  Assuming no RNG problems, this translates to a 0.81% chance of seeing four power sources.  Battleships are notable in that power source explosions do not destroy other power sources, unlike other UFOs with multiple power sources.] - [[User:Zaimoni|Zaimoni]] 12:51 9 October 2007 (CDT)&lt;br /&gt;
&lt;br /&gt;
MTR: please see [[Talk:Exploits#Repairing_damaged_UFOs]] or [http://www.xcomufo.com/forums/index.php?showtopic=242025161 this topic] at the xcomufo forums. BTW, the Medium Scout, Large Scout, Abductor and Battleship all have their PS explosion probabilities calculated separately since they either only have one PS or they are separated by hulls or walls which reduce blast propagation.&lt;br /&gt;
&lt;br /&gt;
The only ships you need to worry about are the Harvester, Supply and Terror Ships. However, since the power sources on those ships are always separated from each other by 6 tiles, we can do some quick and dirty calculations. First of all, a power source has a explosive rating of 180-250 at GZ. Extrapolating to GZ+6 (the location of the other power source), the damage is 120-190. Elerium has a damage rating of 20 which guarantees immediate destruction if another power source explodes (exception is the Supply Ship). Power sources are destroyed outright if the average listed explosive strength is 100 or greater at the point of impact. Since the damage at GZ+6 is always greater than 120 points, all power sources will be destroyed from the blast. In the case of the Terror Ship, if one PS goes off, the strength of that single blast is more than enough to immediately destroy the other power sources. Thus, for all the PS to survive, the game needs to roll the 30% survival dice 4 times for an overall probability of 0.3^4=0.81%. (Supply has 3 PS for a 2.7% chance while the Harvester has 2 for a 9% chance).&lt;br /&gt;
&lt;br /&gt;
The Supply Ship is a special case because the PS are arranged in a straight line each 6 tiles apart. I haven&#039;t checked whether items (such as Elerium) can survive at GZ+12 of a PS explosion (I think they can). If this is the case, then a power source which explodes at the outside of the line will only destroy the one in the middle and permit a second roll to determine the fate of the surviving PS. Of course, if the central PS explodes, any successful &amp;quot;saving&amp;quot; rolls made up to that point are ignored and all the power sources are destroyed. --[[User:Zombie|Zombie]] 14:49, 9 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Now it&#039;s coming back to me... great stuff! Thanks Zai and Zombie. And thanks for the links. It&#039;ll take me a little while to refresh everything in my mind, and maybe take your test map for a drive again. Ultimately I&#039;ll want to get this info onto appropriate wiki pages. - [[User:MikeTheRed|MikeTheRed]] 15:38, 9 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
::I can shine some light onto the GZ+12 question, because I just yesterday recovered Elerium from a Supply Ship with two destroyed power sources.  Blaster Bomb explosions propagate for 11 tiles, and have no power after that, and tests have shown that a PS explodes with the same force as a BB. As well, it should be noted that sometimes the location of the PS starts on fire and may remain so for some time.  (On one final note, it makes more sense to me that Elerium is spawned under SURVIVING power sources; so there is no chance that it is destroyed by an explosion; it spawns after the explosions occur.  Of course, I could be completely wrong, it just makes more sense to me to code it that way.)  [[User:Arrow Quivershaft|Arrow Quivershaft]] 16:16, 9 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:::I was just playing around a bit, and changed Elerium&#039;s explosion resistance to 255. No Elerium spawned under exploded PSes that I could see, but I only did a mission or two that way so far. Further testing obviously needed, but some form of automation would be nice. Of course this lets you get away with using grenades within engine rooms, but otherwise UFO Crash Recovery numbers remain unchanged.[[User:Epiceuropean|Epiceuropean]] 12:07, 11 January 2010 (EST)&lt;br /&gt;
&lt;br /&gt;
:Good point Arrow, thanks for that. Zombie, I&#039;ve got a handle on it again and will post something about expected number of PSs at crash sites, a.k.a. average Elerium recovered. E.g. Supply ships yield 17.7 units of Elerium, on average (calcs to be shown on wiki). One thing has me curious... in your XCOMUFO thread you say you wrote down the edge strength of PS blasts (35 to 70) but then later said there are 71 possible values. But aren&#039;t there actually only 36? And again I wonder if truncation might have something to do with it... see, depending on just how they truncated what was applied (if they did) and/or how BB&#039;s tiles show the number, could have caused a fair amount of creep one way or the other... and it looks like it crept up. (&#039;&#039;If&#039;&#039; there were 256 original values somewhere/somehow which got converted to a 7th as many someway/somehow (36/256) ... shrug.) But it&#039;s really only an incredibly minor issue.  .... Anybody care to recommend where I&#039;d post the info on Elerium salvage? [[UFO_Crash_Recovery]] makes a lot of sense conceptually, but it&#039;s not a particularly info rich page. - [[User:MikeTheRed|MikeTheRed]] 18:58, 10 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
::Heh Mike. The 35-70 damage is the amount found at R11. The 90-125 damage (range of 36) is the average at GZ for objects. The last column is the actual explosive strength of the PS against units 180-250, range=71. Sorry, lots of numbers there to confuse.&lt;br /&gt;
&lt;br /&gt;
::I&#039;d include this info in the UFO Crash Recovery page. That seems like the best place for it, no? --[[User:Zombie|Zombie]] 19:42, 10 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Z, am I losing my mind? but PS explosions are quite unusual, aren&#039;t they? 1) they have a &#039;&#039;range&#039;&#039; versus terrain; all other explosions are a simple, invariant 50% of rated damage versus terrain, and 2) while they have a range, it is not +/- 50% of rated, like it is for explosives vs. units. If we are indeed seeing 50% of rated vs. terrain (which the decrement-by-5 strongly suggests), then your min-ave-max conclusion of 180-215-250 for PSs is actually +/- 16.28% of rated. How weird is that (and where&#039;d they get &#039;&#039;that&#039;&#039; percent)? Am I doing this right?? Maybe they special coded PSs. (There was also some &amp;quot;hybrid weirdness&amp;quot; seen with the  [[Small_Launcher#Stun_Bombs_vs._HE_Block|stun bomb]].) - [[User:MikeTheRed|MikeTheRed]] 21:37, 10 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
::LOL, Yup Power Source explosions are in a class all of their own. When I came back to this recently I was quite perplexed at the numbers since they do not follow the anticipated 50%-150% range which normal explosives dish out. The extrema of the PS at 215 damage is +/- 35 damage points which is strange. Don&#039;t know why the programmers decided to code this explosion so differently but what&#039;s done is done. It&#039;s our job to explain it which is usually hard. --[[User:Zombie|Zombie]] 22:14, 10 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
:Ok I have added [[UFO_Crash_Recovery#Power_Source_Explosions_and_Elerium_Recovery]] (and re-organized the page a little) and also created [[Explosions#Unusual_Explosives]] and simplified [[Small_Launcher#Stun_Bomb_Explosions]].&lt;br /&gt;
:*Did I get that last paragraph on [[Explosions#Stun_Bombs]] right? Also see [[Talk:Main_Page#Re-organize_Explosions]]. &lt;br /&gt;
:*Zombie, is there any way you&#039;d care to do a little more testing on crashing and PS explosions - specifically, how hard are units hit? Given how PSs break the standard explosion rules, it&#039;d be interesting to try to modify the game so that the sectoids(?) in the savegame crash scenario, have a lot of health (and armor?), so one can cross-confirm that the damage inflicted on terrain, is what is seen versus the units. (If PSs break some rules, do they break others? Is terrain really being hit by 50%? Just one look ought to answer everything.) I&#039;m not sure how/if aliens&#039; stats can be modified, when moving from GEO to BATTLE... can it be?&lt;br /&gt;
:- [[User:MikeTheRed|MikeTheRed]] 17:54, 12 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
::Sure, I&#039;ll fool around with this a little bit tonight. But I&#039;m letting you know right now that setting this scenario up is gonna take some time. I&#039;ll need to edit the routes (erm, spawn points) of a craft so the aliens will start directly next to a power source. Then the aliens stats will need to be modified in the executable to have high health to survive the explosion (assuming the PS explosion does a max of 250, an alien with 255 health should survive all the time so modifying armor would not be necessary). Also, to get any idea of what is happening with the blast, the quantity of aliens will need to be modified in the executable to force more of them to show up (8 is good for a GZ+1 test and 16 for a GZ+2). Will let you know what I come up with.&lt;br /&gt;
&lt;br /&gt;
::Edit: I created a scenario and ran it through its paces just now. Turns out Sectoids were dying left and right with 255 health. No good. I edited them to have 200 health and 100 overall armor and checked again. A couple times I saw corpses around the power source so the strength of the blast must be at least 310. 300 + 10 GZ+1 adjustment. As a quick calculation, if GZ is slated to have a blast strength of 250 and it follows the normal explosive theory, the max should be 250*3/2 = 375. Will need to jump up to the higher difficulties in order to bump armor up to 200 though - beginner always cuts the armor rating in the executable by half. Then we can see what will happen with a 400 health unit. Heck, maybe I better crank the total up to 500 to be safe, lol.--[[User:Zombie|Zombie]] 23:31, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
::Edit2: Well, with an armor of 250 and a health of 250, the Sectoids didn&#039;t seem to take any damage so I ended up switching everything to 200. Not sure how many trials I ran but it was on the neighborhood of 200 or so and the lowest value I reached was a health rating of 73. 400-73= 327 at GZ+1 and therefore 337 at GZ. More trials will be necessary to narrow the actual number down since the damage range is extremely high (each value in the range has a 0.3% chance of showing up once). --[[User:Zombie|Zombie]] 21:48, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Zombie, sorry for the delay. Wow I had thought this would only need a single test - I hope this isn&#039;t too much trouble! Are you also writing down the numerical tileset (terrain) GZ damage each test? It&#039;s definitely looking like PS explosions break yet another rule - they are not 50% of average/2 (and who knows what the relation is, unless enough data is colleced). - [[User:MikeTheRed|MikeTheRed]] 15:52, 17 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
:Looks like before the first turn, the engine will look for every tile in the map (it scans the MAP.DAT data linearly) ; when it finds a power source (it checks if the MCD special property is set to 2), there is a 25% chance that it will leave it alone. Otherwise, it&#039;ll generate an explosion at the UPS location with a strength of 180+RND*70. Whether the UPS blows up on top of that or is just destroyed, I do not know. Can someone hack the MCD data and see if it&#039;s possible to generate an explosion on a tile that is not a UPS just by messing with the special property? PS: I am almost certain of the 75% probability of explosion vs 70% that is often stated here. [[User:Seb76|Seb76]] 09:31, 12 February 2008 (PST)&lt;br /&gt;
&lt;br /&gt;
===Bodies===&lt;br /&gt;
&lt;br /&gt;
I&#039;ve noticed that sometimes when you use a high level explosive(Alien Grenade sometimes, but more often Blaster Bombs or XComUtil High-Explosive), aliens killed will not leave a corpse.  Has anyone figured out the rhyme or reason to this? [[User:Arrow Quivershaft|Arrow Quivershaft]] 13:33, 13 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
This also happens with human grenades; a fully healthy Sectoid must be at least two squares away from the detonation center to leave a corpse on Superhuman. [[User:Zaimoni|Zaimoni]] 16:38, 13 October 2007 (CDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Stranger and stranger...I just Mind Controlled two Ethereals, stood them next to each other, and had one of them prime his grenade for immediate detonation and deposit it at his feet.  The ethereal at ground zero, right on top of the grenade, was killed and left a corpse; however, his buddy standing adjacent(and to the south) got completely fragged(no corpse).  Makes me even more curious!  [[User:Arrow Quivershaft|Arrow Quivershaft]] 15:49, 13 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Arrow, I&#039;ll try to explain this the best I can. Just for the sake of understanding let&#039;s look at a piece of terrain. Say you shoot at a tile containing an object (a brick fence for instance). If you shoot at it with a low powered weapon it probably will not do anything to the fence segment. However, if you use a higher powered weapon it will destroy the fence segment which will in turn convert it into a destroyed fence section. If you use a really powerful weapon, it will obliterate the fence segment completely. What happens in this case is that the high damage weapon will destroy the brick fence segment converting it to a damaged object. If the amount of power used up in this process is less than the power of the hit, the resulting excess is applied to the damaged object. If the excess is enough, it will destroy the damaged object. Usually the process ends here and no further objects are created if more damage is applied. Since there isn&#039;t a tertiary object pointed to, the object is obliterated. (But in the case of Bomb Blokes numerical damage testing tileset, he linked a whole bunch of tiles together, each with a damage greater than the last one to form a testing scenario).&lt;br /&gt;
&lt;br /&gt;
The same thing happens to live aliens as it does with objects. When an alien is killed, it leaves a corpse &amp;quot;object&amp;quot; behind. If the damage applied is high enough, it destroys the corpse object and leaves nothing behind. The reason why you may notice some strange results is that the damage done by weapons is random (this is especially true with explosives which damage an area). So even though the damage dealt at GZ wasn&#039;t enough to destroy an alien outright, it doesn&#039;t mean that aliens further away from the blast center will take less damage than those closer to GZ (damage is calculated independently for each tile but still follows the usual damage profile for units). Overall though (like 200+ trials), aliens closer to the blast stand more of a chance to be obliterated than those standing further away. Hope this helps. --[[User:Zombie|Zombie]] 18:03, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Ok, thanks!  Makes alot more sense now.  I suspected that might be the reason, but I wasn&#039;t sure about it.  Considering my primary explosive at this point is the XComUtil High Explosive, it makes sense that the corpses are obliterated.  Thanks for the explanation!  [[User:Arrow Quivershaft|Arrow Quivershaft]] 18:10, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
[[Image:Numerical PS Screencap.png|right|thumb|250px]]&lt;br /&gt;
Note that although most weapons do random damage to their targets, explosives always deal a set amount of damage to tiles (which depends on the distance from GZ, any non-ground tiles in the way and the original power of the blast), as per this image.&lt;br /&gt;
&lt;br /&gt;
Explosive damage to units is random, however. Dunno if it&#039;s random against items or not (I suspect the later). Damage from non-explosive weapons is never applied to those.&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 19:01, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Sort of. At least this is what I think happens: blast damage from explosives is random to living units. If the random damage allocated to the unit is enough, it will kill the unit creating a corpse. If the blast has even more power, it will pass the excess on to the corpse leaving nothing. Think of the death tile for the corpse as an extra amount of health added to a live alien. If that value is surpassed, it bypasses corpse creation and creates the next tile in the sequence. In most cases, this is nothing.&lt;br /&gt;
&lt;br /&gt;
Non-Explosive weapons can and will have the damage applied to an alien and then the corpse if damage is enough. However, once the corpse is formed, any damage from non-explosive weapons will not destroy the body (you can&#039;t target a corpse or items to shoot at, only the ground). --[[User:Zombie|Zombie]] 19:19, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Erm, I&#039;m not following you on that last part. You&#039;re saying that if I shoot a sectoid with, say, a heavy plasma, any excess damage will be passed onto the corpse... But the corpse will never be destroyed?&lt;br /&gt;
&lt;br /&gt;
In that case, how do you know any damage was applied to the corpse at all? Items don&#039;t have an individual &amp;quot;health&amp;quot; stat that I know of, they either get destroyed or they don&#039;t get scratched.&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 19:46, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Let&#039;s say you shoot a Sectoid with a Laser Rifle modified to dish out 255 damage. If the shot pumps out the average (255) it will kill the Sectoid, pass the excess damage on to the corpse object and &amp;quot;kill&amp;quot; the corpse as well all in one fatal swoop. This boils down to sequencing. What probably happens is the game decides what to create by comparing the shot power to the damage ratings of all the tiles in the list sequence. If the damage is high enough, the game creates the appropriate item. It never actually creates the intermediate objects on the battlescape, otherwise a corpse would permanently end the sequence as it is an item from obdata.dat. Is that better? --[[User:Zombie|Zombie]] 20:34, 14 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
No sorry, now you&#039;ve lost me &amp;lt;b&amp;gt;completely&amp;lt;/b&amp;gt;. What the heck do tiles have to do with this?! I suspect we&#039;re not talking about the same issue here.&lt;br /&gt;
&lt;br /&gt;
Terrain when &amp;quot;destroyed&amp;quot; turns into other types of terrain, units turn into items, and items just get vaporised. Terrain never turns into items and units never turn into terrain.&lt;br /&gt;
&lt;br /&gt;
My question was whether or not a non-explosive weapon could damage a corpse, as your comments seem to suggest one could (while also stating one couldn&#039;t, hence my confusion as to what you mean!!). &lt;br /&gt;
&lt;br /&gt;
To make sure I know what I&#039;m talking about, I jacked up the laser rifle damage to maximum, and crippled the Sectoid corpse endurance down to one (defaults to 26 btw). After shooting a few &amp;quot;volunteers&amp;quot; I&#039;ll say my original statement was dead on: A non-explosive weapon CANNOT &amp;quot;kill&amp;quot;, destroy, or otherwise damage an item in the battlescape, even if that item is a corpse produced by the death of the original target.&lt;br /&gt;
&lt;br /&gt;
If you shoot a Sectoid, it takes the damage, and that&#039;s that. There&#039;s no more damage processing unless you&#039;re using an explosive of some sort, regardless as to whether the target dies and leaves a body. Terrain/tile elements have nothing to do with the matter.&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 04:56, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Sorry, I didn&#039;t mean to type &amp;quot;tiles&amp;quot; in my last post it should have been &amp;quot;objects&amp;quot;. As for non-explosive weapons vaporizing a body, I have seen it. Unfortunately I can&#039;t seem to replicate the result I witnessed with pumping up the damage to 255. Perhaps it is a glitch of some sort in one of my saved games? More testing is in order. --[[User:Zombie|Zombie]] 07:39, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Ah! I think I see the light now. I reckon what happened was you killed an alien when the item table was full (meaning a corpse couldn&#039;t be produced). Could that have been the case?&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 15:38, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
I don&#039;t think so. Usually I test on Beginner skill level with a small compliment (8) of crack soldiers each with a Laser Rifle and Psi-Amp. That isn&#039;t  even close to filling the item table. And I would have noticed if I couldn&#039;t finish a mission due to a clogged item table too. I may have been fooling around with the Damage Modifiers though. I wonder if the additional damage produced by a greater susceptibility rating would have done this. Perhaps. I&#039;ll need to run a few tests though. --[[User:Zombie|Zombie]] 21:48, 15 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Zombie, I think it must&#039;ve been something other than the gun itself.  The susceptibility, maybe.  Because otherwise, any alien killed by a Heavy Plasma other than a Muton would usually NOT leave a corpse, because of the inhuman damage dealt by the weapon.  115 damage on average, minus 30 for Sectoid health, leaves plenty more than the 26 needed to frag the corpse, and Sectoids blasted by Heavy Plasma always leave corpses in my experience.  Hope your tests can shed some more light on this!  [[User:Arrow Quivershaft|Arrow Quivershaft]] 17:31, 16 October 2007 (PDT)&lt;br /&gt;
&lt;br /&gt;
== Direct Hits ==&lt;br /&gt;
&lt;br /&gt;
Is there any evidence that a direct hit with an HE round is calculated any differently than dropping the round at GZ at the target&#039;s feet? In one sense you would expect a DH to apply to the facing armour rather than under armour (even though that would make a DH less effective than splash damage at GZ). Is there any chance that &amp;quot;weapon&amp;quot; damage mechanics rather than explosion mechanics are used for a DH? What about DH from Incendiary rounds?&lt;br /&gt;
&lt;br /&gt;
I have a test rig set up to test this: under Armour maxed out,  Auto Cannon accuracy maxed out. I wanted to ask before running the tests.&lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 00:55, 11 April 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:There&#039;s no evidence I&#039;m aware of.  The only weapon type that has &amp;quot;impact&amp;quot; damage, as I recall, is Incendiary.  [[User:Arrow Quivershaft|Arrow Quivershaft]] 00:57, 11 April 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: Well, from all the tests I ran back in the early days when we were still figuring the damage formula out, I did strike my test subjects head on, and that still dealt damage to the under armour. It&#039;s probably easier for the game to deal everything on a tile by tile bases and deal damage to under armour from GZ and GZ+1, then deal directional damage later on. It just recycles the same explosion mechanics that you get with grenades - only it happens earlier(I suppose you could say that if the bullet hits something solid within the tile, instead of dealing directional damage to the target, it tells the game to generate an explosion from that tile location). Besides, making the explosion directional at GZ would weaken it rather than strengthen it. &lt;br /&gt;
&lt;br /&gt;
:: As for incendiary: That&#039;s a weird kettle of fish. Impact damage is dealt to ALL units in flames, so I don&#039;t know if direction or location really matters.&lt;br /&gt;
&lt;br /&gt;
:: No harm in running your tests though. We&#039;ve learned a lot of things here by doing just that. -[[User:NKF|NKF]] 03:15, 11 April 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: I ran more tests on explosives than I&#039;d like to admit over at the XcomUfo forums. There is absolutely no difference between a ranged explosive (those fired from a weapon) and grenades. All affect under armor when the explosive hits at GZ or GZ+1. (As a side note, the mechanics for the stun bomb function exactly like explosives). Like NKF mentioned, a direct hit from an incendiary round is a strange creature. Where the round hits makes no difference: all units which catch fire take 5-10 damage points while those standing in fire take 1-12 damage points per turn. --[[User:Zombie|Zombie]] 06:48, 11 April 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
100 AC-HE rounds fired at a Sectoid in the open with 225 Under-armour, all rounds hit his GZ square, nearly all were Direct Hits on him - zero damage to Mr Sectoid. That seems pretty conclusive. There is no special Direct Hit effect from HE, only the standard GZ explosion effect. &lt;br /&gt;
&lt;br /&gt;
[[User:Spike|Spike]] 04:54, 12 April 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
== Re: When Is a Wall not a Wall  ==&lt;br /&gt;
&lt;br /&gt;
That is so not the definition of a &amp;quot;north&amp;quot; wall. Is he trying to say &amp;quot;the hull you see when the UFO is north of your unit&amp;quot;? --[[User:JellyfishGreen|JellyfishGreen]] 06:57, 7 May 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
You haven&#039;t provided enough context.  Which sentence is wrong, and what should it say?--[[User:Ethereal Cereal|Ethereal Cereal]] 19:53, 8 May 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Take a look at the image in the section listed. There&#039;s a big circle around the southern side of the UFO labeled &amp;quot;north wall&amp;quot;, and a big circle around the eastern side labeled &amp;quot;west wall&amp;quot;. My bet is that&#039;s what he&#039;s referring to.&lt;br /&gt;
&lt;br /&gt;
However, that article is referring to walls on a &amp;quot;tile by tile&amp;quot; basis. There are four sorts of tiles in UFO: Ground, Object, North Wall and West Wall.&lt;br /&gt;
&lt;br /&gt;
That is to say, the tiles referred to as the &amp;quot;north wall&amp;quot; region actually DO have walls placed in the northern region &amp;lt;i&amp;gt;of the tiles themselves&amp;lt;/i&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
And the same goes for the &amp;quot;west wall&amp;quot; tiles, although they are on the eastern side of the UFO the walls themselves are in the western region of the tiles they reside in.&lt;br /&gt;
&lt;br /&gt;
So when is a wall not a wall? When it&#039;s set to an &amp;quot;object&amp;quot; (similar to the lumps of dirt you see in bases, and scenery such as trees, lamp posts, etc). Unlike regular walls, these tiles do not block explosions when hit DIRECTLY by a blast, allowing you to launch attacks through a UFO&#039;s hull even if your explosives don&#039;t actually have the strength to demolish the hull itself. Aside from the true walls circled in the graphic ALL walls that make up a UFO hull fall into this category.&lt;br /&gt;
&lt;br /&gt;
If it helps, try loading up MapView and enabling the TopView. You&#039;ll be able to see which of the four tile types exist in any given map location.&lt;br /&gt;
&lt;br /&gt;
It&#039;s quite true that the section is very vague and confusing (and at worst just plain wrong at times) so I&#039;ve taken a stab at re-writing it.&lt;br /&gt;
&lt;br /&gt;
- [[User:Bomb Bloke|Bomb Bloke]] 21:47, 9 May 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
Like BB says, I took my designations from MapView. I too wondered &amp;quot;north from what?&amp;quot;, etc. But somebody who knew the code a lot better than me (the MapView author) called it something specific. I&#039;m just a data analyst -slash- XCOM lover and didn&#039;t want to bring up a big question of, what&#039;s the right orientation. I just used MapView&#039;s orientation. I, for one, never saw a clear north or south on anything, since it&#039;s an &amp;quot;isometric&amp;quot; view (viewing the edge on of a diamond point, at the bottom of your screen), so I was happy to have someone say something definitive.&lt;br /&gt;
&lt;br /&gt;
If anyone would like to propose a standard way of what is north or south, especially relative to the screen, please say so. And you&#039;re also volunteering to clean up the whole wiki, plus petition the MapView guy to change his program. My same dilemma.&lt;br /&gt;
&lt;br /&gt;
So I went with what MapView said. Thanks for making it sound reasonable, BB.&lt;br /&gt;
&lt;br /&gt;
Thanks for helping to explain that, BB. The whole Explosions page could use a ton of simplification, and maybe even it should be separated into two pages - one a summary page, and the other, all the supporting details. This page grew from some basics to an overflow of information when I hit it ... and it&#039;s a repetitious mess in some places, because I didn&#039;t want to delete what had been there before. The &amp;quot;Blast Propagation&amp;quot;, &amp;quot;Blaster Bomb Pattern&amp;quot;, and &amp;quot;Blast Diameters&amp;quot; sections could all be folded into one, for example (I think Zombie posted some original data and I didn&#039;t want to delete it). Also the footnotes to &amp;quot;Blast Diameters&amp;quot; were obsoleted by my subsequent work, but I never got back to that table.&lt;br /&gt;
&lt;br /&gt;
--[[User:MikeTheRed|MikeTheRed]] 00:28, 10 May 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: While orientation is generally a matter of preference, I&#039;ve always used the overhead map for compass orientation. For example, soldiers exiting the Skyranger travel North, the nose of the Skyranger points South, while the aliens exiting a Large Scout would be traveling East. The isometric view just tilts everything by 45 degrees to the right, so North is the top right of the screen. - [[User:NKF|NKF]] 03:53, 10 May 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
: The default orientation for overhead maps is that north is going up.  Confirming this, the UNITREF orientation byte is 0 for North, and increases going clockwise.  [E.g., East is 2.]  MapView does correctly identify north and west walls -- as &amp;lt;b&amp;gt;map components&amp;lt;/b&amp;gt; whose usage was optimized for thin walls.  As outer UFO walls are thick, the game is forced by data design into using true north walls for the southern boundary of UFOs, and true west walls for the eastern boundary of UFOs. - [[User:Zaimoni|Zaimoni]] 9:28, 10 May 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
: Makes sense to me. In order to help readers a little more, the notes for that one picture could re-emphasize what MapView says. Or, of course, the picture (and text) could be changed to simply say, only south and east outer UFO walls are true ones. Plus supply a footnote re: MapView&#039;s nomenclature, so folks aren&#039;t confused if they use it. I dunno... something like that, shrug. -[[User:MikeTheRed|MikeTheRed]] 11:51, 14 May 2008 (PDT)&lt;br /&gt;
&lt;br /&gt;
== HE Propagation Edge ==&lt;br /&gt;
[[Image:AC-HE Blast.png|thumb|right|AC-HE/HC-HE blast pattern in desert.]]&lt;br /&gt;
A question for our Explosive experts. The tables in this article show AC-HE (44 HE) having a blast radius of 3, and an Edge strength of 14. The Discrepancy shown is &amp;quot;0&amp;quot;, so this is the &amp;quot;expected&amp;quot; radius. But why is there not an effect at radius=4, with HE strength=4 (2-6 dmg)? Of course this would have no impact on terrain and only a small impact on personnel. Are we just ignoring this radius=4 effect, or is it actually &amp;quot;crimped&amp;quot; down to zero by the game engine? The issue came up because I was comparing the gross total damage of AC-HE and HC-HE. HC-HE is stated as being &amp;quot;crimped&amp;quot; to radius=3, with Edge HE=22. Whereas you would expect it to propagate out to radius=4, HE=12 and radius=5, HE=2 (dmg 1-3, almost no chance of doing any damage to a unit). &lt;br /&gt;
&lt;br /&gt;
Could someone explain this in a bit more detail? Thanks! [[User:Spike|Spike]] 09:14, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
:First see picture to the right. This is the actual pattern produced by the Auto-Cannon&#039;s HE round (44HE) and the Heavy Cannon&#039;s round (HE52). (Technically, the pattern is the same for any projectile explosion between 40-59 inclusive). Any tiles which are damaged in my pic are also the tiles where units take damage too. My guess for the reason why the blast doesn&#039;t propagate further than what is expected is due to the [[Explosions#Distance_from_Ground_Zero|equation used]]. The walking TU method models how explosions are applied to units pretty close. Unfortunately, how the game models something is not always what is expected. --[[User:Zombie|Zombie]] 10:27, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
Thanks, that helped a lot, especially the reference to the walking TU rule - I had gotten that wrong. In fact I have also got it wrong in my firepower models, because I thought that for 4-square units, the 4th square would be at GZ+2, but in fact all 3 extra squares are at GZ+1. &lt;br /&gt;
&lt;br /&gt;
I&#039;m still not clear why AC-HE is crimped at radius=3, HE=14, and does not propagate out to radius=4, HE=4. Does your desert test terrain have 0 HE block, 1 strength? In other words does it show any square where a unit would take any damage? [[User:Spike|Spike]] 10:59, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
:Well, I&#039;m using unaltered desert terrain which has 0 HEB, 5 &amp;quot;Base&amp;quot; Armor and 25 &amp;quot;Death&amp;quot; Armor. Suppose I could use Bomb Bloke&#039;s numerical testing tileset for this as his armor strengths are all custom edited and have numbers to show tile damage. But, I might just use my flat terrain map pack and edit the MCD values so that everything is 0. Still, terrain shouldn&#039;t have any effect on damage to units in an explosion if the ground tiles have 0 HEB as this lets the explosion go past unhindered (except for distance of course). Armor only determines when a tile sprite should change it&#039;s appearance. Not too sure of the exact reason why the explosion doesn&#039;t go out further than what is expected though. My only guess is that integer rounding plays a pretty big role here and it may be negating the propagation when the damage gets below 10 Average (or 5 for the min?). Sorry I can&#039;t be more helpful at this point. --[[User:Zombie|Zombie]] 11:28, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
OK that makes sense. With the Desert Base armour at 5, any residual HE effect below 10 would have no effect on the terrain. It does suggest that the HC-HE radius 4, HE=12 is definitely crimped off, since HE=12 would be enough to damage the tiles at radius=4. But I suppose it&#039;s &#039;&#039;possible&#039;&#039; that the AC-HE radius 4, HE=4, is still present but undetected on the desert tile map. Since it does a maximum of 6 damage, you would very rarely see damage even to a unit. But unless the AC-HE is less constrained than the HC-HE, which would make no sense at all, there is no effect at all from AC-HE at radius=4 - not even against units. [[User:Spike|Spike]] 11:37, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
:: The capped explosion radii is even more apparent for Blaster Bombs. Blaster bombs have an edge strength of 90, so very often someone RIGHT on the border of the blast gets killed, while someone just outside the blast radius is totally unharmed. ; Actually, I did some experiments here, and I found that blast radius seems to be, for most weapons, ((Power/10)/2)+1 = (Power/20)+1. (rounded down) (radii  Why /10 and /2? The /10 comes in because explosive power is reduced by 10 for each square distance from the epicentre. The +1 comes in because even an explosion with power of 0 must occur in the tile it hits, giving a minimum radius of 1. The /2 comes in because terrain takes consistent 50% damage from explosives. Unfortunatly, I suspect there was some programming formula logic inconsistencies here, because the 10 point distance reduction is applied BEFORE the 50% damage reduction resulting in &amp;quot;edge&amp;quot;... otherwise, we would have a smooth terrain destruction graph. On the other hand, currently terrain damage is consistent with unit damage. Hmm... So, guys, no, basically nothing to do with integer rounding. (I know all this cause I love making the boom boom booms.) Try editting different weapon power with an editor and you will get interesting results. [[User:Jasonred|Jasonred]] 14:48, 28 February 2009 (CST)&lt;br /&gt;
&lt;br /&gt;
We already did tests on this quite extensively. The equation can be found [[Explosions#Hacking_HE_versus_Blast_Diameters|here]], and integer rounding &amp;lt;b&amp;gt;does&amp;lt;/b&amp;gt; play a role. --[[User:Zombie|Zombie]] 15:29, 28 February 2009 (CST)&lt;/div&gt;</summary>
		<author><name>Epiceuropean</name></author>
	</entry>
</feed>