664a08baf4081

664a08bb0039c
1 Guest is here.
 

Topic: Newbie DML help Read 1023 times  

664a08bb00c53sarge945

664a08bb00ccd
Hi

I am working on a quick test project to learn DML editing.

I am trying to make cameras invulnerable to all damage except for EMP and Armor Piercing rounds.

I am able to make the cameras invulnerable by removing their receptron for standard damage and their Mechanical Vulnerability metaprop

But when I add my own metaprop called "Camera Armor", which should add 2 receptrons (for EMP and AP damage), cameras are completely invulnerable regardless. I spawn a camera in the map as well as an EMP rifle and it does no damage at all.

Is there something wrong with my DML?

Ideally I would hope there's a way to remove a receptron from a metaprop so I can just make a new one that inherits from Invulnerable, but removes it's EMP and AP damage immunitues, but I have been told thats impossible

gamesys.dml:
Code: [Select]
DML1

//New metaprop for Camera Armour
CreateArch "Vulnerabilities" "Camera Armor"

//Add vulnerabilities to Camera Armor
//It's invulnerable to everything except AP Rounds, Energy, EMP, High Explosives, and Electricity
+Receptron "Camera Armor" "EMP"
{
Min 0
Max None

Target Me
    Agent Source

    Effect "Amplify"
    {
        "Multiply by" 4.00
        "Then add" 0.00
    }
}
+Receptron "Camera Armor" "Armor Piercing Impact"
{
Min 0
Max None

Target Me
    Agent Source

    Effect "Amplify"
    {
        "Multiply by" 2.00
        "Then add" 0.00
    }
}

-Receptron -367 "Standard Impact" 00200009 //Remove default bullet damage
-MetaProp -367 "Mechanical Vulnerability" //Remove old "Mechanical Vulnerability" weaknesses
+MetaProp -367 "Camera Armor" //Add Camera Armour
« Last Edit: 30. April 2022, 07:48:23 by sarge945 »

664a08bb00e91voodoo47

664a08bb00ef0
yes, you cannot do that with metaprops. anyway, no time to mess around with the dml today, try this;

1) set everything up in the editor, see whether it works as intended
2) if it does, move the setup to dml
3) load the dml into the editor (clean level, dbmod_load in the command window), see whether the setup still works
4) if it does (work in the editor), run it with the game exe and see whether it still works
5) ..profit?

664a08bb00ffbsarge945

664a08bb0104e
Turns out I was using an amplify damage receptron, rather than an actual damage effect

Turns out I needed this instead:

Code: [Select]
+Receptron "Camera Armor" "Armor Piercing Impact"
{
Min 0
Max None

Target Me
Agent Source

Effect "damage"
{
"Damage Type" 0
"Use stimulus as type" TRUE
"Multiply By" 1.00
"Then Add" 0
}
}

Now I just need to test it.

Do you know how to actually spawn in a different map? Like travel to command1, etc, from within the game itself?

664a08bb01120voodoo47

664a08bb0116d
if you want to start in a certain level, just put first_level whatever.mis into cam.cfg, replacing whatever with the actual level name (ops1, for example), and then start a new game.
Acknowledged by: sarge945

664a08bb012c5sarge945

664a08bb01314
Okay, I got it working, but it involved modifying EVERY DAMN CAMERA IN THE GAME, since I had to remove their damage vulnerabilities from the base archetype and re-add it manually to every camera in the game

Every camera from command1 upwards should now be immune to all non-EMP or AP attacks. Cameras below this deck are as-normal

I was going to make them RED to show that they are serious business (would preferably want an awesome "armoured camera" model, but oh well), but they reset to green once they stop detecting you, so I scrapped it. I assume their model is changed via the alarm script, which is above my pay grade to edit.

The reason I haven't put this in it's own thread yet is because, surely there must be a better way of doing this?


[Indestructible Cameras.7z expired]

664a08bb01403voodoo47

664a08bb01450
aha, if you want just some cameras to be invulnerable without adding a new archetype, then yeah, shenanigans will be required.

