PDA

View Full Version : [Script] Halo 2 Dual Wielding



kenney001
May 5th, 2007, 05:00 PM
Here is how you use it:
If you have a dual-weildable weapon out, and you are standing next to another dual-weildable weapon, you can either press zoom to dual it or action to swap.
once you have the set, you can't switch weapons or enter vehicles until you drop the second dual by pressing action again.
If you have a combo, you can stand on another dual-weapon and swap the second for the new second you are standing by.
Major Problems include (these are unavoidable)
Once you have a dual, and you switch back to single, your ammo counts and grenade counts are reset to default (as if you jsut picked it up)
when you drop the second gun, it dissapears.
You can only pick up the second where they spawn
when you die, you do not drop any weapons if you had a dual combo.
Plasma pistol is un-dualable
(this is due to bungies use of BOTH triggers in one weapon, so when you fire it fires primary, but when you overcharge it automatically switches to secondary fire, thus not allowing a secondary gun.)the issues are unavoidable, but you dont really notice them when playing. It works better than you'd think. :)

Here is the download. Instructions on use are included in the .zip.
Now if you use it and you like it,
(+rep me mb?) give me credit.

It at the moment DOES NOT SYNC ON MULTIPLAYER!! But feel free to try to make it, if you succeed i want to see how.

download here (http://dodownload.filefront.com/7437890//5162e857078ae6666d04e6af2272f814ebc58e8da652b2145d dd68f77fa80cf247ff82581228e103)

Syuusuke
May 5th, 2007, 09:07 PM
Hmm...sucks that it doesnt sync...

Why couldn't you make a test map =P

kenney001
May 5th, 2007, 10:45 PM
here, i compiled what i currently have of headlong with the finished script.

Note: The sounds for the dual-weilds are screwed, but they have nothing to do with the script.

H2_headlong_v2_beta (http://dodownload.filefront.com/7441275//5162e857078ae6666d04e6af2272f814ebc58e8da652b2145d dd68f77fa80cf247ff82581228e103)

megaxp
May 5th, 2007, 10:56 PM
HELL YA!!!!!!! NICEE!
FUCK!!
NICE SCRIPTS!!

OmegaDragon
May 5th, 2007, 11:58 PM
I have yet to test it, but I recommend to zip the map file >.>

Abdurahman
May 6th, 2007, 12:34 AM
MY GOD, This Is one closer step to true dual wielding On HALO CE!!! MARVELOUS! YOU ARE AWESOME!

AAA
May 6th, 2007, 02:49 AM
OMG, Can someone zip or rar this baby and send link please?? I refuse to download this map for almost 2 hours, AGAIN.



.rar/.zip link of map soon plz...

zakaria
May 6th, 2007, 09:40 AM
i don't know how use the script help me please

Syuusuke
May 6th, 2007, 09:41 AM
All your download times are halved =P (http://files.filefront.com/h2_headlong_v2zip/;7444862;/fileinfo.html)
41.1 MB

Are the only "dual-wieldable" weapons SMG-SMG and SMG-Pistol? I can't seem to wield with others, (Plasma Rifle, Needler, and even the pistol occasionally)

Hurrvish
May 6th, 2007, 10:03 AM
only dual wieldable weapons:
smg + pistol
smg + smg
smg + pr

nothing else :(

DarkLord
May 6th, 2007, 01:28 PM
One Thing, how do you use it. I don't know hwo to make it work I know its in the headlong but for someones map or your map.

kenney001
May 6th, 2007, 01:29 PM
no. I didnt finish the weapons for the combo's, so the ones in that are the ones i managed to rip from H2_coag and h2_headlong. (oops did i jsut upload the .map? I meant to zip it sorry.)

they are:

SMG-magnum
smg-plasma rifle
smg-smg
magnum-magnum

i was going to finish the other sets but since it doesnt sync theres no point. Here is all the resources needed to finish them all organized and in folders, along with the models, fp hands, and examples, and the origional .jms and .jma.

REsource files for dual weilds (http://dodownload.filefront.com/7446478//5162e857078ae6666d04e6af2272f814ebc58e8da652b2145d dd68f77fa80cf247ff82581228e103)

Random
May 6th, 2007, 01:48 PM
i was going to finish the other sets but since it doesnt sync theres no point.


It doesn't sync and never will because of the add_equipment command. Which is everything in this script.

-£§- §age
May 6th, 2007, 05:09 PM
Awww, there's no way to make it sync?
What kind of effect does that have on multiplayer?

Random
May 6th, 2007, 07:12 PM
Awww, there's no way to make it sync?
What kind of effect does that have on multiplayer?

Clients spawn floating fp arms when they get the dual wield weapon.

kenney001
May 6th, 2007, 07:41 PM
when i tried, they opponents weapon didnt change, so they appear to be holding say a BR, and over the network they still send BR shots, even though in fp it appears to be firing dual smgs.

keilg2
May 6th, 2007, 07:57 PM
i don't understand the just of this is it like a tag that you put in your map and you can duel wield all the awesome gunz in halo or is it for h2vista

-£§- §age
May 6th, 2007, 07:57 PM
Ahhh. Not good.
Oh well, maybe we can study how H2V does it.

keilg2
May 6th, 2007, 07:59 PM
Ahhh. Not good.
Oh well, maybe we can study how H2V does it.

i still don't understand what this is? :confused::confused:
:XD:

well i immagine that we could "re-write" the games basic scripts to program duel wielding into it

Zeph
May 6th, 2007, 07:59 PM
How about you explain what the download is a bit mor?

keilg2
May 6th, 2007, 08:02 PM
well the download just says this is duel wielding ok here is what it is and these are the bugs

but hey if you have a rocket launcher who needs duel wielding anyway...


god i need to put that in my sig

kenney001
May 7th, 2007, 04:45 PM
a script to allow halo 2 style dual-weilding in single player or ai maps (because it doesnt sync in multiplayer. -i thought the title and the How to use was enough to explain this.

"i immagine that we could "re-write" the games basic scripts to program duel wielding into it"

What do you think i did? I used the few usefull halo 1 scritping commands and wrote this.


(global real sheilds0 (Unit_get_shield (unit (list_get (players) 0))))
(global real health0 (Unit_get_health (unit (list_get (players) 0))))
(global real playerhad0 0)
(global real readiedduals0 0)
(global real 2nd0 0)
(global real hasduals0 0)
(global real dualscheck0 0)

;;*****************************************sets the "has duals" variable from true to false******************************************

(Script continuous duals0
(if (or (unit_has_weapon (unit (list_get (players) 0)) weapons\m-smg\m-smg)
(unit_has_weapon (unit (list_get (players) 0)) weapons\dual_magnums\dual_magnums)
(unit_has_weapon (unit (list_get (players) 0)) weapons\dual_smgs\dual_smgs)
(unit_has_weapon (unit (list_get (players) 0)) weapons\plasma_smg\plasma_smg)
)
(set hasduals0 1)
(set hasduals0 0)

)

;;*****************************************sets weapons had before combo******************************************
(if (= hasduals0 0)
(begin
(cond
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\magnum\magnum)
(set playerhad0 1))
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\smg\smg)
(set playerhad0 2))
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_rifle\plasma_rifle)
(set playerhad0 3))
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\needler\needler)
(set playerhad0 5))
)
(cond
((unit_has_weapon (unit (list_get (players) 0)) weapons\brute_shot\brute_shot)
(set 2nd0 100))
((unit_has_weapon (unit (list_get (players) 0)) weapons\rocket_launcher\rocket_launcher)
(set 2nd0 200))
((unit_has_weapon (unit (list_get (players) 0)) weapons\Beam_rifle\Beam_rifle)
(set 2nd0 300))
((unit_has_weapon (unit (list_get (players) 0)) weapons\Energy_sword_ver4\Energy_sword_ver4)
(set 2nd0 400))
((unit_has_weapon (unit (list_get (players) 0)) weapons\cov_carbine\cov_carbine)
(set 2nd0 500))
((unit_has_weapon (unit (list_get (players) 0)) weapons\Battle_rifle\Battle_rifle)
(set 2nd0 600))
((unit_has_weapon (unit (list_get (players) 0)) weapons\shotgun\shotgun)
(set 2nd0 700))
((unit_has_weapon (unit (list_get (players) 0)) weapons\sniper_rifle\sniper_rifle)
(set 2nd0 800))
((and (unit_has_weapon (unit (list_get (players) 0)) weapons\magnum\magnum)
(not (unit_has_weapon_readied (unit (list_get (players) 0)) weapons\magnum\magnum))
)
(set 2nd0 900)
)
((and (unit_has_weapon (unit (list_get (players) 0)) weapons\smg\smg)
(not (unit_has_weapon_readied (unit (list_get (players) 0)) weapons\smg\smg))
)
(set 2nd0 1000)
)
((and (unit_has_weapon (unit (list_get (players) 0)) weapons\plasma_rifle\plasma_rifle)
(not (unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_rifle\plasma_rifle))
)
(set 2nd0 1100)
)
((and (unit_has_weapon (unit (list_get (players) 0)) weapons\needler\needler)
(not (unit_has_weapon_readied (unit (list_get (players) 0)) weapons\needler\needler))
)
(set 2nd0 1200)
)
((and (unit_has_weapon (unit (list_get (players) 0)) weapons\plasma_pistol\plasma_pistol)
(not (unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_pistol\plasma_pistol))
)
(set 2nd0 1300)
)
)
)
)

