663695396f983

663695397011d
2 Guests are here.
 

Topic: SS2 Big Droid Immortality Protocol
Page: « 1 [2]
Read 11335 times  

66369539709c3ZylonBane

6636953970a46
I can't imagine that not looking very silly.

66369539710a5unn_atropos

6636953971111
Looks cool.  :)
Can the droid fire it? Can you exchange them when they are broken? Different ammunition types?  :lordy:

66369539711favoodoo47

6636953971256
they are dummy guns, just to see how they would look attached to the droid. also, looks like I had some youtube vid playing in the background when recording.

66369539713abGuyFawkesGaming

66369539713fe
So I take the dark scripting engine restricts the modifiable "tag" to weapon objects only. I see now why the repairman mod lists broken turrets as containers.
Anyways, not too bad voodoo. I was expecting much worse. Regardless, what if instead of guns attached to it's hands it had a discrete "access panel" dummy gun on it's back?

6636953971534voodoo47

6636953971583
it's just the original script, which only handles weapons - so to be able to modify other objects, you would have to write a custom squirrel script that would do whatever you want to do with the droid or any other target object. not sure what do you mean by those broken turrets - they are containers (with loot), so they should be registered as such.

anyway, no extended functionality from my side anytime soon, as it will be years before I'll be able to do anything more complex in squirrel - I have no coding background, so trying to learn these things takes immense amount of time and effort.
« Last Edit: 08. May 2018, 19:11:44 by voodoo47 »

663695397168aGuyFawkesGaming

66369539716e3
Ok, so it is modifiable, just complex. I'm no expert programmer, but I was wondering why you didn't just make npcs modifiable/hackable, then 'tag' turrets and droids so only they can be modified, and hacked ones at that. Never touched squirrel, I'm more into Python and HTML, but if it's more complex then it sounds I understand.

For the turrets, I was actually referring to the window that pops up when you select the upper half to repair it; the side says "container" rather than "security".

66369539717acvoodoo47

66369539717fd
I have no idea whether it's more difficult - as I don't know any coding language, I don't have anything I could compare it to.

I actually have no idea why the rim on the repair interface says "container", will investigate a bit. //not fixable by simple means.
« Last Edit: 03. July 2021, 07:38:01 by voodoo47 »

6636953971a52GuyFawkesGaming

6636953971aa8
I've managed to hack the repairman mod's 'turretheal.nut' script to allow droids to be repaired. It was pretty simple actually; their was a short "list" with only 2 entries; allow turrets to be repaired and allow guns. Adding the proper entries for the droids allowed them to be repairable:
Code: [Select]
                // maintenance droids
else if (Object.InheritsFrom(fixObj, "Maintenance")) {
hp = Property.Get(fixObj, "HitPoints");
maxHP = Property.Get(fixObj, "MAX_HP");
if (playerMaintSkill < objSkillRequired) {
addMiscText("WrenchierSkillReq", "Maintaining this device requires a skill of %d.", objSkillRequired);
}
else if (hp >= maxHP) {
addMiscText("WrenchierUnused", "Device already in good condition.");
}
else {
// repair droid 5 HP per point of maint skill (default droids have a max HP of 100)
hp += playerMaintSkill * 5;
if (hp > maxHP) {
hp = maxHP;
}
Property.SetSimple(fixObj, "HitPoints", hp);
consumeTool();
}
}
// security droids
else if (Object.InheritsFrom(fixObj, "Security")) {
hp = Property.Get(fixObj, "HitPoints");
maxHP = Property.Get(fixObj, "MAX_HP");
if (playerMaintSkill < objSkillRequired) {
addMiscText("WrenchierSkillReq", "Maintaining this device requires a skill of %d.", objSkillRequired);
}
else if (hp >= maxHP) {
addMiscText("WrenchierUnused", "Device already in good condition.");
}
else {
// repair droid 5 HP per point of maint skill (default droids have a max HP of 160)
hp += playerMaintSkill * 5;
if (hp > maxHP) {
hp = maxHP;
}
Property.SetSimple(fixObj, "HitPoints", hp);
consumeTool();
}
}
// assault droids
else if (Object.InheritsFrom(fixObj, "Assault")) {
hp = Property.Get(fixObj, "HitPoints");
maxHP = Property.Get(fixObj, "MAX_HP");
if (playerMaintSkill < objSkillRequired) {
addMiscText("WrenchierSkillReq", "Maintaining this device requires a skill of %d.", objSkillRequired);
}
else if (hp >= maxHP) {
addMiscText("WrenchierUnused", "Device already in good condition.");
}
else {
// repair droid 5 HP per point of maint skill (default droids have a max HP of 200)
hp += playerMaintSkill * 5;
if (hp > maxHP) {
hp = maxHP;
}
Property.SetSimple(fixObj, "HitPoints", hp);
consumeTool();
}
}
Don't know if it has any negative side effects or if I made any mistakes so you may want to check it.