off the top of my head, it should be possible to make NVscript check for a qvar upon level start and if passed, remove/add props or metas to all concretes. bit of a moot point though, as you've already completed the mod via mission dmls.

664a08bb014fesarge945

664a08bb0154b
It might be technically moot, but I am still interested because I feel it would improve my knowledge, and also help to make the mod more compatible.

Do you have an example script?

664a08bb0188fvoodoo47

664a08bb018e3
no, not yet. but I'm thinking about it, as I would maybe want to redo and expand the pistol hybrid mod, and use exactly that setup to make things smart. anyway, it's really just digging around NVscript docs or asking NV directly and finding out whether NVRelayTrap/NVMetaTrap supports a qvar check, and anybody can do that. my bet is that it does, because why not.

Quote by NVscript docs:
NVTrigQVar(NVTrigger)
An improved version of the standard TrigQVar script.
Watches the state of a quest variable, and sends TurnOn when its value changes to satisfy the formula specified in the Trap->Quest Var property. If the value changes so that it no longer satisfies the formula, it sends TurnOff instead.

For details of how to use the Trap->Quest Var property, see Telliamed's excellent guide.
NVTrigQVar and NVTrapSetQVar support a few new features, however.
Firstly, you can use the name of a quest variable in place of the numerical argument, in which case the value of that variable will be used instead. For example, you could use >QVar2:QVar1 to check if Qvar1 is greater than QVar2. You can also place a question mark ('?') in front of the name of this qvar to give a random number between zero and its value.
so for example me changing all shotgun hybrids to fusion cannon hybrids for the duration of the give VB engine control to Shodan quest would be pretty trivial.
« Last Edit: 01. May 2022, 09:15:16 by voodoo47 »

664a08bb01f39ThiefsieFool

664a08bb01f93
so for example me changing all shotgun hybrids to fusion cannon hybrids for the duration of the give VB engine control to Shodan quest would be pretty trivial.
now why does this sound like something I would actually like to see in action?
Acknowledged by: voodoo47

664a08bb02496sarge945

664a08bb024ea
no, not yet. but I'm thinking about it, as I would maybe want to redo and expand the pistol hybrid mod, and use exactly that setup to make things smart. anyway, it's really just digging around NVscript docs or asking NV directly and finding out whether NVRelayTrap/NVMetaTrap supports a qvar check, and anybody can do that. my bet is that it does, because why not.
so for example me changing all shotgun hybrids to fusion cannon hybrids for the duration of the give VB engine control to Shodan quest would be pretty trivial.

I'm confused, I see docs about squirrel script in the SS2 docs folder. Is that the same as NVScript, or are there two completely independent script engines within newdark?

now why does this sound like something I would actually like to see in action?

Having more harder enemies during the "return to an earlier area" parts of the game would be nice actually. I know engineering eventually adds assassins, but the difficulty sort of caps off eventually

664a08bb02676voodoo47

664a08bb026c7
NVscript is a pre-compiled script set you can use to do.. stuff. so basically, you have a bunch of tools you can use to create the setups you want, you can you use one script to send a signal from one object to another, where another script will receive it and do another thing, and you can link stuff and tell them what to do until they do what you want them to do. the limitation is they only can do what they are meant to do. Squirrel, which can be used for the same purposes, is basically a tool you can use to create those scripts, so you can code in anything you want, as long as you actually can code it, pretty much no restrictions. see \SS2\osm\NVScript.html for NVscript info. and this as well.

the engineering assassins are actually spawned by special ecologies that are only active during the already mentioned give Shodan core control quest (funnily enough, this never worked properly in cd vanilla). so it's not like they just start to spawn replacing the native baddies once you reach a certain part of the game.
« Last Edit: 02. May 2022, 08:31:32 by voodoo47 »
1 Guest is here.
Unless you're a sinner. You're not a sinner, right? Right?!
Contact SMF 2.0.19 | SMF © 2016, Simple Machines | Terms and Policies
FEEP
664a08bb0293d