;;*****************************************Chooses weapons when switching from a combo******************************************

(cond ((and (= hasduals0 1) (player_action_test_action))

(set health0 (* (Unit_get_health (unit (list_get (players) 0))) 75))
(set sheilds0 (* (unit_get_shield (unit (list_get (players) 0))) 75))
(Player_add_equipment (unit (list_get (players) 0)) blank true)
(cond
((= 2nd0 100)
(player_add_equipment (unit (list_get (players) 0)) brute true)
)
((= 2nd0 200)
(player_add_equipment (unit (list_get (players) 0)) rock true)
)
((= 2nd0 300)
(player_add_equipment (unit (list_get (players) 0)) beam true)
)
((= 2nd0 400)
(player_add_equipment (unit (list_get (players) 0)) energy true)
)
((= 2nd0 500)
(player_add_equipment (unit (list_get (players) 0)) car true)
)
((= 2nd0 600)
(player_add_equipment (unit (list_get (players) 0)) br true)
)
((= 2nd0 700)
(player_add_equipment (unit (list_get (players) 0)) shot true)
)
((= 2nd0 800)
(player_add_equipment (unit (list_get (players) 0)) sniper true)
)
((= 2nd0 900)
(player_add_equipment (unit (list_get (players) 0)) magnum true)
)
((= 2nd0 1000)
(player_add_equipment (unit (list_get (players) 0)) smg true)
)
((= 2nd0 1100)
(player_add_equipment (unit (list_get (players) 0)) plasma_rifle true)
)
((= 2nd0 1200)
(player_add_equipment (unit (list_get (players) 0)) needler true)
)
((= 2nd0 1300)
(player_add_equipment (unit (list_get (players) 0)) plasma_pistol true)
)
)

(sleep 5)
(cond ((= playerhad0 1)
(player_add_equipment (unit (list_get (players) 0)) magnum true)
)
((= playerhad0 2)
(player_add_equipment (unit (list_get (players) 0)) smg true)
)
((= playerhad0 3)
(player_add_equipment (unit (list_get (players) 0)) plasma_rifle true)
)
)


(unit_set_current_vitality (unit (list_get (players) 0)) health0 sheilds0)
(player_action_test_reset)
)

);;closes closes if


