Go Back   Novahq.net Forum > Games > Delta Force
FAQ Community Calendar Today's Posts Search

Delta Force Anything to do with the Delta Force series of games, DF1, DF2, LW, TFD, BHD, DFX, AF etc.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 06-29-2017, 10:27 PM
Guest001 is offline Guest001
Registered User

Join Date: Aug 2008
Posts: 4,971

Mapping With The MEd - AI Detection

In a previous post I wrote about the process of working out how to detect player deaths without problems.

Though after recent events I decided this topic needed reposting in the DFX2 forum...

The short story is, during the latest round of mapping for DFX2 I discovered quite a few new things.

One of them being there's a real difference between the statements "is not alive" and "is dead".

Particularly when it comes to the way the AI is detected by the engine.

This led me to discovering a new script to detect player deaths accurately.

The resulting code is so simple that I nearly fell over when it worked.

Code:
;Count Player Deaths
if never() then
set(v1,0) // Triggers once then resets
set(v2,0) // Count 1 adds
set(v3,0) // Count 2 Subtracts
endif

if not ssnalive(player) then
set(v1,1)
endif

if eq(v1,1) then
set(v1,0)
endif
; Use chain to trigger once each time the variable flips - link will keep counting
if chain(1) then
add(v2,1)
sub(v3,1)
endif
Reply With Quote
  #2  
Old 02-12-2018, 03:56 PM
Oscarmike247 is offline Oscarmike247
Oscarmike247's Avatar
Registered User

Join Date: Feb 2018
Posts: 229

Interesting. I know this is the same script you shared with me earlier. Thanks.

So what exactly is the difference between "not alive" and "dead" ?
Reply With Quote
  #3  
Old 02-12-2018, 05:37 PM
Guest001 is offline Guest001
Registered User

Join Date: Aug 2008
Posts: 4,971

Seems like this is a distinction for finer scripting control, you could argue that their meanings are different not.

Dead - Not Dead vs Alive - Not Alive

So I think it goes something like this:

You can be dead in area 1 because there's a body there (you just died) to detect but you can't be not alive in area 1 because you're not there (you're not alive).
Reply With Quote
  #4  
Old 02-12-2018, 05:56 PM
Oscarmike247 is offline Oscarmike247
Oscarmike247's Avatar
Registered User

Join Date: Feb 2018
Posts: 229

Quote:
Originally Posted by stompem View Post
Seems like this is a distinction for finer scripting control, you could argue that their meanings are different not.

Dead - Not Dead vs Alive - Not Alive

So I think it goes something like this:

You can be dead in area 1 because there's a body there (you just died) to detect but you can't be not alive in area 1 because you're not there (you're not alive).
interesting.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 05:32 PM.




Powered by vBulletin®