Is a Hackeable Panel Doable?

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
User avatar
GAB
1st Lieutenant
1st Lieutenant
Posts: 431
Joined: Sun Jul 03, 2011 8:56 pm
Location: Somewhere around the world
Contact:

Is a Hackeable Panel Doable?

Post by GAB »

Here I am again, this time it is to ask if it is possible to turn a simple prop object into one that you can slice (hack) with a fusion cutter, in the same way you can do with vehicles. My intentions with this is to create the illusion of hacking a panel.

So, is this possible, and if so, how?
Loopy53
1st Lieutenant
1st Lieutenant
Posts: 456
Joined: Thu Nov 01, 2012 2:27 am
Projects :: Earth Apocalypse
Games I'm Playing :: swbf2 bf3 cod
xbox live or psn: Dont have one
Location: On earth, I guess.

Re: Is a Hackeable Panel Doable?

Post by Loopy53 »

its possible, since you can already repair panels. I just dont know how. sorry I cant be of more help. I would look in and around the common odf folders or in death star folder (the ds has a panel) and go from their.
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Is a Hackeable Panel Doable?

Post by Marth8880 »

Are you trying to make a scripted event occur when the panel is "hacked"? If so, it's totally possible: see AQT's Death Watch Bunker 2.0.
User avatar
Locutus
1st Lieutenant
1st Lieutenant
Posts: 420
Joined: Fri Jun 04, 2010 10:08 am
Projects :: Stargate Battlefront Pegasus
Location: Germany
Contact:

Re: Is a Hackeable Panel Doable?

Post by Locutus »

A destructible building should do it.
To prevent it from being destroyed, you can set its health ridiculously high.
CurrentHealth could be set to, say, 999.900 and TotalHealth to 999.999 so that you only need to repair 99 hitpoints, in this case. Setback would be that the repair would take very long if you shot this object just for fun before.

There are also those special weapons you can find in a couple of custom missions (might be a modified force push) which are used to activate consoles. But I don't know how they work.
User avatar
Fiodis
Master of the Force
Master of the Force
Posts: 4145
Joined: Wed Nov 12, 2008 9:27 pm
Projects :: Rannoch + Tientia + Tools Programming

Re: Is a Hackeable Panel Doable?

Post by Fiodis »

Or you could give it a destroyed geometry and only 100 or 10 hitpoints or whatever, so you can still hack it even if it's destroyed.

Or the process of hacking it might intentionally involve repairing it from 0 hitpoints to full.

Those special weapons to activate panels just shoot an invisible short-range bolt that deals very little damage. Then the lua code is set up to execute some functions whenever the proper panel is hit by that particular weapon.
User avatar
GAB
1st Lieutenant
1st Lieutenant
Posts: 431
Joined: Sun Jul 03, 2011 8:56 pm
Location: Somewhere around the world
Contact:

Re: Is a Hackeable Panel Doable?

Post by GAB »

Ok, so today I tried something. However, when I attempt to slice the panel nothing happens. I don't get the slice counter (slicing... %)

Here's the object's odf:

Code: Select all

[GameObjectClass]       

ClassLabel		= "destructablebuilding"
GeometryName    	= "AL3_prop_panel.msh"

[Properties]        

GeometryName    =   "AL3_prop_panel"

MaxHealth	= 500.0
HealthType	= "vehicle"
ExplosionDestruct	= "com_inf_rechargedroid_exp"

TimeRequiredToEject	= "7.5"
EjectResistance		= "0.02"
TimeTilReboard		= "1e+37"

//AttachOdf	= "AL3_light_redflare_strobe1"
//AttachToHardPoint	= "hp_light"
CressAlbane
Master Bounty Hunter
Master Bounty Hunter
Posts: 1519
Joined: Fri Dec 18, 2009 8:02 am
Projects :: CTF Arenas
Games I'm Playing :: Steam- cressalbane2
Location: ¿uoıʇɐɔoן ʎɯ sıɥʇ sı

Re: Is a Hackeable Panel Doable?

Post by CressAlbane »

I don't think the "Slicing" menu would show up even if you had it correct. The player would be able to measure progress by watching the health bar at the top.
Loopy53
1st Lieutenant
1st Lieutenant
Posts: 456
Joined: Thu Nov 01, 2012 2:27 am
Projects :: Earth Apocalypse
Games I'm Playing :: swbf2 bf3 cod
xbox live or psn: Dont have one
Location: On earth, I guess.

Re: Is a Hackeable Panel Doable?

Post by Loopy53 »

That slicing % thing is for vehicles only. Look in vehicle ODF's and see if you cant find something of relevance.
User avatar
GAB
1st Lieutenant
1st Lieutenant
Posts: 431
Joined: Sun Jul 03, 2011 8:56 pm
Location: Somewhere around the world
Contact:

Re: Is a Hackeable Panel Doable?

Post by GAB »

The only things of relevance I found were the properties TimeRequiredToEject, EjectResistance and TimeTilReboard. I'm pretty sure the Classlabel is relevant too. In fact, before making this thread I had already tried the same setting shown above, but with the Classlabel set to hover and the object set, in ZE, to team 2. But it didn't work, although the fusion cutter kept making sound and playing it's effect even if the object's health was full.
User avatar
Maveritchell
Jedi Admin
Jedi Admin
Posts: 7366
Joined: Mon Aug 21, 2006 11:03 pm

Re: Is a Hackeable Panel Doable?

Post by Maveritchell »