;;****************************************chooses dual weild when action is pushed**********************************


(cond ((player_action_test_zoom)
(set health0 (* (Unit_get_health (unit (list_get (players) 0))) 75))
(set sheilds0 (* (Unit_get_shield (unit (list_get (players) 0))) 75))
(cond

((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\smg\smg)
(cond ((or (volume_test_object magnum (unit (list_get (players) 0)))
(volume_test_object magnum2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) m-smg true))

)

(cond ((or (volume_test_object smg (unit (list_get (players) 0)))
(volume_test_object smg2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) dual_smg true))

)

(cond ((or (volume_test_object plasma_rifle (unit (list_get (players) 0)))
(volume_test_object plasma_rifle2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) pr_smg true))

)





)
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\magnum\magnum)
(cond ((or (volume_test_object magnum (unit (list_get (players) 0)))
(volume_test_object magnum2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) dual_magnums true))

)

(cond ((or (volume_test_object smg (unit (list_get (players) 0)))
(volume_test_object smg2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) m-smg true))

)








)
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_rifle\plasma_rifle)
(If (or (volume_test_object smg (unit (list_get (players) 0)))
(volume_test_object smg2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) pr_smg true)

)













)
;;((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_pistol\plasma_pistol)












;;)
;;((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\needler\needler)














;;)
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_smg\plasma_smg)
(cond ((or (volume_test_object smg (unit (list_get (players) 0)))
(volume_test_object smg2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) dual_smg true))

)

