Photon's Modding Adventures


Recommended Posts

9 hours ago, Cyberboy2000 said:

In the case of icebreak unit is the Buster Chip (abilityOwner) and userUnit is the agent carrying the item, but in your case it's the agent that is abilityOwner.

Some clarification: the new icebreak is not attached to the agent augment. The augment works in the same way ones like Sharp's do: the ability checks for the presence of the augment and then modifies its functionality based on that.

Its a bit long, but I'll just post the scripts if anyone wants to look at them. Bear in mind this is my general purpose test mod, so modinit has some extra stuff in it:

mod_icebreak.lua

modinit.lua

Link to comment
Share on other sites

2 hours ago, PrismaticPhoton said:

Some clarification: the new icebreak is not attached to the agent augment. The augment works in the same way ones like Sharp's do: the ability checks for the presence of the augment and then modifies its functionality based on that.

Yes, that's what I meant. Take a look at how jackin does it.

acquireTargets = function( self, targets, game, sim, abilityOwner, unit )

When you're jackin in manually, abilityOwner and unit are the same thing, because agents have the jackin ability. If an agent picks up an Accelerator chip, which also has the jackin ability, abilityOwner and unit are no longer the same, because unit is still referring to the agent but abilityOwner is referring to the Accelerator Chip. You are using code that expects abilityOwner to be an item when it actually is an agent. Hope that clears things up.

Link to comment
Share on other sites

8 minutes ago, Cyberboy2000 said:

Yes, that's what I meant. Take a look at how jackin does it.


acquireTargets = function( self, targets, game, sim, abilityOwner, unit )

When you're jackin in manually, abilityOwner and unit are the same thing, because agents have the jackin ability. If an agent picks up an Accelerator chip, which also has the jackin ability, abilityOwner and unit are no longer the same, because unit is still referring to the agent but abilityOwner is referring to the Buster Chip. Your code is expecting abilityOwner to be an item when it actually gets passed an agent. Hope that clears things up.

I'm afraid I'm not following you. The agent never was an owner of icebreak, so I don't see how this applies. This augment is NOT like Tony's EMP; there is no "manual" icebreak going on. Its all through items, just like icebreak should expect.

Link to comment
Share on other sites

2 minutes ago, PrismaticPhoton said:

I'm afraid I'm not following you. The agent never was an owner of icebreak, so I don't see how this applies. This augment is NOT like Tony's EMP; there is no "manual" icebreak going on. Its all through items, just like icebreak should expect.

Ah, you are modifying the original icebreak is that it? Well looking at the code you uploaded it's clear what the problem is.

function Mod_icebreak:acquireTargets( self, targets, game, sim, unit )

Colon tells lua to insert self as the first parameter. All you have to do is either remove self as a parameter or replace the colon with a dot.

Link to comment
Share on other sites

1 minute ago, Cyberboy2000 said:

Colon tells lua to insert self as the first parameter. All you have to do is either remove self as a parameter or replace the colon with a dot.

Ah! I'm not overly familiar with Lua, so based on what I'd seen I just assumed that colons were the syntax for referencing functions. Oops!

Thanks!

Link to comment
Share on other sites

On 10.05.2017 at 4:14 AM, PrismaticPhoton said:

I'm trying to work on a "wireless" skill for an agent so they can interface with devices from a distance. Essentially, the ability to interact with a device should work in much the same way it does with Incognita programs: as long as you know the location of a device, you can interact with it.

Like buying from shops while being several rooms away? or just icebreak?

Link to comment
Share on other sites

7 hours ago, Shirsh said:

Like buying from shops while being several rooms away? or just icebreak?

Just icebreak. Wireless shopping would be interesting though! Like, you could have an augment where an agent crafts shop items by downloading a nearby fab's schematics or something (if we're trying to make sense, at least.)

Now that I've got everything pretty much working, I'll elaborate a bit more on this new agent I've been working on: Dolphin. Her story is that she was a former university student whose ambitions were more or less taken advantage of:

Spoiler

