Author Topic: [Documentation] Active camouflage and predator vision ;-)  (Read 48208 times)

Offline Surrealistik

  • Colonel
  • ****
  • Posts: 486
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #30 on: August 16, 2016, 07:59:07 pm »
Well, I'm open to suggestions how to handle this invisibility un-hacking. At least the basterds will be hittable in melee, which immunity was a major pain. I still think that there should be vision mode that allows some enemies to see through smoke, else it's all too easy. Also, scanners... Detecting invisibles was their main boon. Unless I will make some truly ethereal enemies which are fully unhittable, except by explosives, and need to be first relieved of their ethereal status by a well-placed explosion...

I'd be cool with a 'psi-o-vision' or whatever which ignores typical LoS obstacles, but depends on both Psi Mastery of the spotter (or Psi Strength if no Skill), and the Psi Strength of those that would be spotted to determine detection range: those stronger with the force can be detected further away; it also adds at least a small upside to using soldiers that have weaker Psi vs Celatids and Star Gods, whereas you'd be straight up pants on head retarded to do so normally in the latter case.

Like I said, you could give Ethereals a detection range of 1 to 3 (this would allow for range extending items/armours) and the gameplay would be about the same except without the ridiculousness of the current hack.

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11731
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Active camouflage and predator vision ;-)
« Reply #31 on: August 16, 2016, 08:12:08 pm »
I'd be cool with a 'psi-o-vision'

That's pretty much what I wrote on the Solar's Wishlist:

Quote
Psionic Sense: Used by certain alien races (some of them only use this vision mode, like Celatids). Has a separate, definable radius (generally much smaller than normal vision). Works through walls and such. Does not pick up mechanical units, or units which are defined not to show up on the psi vision. Does not reveal terrain.

Do you think this is fine?

Like I said, you could give Ethereals a detection range of 1 to 3 (this would allow for range extending items/armours) and the gameplay would be about the same except without the ridiculousness of the current hack.

I wonder if you could give them a detection range of 0.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9104
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #32 on: August 16, 2016, 08:33:58 pm »
I don't like these idea... as I wrote in Solar's thread already.

Furthermore, FOV calculation is expensive and called very often. Please keep that in mind when designing new crazy ways of detection (like can see through 2 thin walls, 1 thick wall, 1 car, 3 phone booths, but can't see through trees, rocks and hot-blood humanoids).

If you want it SO MUCH, I can probably do two flags:
- canSeeThroughSmoke (i.e. simple heat-vision)
- canSeeThroughEverything (i.e. simple psi-vision, maybe with max distance)

...but anything else is beyond my pain threshold.

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11731
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Active camouflage and predator vision ;-)
« Reply #33 on: August 16, 2016, 09:33:33 pm »
Yeah, I understand and respect this. My job is to pop ideas, yours is to... uh... keep them reality relevant. :)

What I think is the ore here is to break the uniform sight system a bit. It doesn't really matter how, as long as there is some variation.
Your ideas are good examples and I think they're good enough. One thing I can suggest in addition is differentiating between types of vision when it comes to camouflage, so for example a unit can be visible normally with eyes and only from 5 tiles or less with psi. If we have this, I think we have everything.

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #34 on: August 16, 2016, 09:44:15 pm »
I don't like these idea... as I wrote in Solar's thread already.