(cond ((or (volume_test_object magnum (unit (list_get (players) 0)))
(volume_test_object magnum2 (unit (list_get (players) 0))))
(Player_add_equipment (unit (list_get (players) 0)) m-smg true))

))

((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\dual_smgs\dual_smgs)
(cond ((or (volume_test_object magnum (unit (list_get (players) 0)))
(volume_test_object magnum2 (unit (list_get (players) 0))))
(Player_add_equipment (unit (list_get (players) 0)) m-smg true))




))

((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\dual_magnums\dual_magnums)
(cond ((or (volume_test_object smg (unit (list_get (players) 0)))
(volume_test_object smg2 (unit (list_get (players) 0))))
(Player_add_equipment (unit (list_get (players) 0)) m-smg true))



))
((unit_has_weapon_readied (unit (list_get (players) 0)) weapons\m-smg\m-smg)
(cond ((or (volume_test_object smg (unit (list_get (players) 0)))
(volume_test_object smg2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) dual_smg true))

)
(cond ((or (volume_test_object magnum (unit (list_get (players) 0)))
(volume_test_object magnum2 (unit (list_get (players) 0))))
(Player_add_equipment (unit (list_get (players) 0)) dual_magnums true))

)
(cond ((or (volume_test_object plasma_rifle (unit (list_get (players) 0)))
(volume_test_object plasma_rifle2 (unit (list_get (players) 0))))

(Player_add_equipment (unit (list_get (players) 0)) pr_smg true))


))

);;Weaponsreadied list conditional

(unit_set_current_vitality (unit (list_get (players) 0)) health0 sheilds0)
(player_action_test_reset)
(set dualscheck0 1)

);;ends player_action_test_zoom conditional
);;ends zoom conditional

;;*****************************************prevent s weapons switching when in combo mode******************************************

(cond ((and (or (unit_has_weapon_readied (unit (list_get (players) 0)) weapons\m-smg\m-smg)
(unit_has_weapon_readied (unit (list_get (players) 0)) weapons\dual_magnums\dual_magnums)
(unit_has_weapon_readied (unit (list_get (players) 0)) weapons\dual_smgs\dual_smgs)
(unit_has_weapon_readied (unit (list_get (players) 0)) weapons\plasma_smg\plasma_smg)
) (= dualscheck0 1))
(Player_add_equipment (unit (list_get (players) 0)) blank true)
(unit_set_current_vitality (unit (list_get (players) 0)) health0 sheilds0)
(set dualscheck0 0))


)



);;closes script