Sarah "Dolphin" Hale

    Sarah was once one of the most celebrated and anticipated university students in cranial technology. When Plastech awarded her a lucrative grant for her "Dolphin Radio" project--a transmitter converting brainwaves to data and vice versa,--her future looked to be set.
    However, after months of work and an important visit to one of Plastech's facilities, she inadvertently learned the truth: the corporation was planning to weaponize her technology as a form of "psionic" warfare. Overwhelmed by this prospect, she destroyed nearly all of her research and vanished overnight.
    Relentlessly hounded by the corps for her secrets, she eventually found refuge with Invisible. Though jaded by her past experiences, she still yearns to make the positive impact she once envisioned.

Dolphin's entire toolset revolves around her "Dolphin Transmitter" augment, supposedly the last of its kind, which allows her to use Buster Chips from range (currently thinking in the range of 4-5 tiles.)  She also has a specialized "Mask Buster," which simultaneously breaks 1 firewall and reveals hidden daemons. The thrust is that she's a local firewall buster with the ability to get around some trickier mainframe defenses.

As I've been playing through Endless and thinking about agent ideas, the question in my mind has been to the effect of "If I made this agent, would it actually change the way I played the game?" I think with Dolphin, she has several things going for her that, though somewhat situational, are noteworthy in distinguishing her:

  • She is the only agent in the game that can safely "Buster Chip" cameras without the help of other items (cloaks, holorig, etc.) This versatility extends to other situations where adjacent-space hacking may be difficult (drones--especially Null Drones,-- barrier units, etc.) 
  • Her "Mask Buster" not only differentiates her starting loadout from Archive Prism, but it gives her a ranged daemon scan. Again, this flexibility could be big if you aren't running the Sniffer program.
  • She could make for a soft Porticullis (2.0) counter.

I look at her a bit like Banks and her Crypto Computer augment: its situational, but when you need it, the impact it can have is monumental and well worth it. That being said, even when the range isn't necessary Buster Chips aren't particularly useless either! We'll see how testing goes: pairing her with Internationale is an obvious choice but I might want to explore less obvious synergies instead.

Link to comment
Share on other sites

I've been playing around with Dolphin, and so far I'm really happy with her. This is the starting loadout I ran: OnFile Nika, Dolphin, Fusion, Parasite. The camera busting point I made earlier does a great job of covering one of Parasite's primary weaknesses (stagnated movement.) Running this synergy can also mean plenty of PWR for Nika's attack-happy antics. It'll be interesting to see how things progress as I add more programs (might try running both Parasites) and look into diverting PWR into other avenues (Subdermal Cloak, higher-tier Volt Disruptors for Nika, etc.)

Link to comment
Share on other sites

The Custom Augments mod started an alternate ability for Internationale that uses her attack action to break 1 firewall at a long range (20 range is long, right?), and reduces her maximum movement by 1 AP.  It seems to be unfinished, though, greyed-out in the latest version.

I like your approach with Buster Chips better: more flexible and scaleable, shouldn't be hard to balance, and I love that it's a qualitative change.  Your Mask Buster sounds good too: synergistic and unique.  I would suggest having Dolphin's use of her augment take her attack action, curbing extreme abuse cases, still allowing her to Buster Chip adjacent devices as many times as she likes as normal.

Link to comment
Share on other sites

45 minutes ago, SteelCrow said:

The Custom Augments mod started an alternate ability for Internationale that uses her attack action to break 1 firewall at a long range (20 range is long, right?), and reduces her maximum movement by 1 AP.  It seems to be unfinished, though, greyed-out in the latest version.

Ah, didn't know about that one... this is what I get for showing up so late to the modding party. :p

46 minutes ago, SteelCrow said:

I like your approach with Buster Chips better: more flexible and scaleable, shouldn't be hard to balance, and I love that it's a qualitative change.  Your Mask Buster sounds good too: synergistic and unique.  I would suggest having Dolphin's use of her augment take her attack action, curbing extreme abuse cases, still allowing her to Buster Chip adjacent devices as many times as she likes as normal.