Is the "slicing" text a dealbreaker? Every time I've used this thing in campaign missions, I've used repair/destroy and not slicing - it's much simpler.
User avatar
GAB
1st Lieutenant
1st Lieutenant
Posts: 431
Joined: Sun Jul 03, 2011 8:56 pm
Location: Somewhere around the world
Contact:

Re: Is a Hackeable Panel Doable?

Post by GAB »

No, it's not a dealbreaker. Since when I had this idea, I also considered the destroy/repair concept in case of failure. I'm doing this just for the slice meter. I want it because, while the player "slices" the panel, the slice percentage meter would appear (and you could even localize "slicing.." to "hacking..."), therefore giving the illusion that the player is breaking some sort of security code. I wanted to try something different.

When I had this idea I considered that this might not possible, but I wanted to try and see what other people think before giving up and going to the common way of doing this.
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: Is a Hackeable Panel Doable?

Post by AQT »

Loopy53 wrote:That slicing % thing is for vehicles only. Look in vehicle ODF's and see if you cant find something of relevance.
And to elaborate on this, it has more to do with disabling an occupied enemy vehicle than repairing/destroying an object.
CressAlbane
Master Bounty Hunter
Master Bounty Hunter
Posts: 1519
Joined: Fri Dec 18, 2009 8:02 am
Projects :: CTF Arenas
Games I'm Playing :: Steam- cressalbane2
Location: ¿uoıʇɐɔoן ʎɯ sıɥʇ sı

Re: Is a Hackeable Panel Doable?

Post by CressAlbane »

Could you make the panel an enemy occupied vehicle? Make a new vehicle that can't move, has no weapons, and then force a unit from the other team into it?
User avatar
Fiodis
Master of the Force
Master of the Force
Posts: 4145
Joined: Wed Nov 12, 2008 9:27 pm
Projects :: Rannoch + Tientia + Tools Programming

Re: Is a Hackeable Panel Doable?

Post by Fiodis »

If you really wanted to, then yes.
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Is a Hackeable Panel Doable?

Post by Marth8880 »

CressAlbane wrote:Could you make the panel an enemy occupied vehicle? Make a new vehicle that can't move, has no weapons, and then force a unit from the other team into it?
The problem with that is the unit will be forced out of the vehicle once the panel vehicle is sliced. An alternative solution to making a panel that can be "hacked" is to just use AQT's method in DWB (basically an unbuilt destructable building) but implement message text "checkpoints" that notify the player of the hacking progress (as well as the health bar, of course, but that can actually be hidden if you so choose using the HideHealthBar ODF parameter), e.g., at 30% hacking progress, you'd tell the Lua to display a message text that reads "Hacking... 30%".

Here's an example block for the checkpoint bit that might work:

Code: Select all

	panel1_health = GetObjectHealth("panel1")
	-- panel has max health of 1000
	if panel1_health > 100 then
		ShowMessageText("level.ME5.hackprogress.10") -- Display "Hacking... 10%"
	end -- might need to use 'elseif' for each checkpoint
	
	if panel1_health > 200 then
		ShowMessageText("level.ME5.hackprogress.20") -- Display "Hacking... 20%"
	end
	
	if panel1_health > 300 then
		ShowMessageText("level.ME5.hackprogress.30") -- Display "Hacking... 30%"
	end
	
	if panel1_health > 400 then
		ShowMessageText("level.ME5.hackprogress.40") -- Display "Hacking... 40%"
	end
	
	if panel1_health > 500 then
		ShowMessageText("level.ME5.hackprogress.50") -- Display "Hacking... 50%"
	end
	
	if panel1_health > 600 then
		ShowMessageText("level.ME5.hackprogress.60") -- Display "Hacking... 60%"
	end
	
	if panel1_health > 700 then
		ShowMessageText("level.ME5.hackprogress.70") -- Display "Hacking... 70%"
	end
	
	if panel1_health > 800 then
		ShowMessageText("level.ME5.hackprogress.80") -- Display "Hacking... 80%"
	end
	
	if panel1_health > 900 then
		ShowMessageText("level.ME5.hackprogress.90") -- Display "Hacking... 90%"
	end
	
	if panel1_health >= 1000 then
		ShowMessageText("level.ME5.hackprogress.100") -- Display "Hacking... COMPLETE"
	end
User avatar
GAB
1st Lieutenant
1st Lieutenant
Posts: 431
Joined: Sun Jul 03, 2011 8:56 pm
Location: Somewhere around the world
Contact:

Re: Is a Hackeable Panel Doable?

Post by GAB »

Ok. I managed to make it work in a similar fashion to what was originally intended.
Loopy53
1st Lieutenant
1st Lieutenant
Posts: 456
Joined: Thu Nov 01, 2012 2:27 am
Projects :: Earth Apocalypse
Games I'm Playing :: swbf2 bf3 cod
xbox live or psn: Dont have one
Location: On earth, I guess.

Re: Is a Hackeable Panel Doable?

Post by Loopy53 »

can you tell us how? Thanks! I could make a campaign for my next release (not afghanistan village) with something like this :o
User avatar
GAB
1st Lieutenant
1st Lieutenant
Posts: 431
Joined: Sun Jul 03, 2011 8:56 pm
Location: Somewhere around the world
Contact:

Re: Is a Hackeable Panel Doable?

Post by GAB »

Well, since it is for the Alzoc 3 campaign, I'd like to not reveal details of it yet. After the release of the map, I can answer any question about how something was done.
Post Reply