THat pretty much simulates the h2 environment as well as Halo 1 can without re-writing the engine itself. If you still dont know what im talking about, then your probably not advanced enough to use it, not to offend anyone.

Abdurahman
May 7th, 2007, 11:47 PM
too technical for my small brain : P

kenney001
May 8th, 2007, 07:15 AM
thats why i tell you what to put in your map to make this work without modification. Modification is easy enough though.

demonmaster3k
May 8th, 2007, 04:13 PM
think this can work in conjunction with the backpack script?

ReFlex
May 8th, 2007, 04:26 PM
no clue what to do with scripts once downloaded:confused:

-£§- §age
May 8th, 2007, 05:48 PM
Put in data/levels/<mapname>/scripts and compile in Sapien.

Abstract.Error
May 11th, 2007, 01:52 PM
Argh, i can't find data....

demonmaster3k
May 11th, 2007, 02:27 PM
ooohhh clever!

i see what you did!
when the player has a smg or a pistol, and the player presses "z", the weapon is switched for the duals pretty much a change in the tags.

since you said that it won't sync online, does that include lan/t1 connections as well?

and could i somehow add extra combos to the list by creating more dual weapon tags?
i'm not too good with making scripts, but i can modify them

keilg2
May 12th, 2007, 12:48 PM
well ive known for a long time that you can literally re-write the game engine itself from the beginning but ive never known how to do it

Patrickssj6
May 13th, 2007, 10:35 AM
well ive known for a long time that you can literally re-write the game engine itself from the beginning but ive never known how to do it
Yes...literally...

That's called reverse engineering.But for a game like Halo it's easier to get the source code from Bungie.

So make stuff sync online you don't even have to rewrite the whole engine.

Well I guess this is my minor theory and since Korn doesn't watch this part of the forum I don't have to expect a comeback (dare anyone to redirect him to here :p)

I'm talking about hosting right now not on a dedi but normal hosting.On the host the AI exists and on the client the AI existst.The memory blocks have the same length and are at the same position.I guess if you sent via an external app the memory chunks to the client and let him overwrite his this might work.The prob is this is only a theory and second I don't know where all the important chunks are located and how big they are.

Now that I look at my theory it seems kinda...stupid.It's easier to enable the host and client to sent/receive the data.

kenney001
May 13th, 2007, 11:19 AM
yes you can add extra weapons. Just look at the pattern in it, and add another line, another set global value (or the result of the if statements) and go on down and add it where the patterns are. Its fairly obvious to see.,

No it does not work over LAN either, i wish it did. Maybe if someone wants to speek to korn about an external app or a patch that just adds this to the data stream over the network, but i dont know anything about the actual coding of the game,so i dont know how easy/hard it is. I also think we could make halo 1 ce become almost a clone of h2 once vista comes out because of rippers, and scripts like this.

Ki11a_FTW
May 14th, 2007, 05:04 PM
hey kenny i have Daul SMG+needler and SMG+ Brute plasma i made a while ago, want them?

kenney001
May 18th, 2007, 10:05 PM
nah. im not messing with CE anymore......but it might be nice to upload somewhere for others who want to use this.

Ralex123
May 22nd, 2007, 06:25 PM
Looks good so far. I hope they can get as much as they can from H2V. Haven't tried it yet, maybe later.

tj117
May 25th, 2007, 03:29 PM
Its too bad that there are so many serious errors...:fail:
I will be sure to play it later.

fjna
May 27th, 2007, 08:01 PM
Kenny or anyone else could give me a brief explanation about how to use the script, im bared on the info cant understand it so... what u mean with starting profiles? i know its kinda a stupid question but bah, and for needed weap. are all of them compulsory?