The attack consumation isn't something I'd thought of, and its actually a pretty good idea. I did have some concerns that late game she could become a firewall-breaking monster, especially if you run her with Torque Injectors (Buster Chip III's with range and 2 turn cooldowns? Yes please.) Making it consume an attack could prevent her from going completely ham, even if it might slow her down in some of the late-game dilemnas I mentioned above.

Link to comment
Share on other sites

6 hours ago, PrismaticPhoton said:

The attack consumation isn't something I'd thought of, and its actually a pretty good idea. I did have some concerns that late game she could become a firewall-breaking monster, especially if you run her with Torque Injectors (Buster Chip III's with range and 2 turn cooldowns? Yes please.) Making it consume an attack could prevent her from going completely ham, even if it might slow her down in some of the late-game dilemnas I mentioned above.

Another comment: Ranged Buster Chips can save a lot of AP, allowing her to cover ground very fast.  Without a limit she could become hyper-aggressive with little-to-no weaknesses.  I had a thought that this "Dolphin Transmitter" lets her be very useful without engaging in combat, so taking up her attack - thus discouraging combat - reminds me of the direction you were going with Manta.

Perhaps if you know how (I don't know how), you could make Buster Chips require Speed for her instead of Anarchy, if you want to inject more stealth into the mix.

Link to comment
Share on other sites

13 minutes ago, SteelCrow said:

Another comment: Ranged Buster Chips can save a lot of AP, allowing her to cover ground very fast.  Without a limit she could become hyper-aggressive with little-to-no weaknesses.  I had a thought that this "Dolphin Transmitter" lets her be very useful without engaging in combat, so taking up her attack - thus discouraging combat - reminds me of the direction you were going with Manta.

On that note, Net Downlink was another augment I thought might be really strong on her. With that and Torque Injectors, she could potentially do some crazy stuff... not that there aren't crazy-busted combos already (ever tried Subdermal Cloak and Chameleon Movement?) They make for a nice punch that make the game more fun; nonetheless, I still think the attack consumation is a smart idea, as even with that restriction I'm fairly confident she'll still be useful.

19 minutes ago, SteelCrow said:

Perhaps if you know how (I don't know how), you could make Buster Chips require Speed for her instead of Anarchy, if you want to inject more stealth into the mix.

Probably not as straightforward as the Anarchy-Econchip change I wrote up. Since buster chips aren't character-exclusive, the change would probably be in the requirement checking code. Then I'd have to somehow check for the Dolphin augment, verify the item in question is a buster chip, make sure the item tooltip changes appropriately from agent to agent, etc. I'd rather keep things consistent anyway since, as stated, the buster chips aren't character-exclusive.

Link to comment
Share on other sites

I've been running two different campaigns lately: one for testing Dolphin on Expert and one for my "Power Drip" revamp on Expert+. With the latter, one of the things I've noticed is that vanilla Power Drip seems boring in part because its so static: its just +1 PWR forever with no pros or cons. By adding the +2 threshold, there's a new incentive to play strategically with your PWR.

To further elaborate: the starting loadout I ran with the new Power Drip was Rapier, Archive Prism and Archive Internationale... with that last agent choice being something I considered pretty mediocre at one point. So many synergies:

  • Maintaining a +2 threshold on Power Drip essentially means I can keep the Projection Mesh up indefinitely.
  • Rapier keeps early PWR usage more economic, meaning I have a better chance to hit the threshold early.
  • Not only does Archive Internationale help offset late-mission Rapier, but it can also let me splurge on PWR costs near alarm level increases without having to sacrifice the Power Drip bonus.

In other words, I'm having a lot of fun with that playthrough. I picked up Abacus 1.0 too, so you could say I'm psuedo-testing it for Expert difficulty too (-1 starting PWR difference from vanilla Expert starting PWR.)

I still want to push a "Starting Loadout Remix" mod at some point. I'm less keen on making some of the other changes I mentioned earlier, but based on my conclusions with Power Drip so far, I have an idea for Faust:

Faust : +2 PWR per turn. Spawns a random daemon every time the alarm level increases.

Statistically, this is actually a nerf: 20% chance of spawning a daemon means 1 in 5 turns, which is one alarm level's worth of turns. However, if you increase the alarm level faster than normal, statistically you'll be seeing more daemons. But with the change you get more predictability, and I'd say this also gives more incentive to play in a quick, stealthy manner. Thoughts?

Link to comment
Share on other sites

While you're on Faust, make it so it activates daemons based on "sim:getTracker() % simdefs.TRACKER_INCREMENT == 0" calculation with "simdefs.TRG_START_TURN" trigger, not "simdefs.TRG_ALARM_STATE_CHANGE" trigger. This will make it continue spawning daemons after reaching maximum alarm level.

Link to comment
Share on other sites

2 hours ago, wodzu_93 said:

While you're on Faust, make it so it activates daemons based on "sim:getTracker() % simdefs.TRACKER_INCREMENT == 0" calculation with "simdefs.TRG_START_TURN" trigger, not "simdefs.TRG_ALARM_STATE_CHANGE" trigger. This will make it continue spawning daemons after reaching maximum alarm level.

That doesn't sound like fun to you? :p

Edit: Wait, if what you say is true, wouldn't that mean Archive Internationale generates 12 PWR per turn at max alarm level? I mean, maybe that IS how it is, but it sounds a bit over the top. :o

Link to comment
Share on other sites

Well, not quite. What I mean with "sim:getTracker() % simdefs.TRACKER_INCREMENT == 0", this performs "modulo" operation. The result is, anytime alarm tracker fills in to full circle, Daemon will be spawned, and it continues past alarm level 6. While graphically alarm tracker stops at 6, internally it continues to go up indefinetly. Archive Internationale uses this exact calculation if I'm not mistaken, so you will continue to get PWR from her every few turns, and amount increases as well, so you will get 12 (alarm level 6), then 14 (theoretical alarm level 7), 16 and so on.

Link to comment
Share on other sites

No, archive International does use TRG_ALARM_STATE_CHANGE, and TRG_ALARM_STATE_CHANGE does continue to trigger after alarm level 6. You should not use TRG_START_TURN to test for alarm change because that doesn't detect alarm change if alarm level increases by more than one during a turn, say because of a daemon or a heartmonitor.

I believe your mistake comes from this line:

	            local stage = self:getTrackerStage()
	            if stage > self._trackerStage then
	                self._trackerStage = stage

but getTrackerStage can increase beyond alarm level 6

function simengine:getTrackerStage( tracker )
    if not tracker then
        tracker = self:getTracker()
    end
    -- Note that self._tracker increases without cap; this is so alarm stages past TRACKER_MAXCOUNT continue to execute.
    -- The UI caps the tracker for display purposes only.  There is therefore no limit on the stage this function returns.
    return math.floor( tracker / simdefs.TRACKER_INCREMENT )
end

Those comments were made by the devs, not me by the way.

Link to comment
Share on other sites

1 hour ago, Cyberboy2000 said:

No, archive International does use TRG_ALARM_STATE_CHANGE, and TRG_ALARM_STATE_CHANGE does continue to trigger after alarm level 6.

My mistake then, but desired effect I remembered is there.

Link to comment
Share on other sites

Thanks for the insights guys. I think the required change here should be pretty simple: as soon as I hit Alarm Level 6, I switch on a boolean variable to stop Faust's daemon spawning. Even better: if there is an engine variable or something similar that indicates maximum alarm level, I could use that for the check so compatibility is maintained with other mods that change the alarm level count.

Link to comment
Share on other sites

I think you misunderstood us, Faust SHOULD spawn more than 6 daemons per mission, to still be dangerous after hitting max alarm level. Here is the quick code:

	faust = util.extend( DEFAULT_ABILITY )
	{
		name = STRINGS.PROGRAMS.FAUST.NAME,
		desc = STRINGS.PROGRAMS.FAUST.DESC,
		huddesc = STRINGS.PROGRAMS.FAUST.HUD_DESC,
		shortdesc = STRINGS.PROGRAMS.FAUST.SHORT_DESC,
		tipdesc = STRINGS.PROGRAMS.FAUST.TIP_DESC,
		lockedText = STRINGS.UI.TEAM_SELECT.UNLOCK_CENTRAL_MONSTER,

		icon = "gui/icons/programs_icons/icon-program-faust.png",
		icon_100 = "gui/icons/programs_icons/store_icons/StorePrograms_faust.png",
		value = 300,

		passive = true,
		
		executeAbility = function( self, sim )
			local player = sim:getCurrentPlayer()			

			sim:dispatchEvent( simdefs.EV_PLAY_SOUND, cdefs.SOUND_HUD_MAINFRAME_PROGRAM_AUTO_RUN )
			sim:dispatchEvent( simdefs.EV_SHOW_WARNING, {txt=STRINGS.PROGRAMS.FAUST.WARNING, color=cdefs.COLOR_PLAYER_WARNING,
            	sound = "SpySociety/Actions/mainframe_gainCPU",icon=self.icon } )
			player:addCPUs( 2 )
		end,

		canUseAbility = function( self, sim )
			return false 	
		end,

		onSpawnAbility = function( self, sim )
			DEFAULT_ABILITY.onSpawnAbility( self, sim )
			sim:addTrigger( simdefs.TRG_ALARM_STATE_CHANGE, self )	
		end, 

    	onDespawnAbility = function( self, sim, player )
    		DEFAULT_ABILITY.onDespawnAbility( self, sim )
			sim:removeTrigger( simdefs.TRG_ALARM_STATE_CHANGE, self )	
    	end,

		onTrigger = function( self, sim, evType, evData )
			DEFAULT_ABILITY.onTrigger( self, sim, evType, evData )
			if evType == simdefs.TRG_START_TURN then
				self:executeAbility(sim)	
			end
            if evType == simdefs.TRG_ALARM_STATE_CHANGE then
					local programList = nil
					local daemon = nil
					if sim:isVersion("0.17.5") then
						programList = sim:getIcePrograms()
						daemon = programList:getChoice( sim:nextRand( 1, programList:getTotalWeight() ))
					else
						programList = serverdefs.PROGRAM_LIST
						daemon = programList[sim:nextRand(1, #programList)]			
					end	

					sim:getNPC():addMainframeAbility( sim, daemon )
			end
		end,
	},

 

Link to comment
Share on other sites

Yes, that's essentially what I have now. But if I correctly understand the code Cyberboy referenced, after Alarm Level 6 "TRG_ALARM_STATE_CHANGE" goes off every turn to keep the max countermeasures continually triggering. I do not think spawning daemons every turn, despite it being Alarm Level 6, is even close to being balanced.

On top of that, the Faust description would either have to be slightly misleading or be convoluted/excessive to explain the special technical circumstances that occur after Alarm Level 6.

Link to comment
Share on other sites

It doesn't go off every turn. If you want proof, start a game with archive Internationale, and camp in mission past alarm level 6. You should notice +PWR text floating above her head exactly every 5 turns if there wasn't any alarm increasing event outside of autoincrement, even past alarm level 6.

Link to comment
Share on other sites

How do you guys feel about the two programs Golem and Mercenary? I've come to understand better how you can use them, but when I look at the two of them they seem far too similar in that they both rely on sparse and precise usage to be the most effective. The differences in how they change (total turns waited vs. alarm level) give them a little more flavor, but not enough that they feel like two super distinct programs in my eyes.

Which of those two do you use/prefer? Which one, if either, would you like to see changed?

Link to comment
Share on other sites

I prefer Golem over Mercenary, because I abhor raising the alarm level.

I like the concept of Golem, to break ice more efficiently with time between uses, but I have a problem with it scaling horribly.  I contemplated making a Golem 2.0 breaking ~3 firewalls with ~5 base PWR cost, so it could be helpful in later missions, but it ultimately has the same problem, just like every other program that leverages time to break firewalls.  I suppose they have their place.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.