6636953971b5aZylonBane

6636953971bae
All that duplicated code because you don't know how to do OR in an if statement. Sigh.

6636953971c51GuyFawkesGaming

6636953971ca0
Hey, I said I've done programming before. Never said I was a pro.
Acknowledged by: JML
663695397226b
All that duplicated code because you don't know how to do OR in an if statement. Sigh.
What about quickly simplifying the code so people in this forum can actually learn something by it? Having a code that works and having a simplified code that also works is super easy to learn from. :thumb:

663695397258bZylonBane

66369539725fd
Hey, I said I've done programming before. Never said I was a pro.
This is like someone trying to make toast, burning their house down, then claiming "I never said I was a pro!" Booleans in conditionals are barely one step up from HELLO WORLD. If you actually have Python experience, you should already know how to do this.

else if (Object.InheritsFrom(fixObj, "Turrets") || Object.InheritsFrom(fixObj, "Maintenance") || Object.InheritsFrom(fixObj, "Security") || Object.InheritsFrom(fixObj, "Assault")) {

There. Just modify one line of code from the original script.

6636953972742GuyFawkesGaming

66369539727ab
Considering the game didn't crash from my method, I'd say it's more like someone trying to cook an egg but not knowing what a spatula is and using their hands instead (imagine the screaming).  :P
Acknowledged by: JML

6636953972a89GuyFawkesGaming

6636953972ada
After observing the hacked droids more, I've noticed one extremely annoying issue. There are times when a droid is being attacked but it will just sit there frozen and not attack it's enemy until it's finally destroyed. Not sure what causes this and it doesn't always happen, but wow. I'd also suggest making the droids able to see in the dark. It makes no scene that turrets can activate and attack you in dark places but droids can't, in addition to all the "infrared" messages in the security monitors. I still think making them modifiable would be a good idea but I can wait on that.

6636953972b8bvoodoo47

6636953972bdf
it  certainly would be possible to make all AIs ignore how much light is on other AIs. will maybe have a look once I have more time.

6636953972ca1voodoo47

6636953972cfb
updated to 1.01, the mod is now no longer SCP exclusive. requires a game patched with SS2tool (NewDark v2.48+, NVscript loaded), should work with SCP, vanilla, Secmod, Alyamod etc.
Acknowledged by: JML

6636953972e58Deu sex

6636953972ea7
Yo, I've been digging this mod and it's really cool! However I may have one complain, could it be possible that the robots you repaired follow you a bit? They are kind of static otherwise.
Another minor thing, but while not everything requires the same skill level, everything costs 50 nanites to repair, could it be slightly less expensive for low tier, this for mid tier, and slightly more expensive for high tier? (something along those lines).

6636953972febvoodoo47

6636953973052
I decided against follow as I think it would be too good (right now, they should just patrol their area). prices can be changed easily by literally anyone who can edit the dml with a text editor.

663695397318aDeu sex

66369539731e2
I'll do that then, as for following I can totally understand the argument of robots being too good (even if their movements would be limited since they can't travel between loadings and can't use gravlifts), though I wish a middleground could exist.
I'll try to mod it out from the files though, just to see if it would be interesting.

-> damn I looked at the files, but reading them I can get a vague idea what is going on in there but I have 0 clue on how to script on SS2 :D I was expecting something like "FollowPlayer=FALSE" in the entity's parameters lol.
The cost values can be modified easily indeed though.
« Last Edit: 21. January 2021, 19:31:49 by Deu sex »

Your name:
This box must be left blank:

A familiar door code with 3 digits:
2 Guests are here.
Philosophy is the talk on a cereal box.
Contact SMF 2.0.19 | SMF © 2016, Simple Machines | Terms and Policies
FEEP
6636953973f78