kenney001
May 28th, 2007, 12:35 AM
ok first off, take the tags for the dual weild sets included in this (http://dodownload.filefront.com/7446478//5162e857078ae6666d04e6af2272f814ebc58e8da652b2145d dd68f77fa80cf247ff82581228e103)
and put them in your weapons folder.
(that I believe has the required resources to make the rest of the dual combo's, and the tags needed for the current script to run)

then open your scenario in gurilla, and find that section called "starting profiles" and follow the instructions in the script.
-starting profiles with these names (no parentheses words)
Car (carbine)
rock (rocket)
brute (brute shot)
energy (sword)
beam (beam rifle)
shot (shotgun)
br (battlerifle)
plasma_pistol (duh)
needler (duh)
magnum (duh again)
sniper (sniper rifle)
plasma_rifle (duh x3)
smg (again....wtf)

m-smg (magnum/smg combo)
Pr-smg (plasma rifle/smg)
dual_smg (....)
dual_magnums (.....?)
Add the appropriate starting ammo, leave the rest blank (except put in 2 nades)

Then you open your scenario in sapien, and add the trigger volumes with these names, over their according weapons

SMG
SMG2
Magnum
Magnum2
Plasma_rifle
Plasma_rifle2

Then take the script, put it in your map's folder, in a new folder called "scripts" and hit compile in sapien. Whala, your done. Im sorry i did not include mroe weapons, but i left those sections in the script to be added when needed, just use some simple scritpintg knowledge and copy/paste to add the other sections.

xtremestunt
June 2nd, 2007, 11:59 AM
can someone pls pls pls put this on hce.halomaps.org (http://hce.halomaps.org) cuz filefront doesn't work 4 meeeeee :mad: :( or send it to my e-mail BruceLau911@hotmail.com -THX!

Ralex123
June 2nd, 2007, 07:18 PM
can someone pls pls pls put this on hce.halomaps.org (http://hce.halomaps.org) cuz filefront doesn't work 4 meeeeee :mad: :(
I fully agree. Same thing happens to me.

kenney001
June 2nd, 2007, 09:21 PM
I uploaded it with a better set of instructions, so it should be there

xtremestunt
June 5th, 2007, 08:03 PM
try to upload it again cuz its still not there :\ and um i added u on xfire

Ralex123
June 6th, 2007, 04:55 PM
Hope it comes soon. Thanks for uploading! Hope it is awesome. I really believe that that map will have way more than 1000 downloads once it's up. :D

kenney001
June 6th, 2007, 05:08 PM
i didnt upload a map......just the tags.

kenney001
June 6th, 2007, 05:09 PM
I didnt upload a map...jsut the tags. And ALL of my maps have had over 2000, and I believe one had like 6000.

Ralex123
June 7th, 2007, 09:55 AM
I was asking for the map man. Now there is no way i can play it :( Can you upload the map? That was all I really needed. I can't seem to get it from Filefront. (I'm asking for headlong_h2_v2). Thanks.

kenney001
June 7th, 2007, 09:56 PM
no not really, i dont want to have it that readily avaliable to everyone. I will, however, fire you the file. Send a freind request to kenney001, and ill send the file.

Ralex123
June 8th, 2007, 05:06 AM
On Xfire? I don't have a username on filefront, but I think I'll get one.

Jay2645
June 30th, 2007, 02:39 AM
Yeah, he means on Xfire. Where'd you get Filefront from?

RandomVietBoy
June 30th, 2007, 10:46 AM
hey is that map out for the public yet?

kenney001
June 30th, 2007, 11:03 AM
Filefront deleted the map without me knowing (it will automatically delete idle files unless you tell it not to.) And I have no more maps using the Dual-weilding script. The real map, HEadlong, will not be using it. However, I will be releasing a second final build of the map with Dual-weilding, destructable vehicles, and AI just for those who want to have that H2 expirience.

Ralex123
July 1st, 2007, 07:59 AM
I love what you have done with the map. I think you are one of the best really. I can't wait to try it.