Furthermore, FOV calculation is expensive and called very often. Please keep that in mind when designing new crazy ways of detection (like can see through 2 thin walls, 1 thick wall, 1 car, 3 phone booths, but can't see through trees, rocks and hot-blood humanoids).

If you want it SO MUCH, I can probably do two flags:
- canSeeThroughSmoke (i.e. simple heat-vision)
- canSeeThroughEverything (i.e. simple psi-vision, maybe with max distance)

...but anything else is beyond my pain threshold.
I plan do it after I finish new lighting. Overall I don't plan change how tracking part (that is expensive) work but how final calculation work.
Instead of intruding multiple new properties scripts will handle it. Otherwise would be huge mess, probably 20 would be needed if you would want support most of proposed functionality. Not mentioning mess in code that will need to handle all this cases.
Visibility scripts are superior because from code perspective it only one function call and all complexity will be in rulesets. And this lot less complex because you will not need handle all possible use cases, only what you will use.

Probably grate example is new corpse graphic by ivandogovich and probably he don't use even 10% of capabilities of it (animations, and handling more conditions).

Offline ivandogovich

  • Commander
  • *****
  • Posts: 2381
  • X-Com Afficionado
    • View Profile
    • Ivan Dogovich Youtube
Re: Active camouflage and predator vision ;-)
« Reply #35 on: August 16, 2016, 09:53:06 pm »
Probably grate example is new corpse graphic by ivandogovich and probably he don't use even 10% of capabilities of it (animations, and handling more conditions).
Yeah, but I wouldn't mind doing some animations. ;)  ... make some of those Zzs wiggle, etc, I just don't know how. </OffTopic>

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11731
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Active camouflage and predator vision ;-)
« Reply #36 on: August 16, 2016, 10:01:14 pm »
Yeah, but I wouldn't mind doing some animations. ;)  ... make some of those Zzs wiggle, etc, I just don't know how. </OffTopic>

Sleeping Catgirls will be cute.

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #37 on: August 16, 2016, 10:53:26 pm »
Yeah, but I wouldn't mind doing some animations. ;)  ... make some of those Zzs wiggle, etc, I just don't know how. </OffTopic>
If you don't mind copy all corpses 2x then you can use `anim_frame` value in floor item script to toggle between two versions.
Similar to how parrot mod work.
Probably this isn't good solution but is doable. I plan in future to allow drawing multiple surfaces at once. With this you will only need add dead/alive corpse and Zzz +++ will be from separate surface.

Offline khade

  • Commander
  • *****
  • Posts: 509
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #38 on: August 16, 2016, 11:13:26 pm »
Might be a good idea to have the camouflage effect work differently for other vision types, like the Guerilla suit lowering normal vision but not psi or heat, anything with active reactors being MORE visible to heat, maybe even through walls if that ends up not being too hard to set up, psi blocking outfits working on psi but not on the others, Mud helping against heat vision.  heh, naked and covered in mud would be a funny way to beat some enemies, too bad the Star Gods wouldn't be among those.

If we can get the items that provide benefits, we could even avoid having to create new outfits, or at least not as many.

Offline Surrealistik

  • Colonel
  • ****
  • Posts: 486
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #39 on: August 17, 2016, 01:46:04 am »
Might be a good idea to have the camouflage effect work differently for other vision types, like the Guerilla suit lowering normal vision but not psi or heat, anything with active reactors being MORE visible to heat, maybe even through walls if that ends up not being too hard to set up, psi blocking outfits working on psi but not on the others, Mud helping against heat vision.  heh, naked and covered in mud would be a funny way to beat some enemies, too bad the Star Gods wouldn't be among those.

If we can get the items that provide benefits, we could even avoid having to create new outfits, or at least not as many.

For sure; I definitely think that camo/detection modifiers both pro and con should be specific to vision types if possible.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9104
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #40 on: August 17, 2016, 08:59:05 am »
I plan do it after I finish new lighting. Overall I don't plan change how tracking part (that is expensive) work but how final calculation work.
Instead of intruding multiple new properties scripts will handle it. Otherwise would be huge mess, probably 20 would be needed if you would want support most of proposed functionality. Not mentioning mess in code that will need to handle all this cases.
Visibility scripts are superior because from code perspective it only one function call and all complexity will be in rulesets. And this lot less complex because you will not need handle all possible use cases, only what you will use.

Probably grate example is new corpse graphic by ivandogovich and probably he don't use even 10% of capabilities of it (animations, and handling more conditions).

I think I can do the simple heat and psi vision with just 2 armor attributes and less than 20 lines of code in FOV calc function.

I agree that scripts will be superior and we can remove my attributes and replace them with scripts once done. My ramshackle attributes could be used for experimentation and balancing until you are ready with the scripts.

That being said, I'd like to say more about my feelings towards your scripts:
- compared to let's say mapScript or missionScript, your scripts are much more advanced... slowly approaching the status of programming language, not just script
- they give enormous power... but I am afraid that currently you are the only one who can write them
- in my professional life, I have also created (or at least helped create) two such scripting engines for our customers, because their requirements were to be as flexible as possible and change for example some calculations on the fly without having to upgrade our software... at the end, both cases are a disaster... even though there are IT people there, nobody (and I mean nobody!) has learned the scripting language and writing of scripts ended up being our responsibility... the same may happen to you, just saying; also from time to time some individuals give it a try and most likely break it... and then they blame us that our software doesn't work... without telling us that they have changed the scripts of course.

You say that new corpse graphic by Ivan is a great example... but as far as I know, you have actually written the script for Ivan, not Ivan himself. Anyone who can write that script, can also change the source code to do the same functionality, even with less code than in the script (I guess I could do the alt corpses with less than 20 lines of C++ code).

Personally, I am adding new functions only if I am convinced that they will be used by someone... that's why I mostly add stuff requested by Dioxine and Solar... because I know they would use it... and mostly ignore stuff from fantasies of other people (like Surrealistic for example... btw. I am still waiting for that alpha chryssalid mod, if you're reading this). And writing a cool scripting engine, which nobody will be able or willing to use, is a scary thought for me. And I speak from real experience.

I definitely didn't want to discourage you from any of the work you are doing now... just warning you what might happen... be prepared for it. I hope somebody will use it, it will be a huge success and I will be proven wrong.

Offline Surrealistik

  • Colonel
  • ****
  • Posts: 486
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #41 on: August 17, 2016, 09:12:38 am »
Personally, I am adding new functions only if I am convinced that they will be used by someone... that's why I mostly add stuff requested by Dioxine and Solar... because I know they would use it... and mostly ignore stuff from fantasies of other people (like Surrealistic for example... btw. I am still waiting for that alpha chryssalid mod, if you're reading this).

Having item (not exclusively armour) based counters to the concealment was an important part of the concept. Beyond that Dioxine has found uses for the mechanic, so regardless of whether or not I specifically make the Chryssalid (which Dioxine has said he'll create and add anyways), why come at me bro? I appreciate the work, it's seeing use, and I look forward both to its imminent official implementation into Piratez.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9104
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #42 on: August 17, 2016, 09:19:07 am »
Having item (not exclusively armour) based counters to the concealment was an important part of the concept. Beyond that Dioxine has found uses for the mechanic, so regardless of whether or not I specifically make the Chryssalid (which Dioxine has said he'll create and add anyways), why come at me bro? I appreciate the work, it's seeing use, and I look forward both to its imminent official implementation into Piratez.

Just one question: if I implement item (not armor) based counter, will you implement the mod?

And sorry that I used you as example (you just came to mind first, because it was the most recent case). Didn't want to "come at you"... although reading my previous post, I really did :( I should always read my post again before posting.

Offline Surrealistik

  • Colonel
  • ****
  • Posts: 486
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #43 on: August 17, 2016, 09:23:50 am »
Sure. Keep in mind that I'm totally new to this modding business; where would I go to create such a thing? How would I draft it into the game such that it's in addition to the aliens that exist rather than replacing one, like the existing Chryssalid, wholesale?

And it's fine; it just seemed like there were residual hard feelings from when we clashed before.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9104
    • View Profile
Re: Active camouflage and predator vision ;-)
« Reply #44 on: August 17, 2016, 09:31:31 am »
Sure. Keep in mind that I'm totally new to this modding business; where would I go to create such a thing? How would I draft it into the game such that it's in addition to the aliens that exist rather than replacing one, like the existing Chryssalid, wholesale?

And it's fine; it just seemed like there were residual hard feelings from when we clashed before.

I guess the best would be to study a few existing small mods.

The basic idea is:
- mod adds new stuff or rewrites existing stuff
- base game is loaded first and then all mods in order defined by the user (if mod B is loaded after mod A, it can rewrite A's stuff if they add/modify the same stuff)

Technically:
- put a mod in a separate directory in mods folder (never mod anything by editing base game files!)
- find the definition of chryssalid in base game
- find the definition of its armor
- copy and rename that armor... then add the new attributes
- copy and rename the old chryssalid... then change its armor to new armor
- lastly, add that new chryssalid into some of the alien deployments... so that we can actually meet it in combat

If you want to start with small steps:
- just find the chryssalid, its armor and change that armor (without making a copy)... then balance the stats as you wish