Jump to content


Photo

Making a creature Untargettable


  • Please log in to reply
No replies to this topic

#1 Cuv

Cuv

    Area Maker (retired)

  • Modder
  • 925 posts

Posted 20 August 2002 - 07:35 PM

I posted this at TeamBG also. Didnt want anyone to feel left out. This is for general information purposes, and I dont intend to respond to questions with any regularity or perhaps ever. I will give out more information when I have the time.

Since I have been bombarded with emails and PMs with regards to this matter... here is some info for you all. No point in holding onto it as a secret with NWN out. This wont be everything you need, but should get you started. I will assume this request is for dualing.

Start adding opcode protections and benefits to a creature. They should include the following and more:

Immunity to Effect: Death
Immunity to Effect: Set AI Script
Immunity to Effect: Slow
Immunity to Effect: Slay
Immunity to Effect: Wing Buffet
Immunity to Effect: Teleport Field
Immunity to Effect: Remove Fear
Immunity to Effect: Remove Fear2
Immunity to Effect: Disintigrate
Immunity to Effect: Stone to Flesh
Immunity to Effect: Stun
Immunity to Effect: Polymorph
Immunity to Effect: Grease Effect Overlay
Immunity to Effect: Web Effect Overlay
Immunity to Effect: Entangle Overlay
Immunity to Effect: Level Drain
Immunity to Effect: Backstab
Immunity to Effect: The rest... there are hundreds more
Invisibilty Detection by Script
Protection from Spell: Haste
Protection from Spell: Improved Haste
Protection from Spell: Nature's Beauty
Magic Damage Resistance Bonus: Maximum
Bonus to AC: -20
Physical resistances: Maximum
Elemental resistances: Maximum
Magic Resistance: Maximum
Immunity to spell levels: 1-10; all schools and all types (Mage, Priest and Innate)
Remove Feet Circle(287)

All effects should target self. Then you need to flag the creature as something other than a creature.... I have mine flagged as a pair of boots so that no scripting can find it. It should have no alignment or anything else that can identify it in any way. You will also need to play around with the states (which is the key to true untargettability).

Just transfer the opcode protections to your character with NI if you want a god that cannot be killed. Again, I havent listed everything. My character file was too large to load in NI so I wasnt able to be more specific. Too low on resources at the moment:p

If you want to take things further, give all the above to an item that does maximum damage (in excess of 1400 damage per hit) of every kind with an insane THACO. You can use any item in the game... I have altered the Beladonna Flowers to be a weapon. Dont change the file name and you can use your item in MP. You can even make custom spells that are useable in MP. This will work against all the wannabe dual'ers out there. But none of this will help you against the clans... you will need to go further. Making a script that removes your character from the party and attack with hotkeys. The script should use all the 'Sure_Kill' type spells. Look at the Irenicus script in the Promenade for suggestions... where he battles the cowled wizards. Also look closely at the Spell.ids for other spells to use that ignore resistances.

Here is a sample dualing script that uses a hotkey

IF
HotKey(A)
THEN
RESPONSE #100
CutSceneId("Player1Fill")
CutSceneId("Player2Fill")
CutSceneId("Player3Fill")
CutSceneId("Player4Fill")
CutSceneId("Player5Fill")
CutSceneId("Player6Fill")
StartCutSceneMode()
DisplayStringHead(SecondNearest,4864)
SmallWait(20)
DisplayStringHead(ThirdNearest,4861)
SmallWait(20)
DisplayStringHead(FourthNearest,4864)
SmallWait(20)
DisplayStringHead(FifthNearest,4864)
SmallWait(20)
DisplayStringHead(Myself,59571)
ForceSpell(SecondNearest,FLASHY_3)
PlayDead(5)
CreateVisualEffectObject("SPROTECT",Myself)
CreateVisualEffectObject("SPRWRA2I",Myself)
CreateVisualEffectObject("SPRAISED",Myself)
CreateVisualEffectObject("SPRWRATI",Myself)
CreateVisualEffectObject("SPUNHOLY",Myself)
CreateVisualEffectObject("SPWIRBLA",Myself)
CreateVisualEffectObject("SPROTECT",Myself)
SmallWait(30)
DisplayStringHead(Myself,2844)
CreateVisualEffectObject("SPMAGMIS",SecondNearest)
CreateVisualEffectObject("SPCALLLI",SecondNearest)
CreateVisualEffectObject("SPFIREPI",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("SPFLADOW",SecondNearest)
CreateVisualEffectObject("CGALTERA",SecondNearest)
CreateVisualEffectObject("CGILLUSI",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("MMAGICH",SecondNearest)
CreateVisualEffectObject("SPBASEWT",SecondNearest)
CreateVisualEffectObject("SPBEHBLA",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("SPCMWOUI",SecondNearest)
CreateVisualEffectObject("SPCCWOUI",SecondNearest)
CreateVisualEffectObject("SPCHLGT1",SecondNearest)
ActionOverride(SecondNearest,DestroyAllEquipment())
CallLightning(SecondNearest)
Kill(SecondNearest)
ActionOverride(SecondNearest,DropInventory())
ActionOverride(SecondNearest,DestroySelf())
ActionOverride(SecondNearest,Enemy())
ActionOverride(SecondNearest,Deactivate())
ActionOverride(SecondNearest,LeaveParty())
SmallWait(30)
DisplayStringHead(Myself,60501)
ForceSpell(SecondNearest,FLASHY_3)
PlayDead(5)
CreateVisualEffectObject("SPROTECT",Myself)
CreateVisualEffectObject("SPRWRA2I",Myself)
CreateVisualEffectObject("SPRAISED",Myself)
CreateVisualEffectObject("SPRWRATI",Myself)
CreateVisualEffectObject("SPUNHOLY",Myself)
CreateVisualEffectObject("SPWIRBLA",Myself)
CreateVisualEffectObject("SPROTECT",Myself)
SmallWait(5)
CreateVisualEffectObject("SPMAGMIS",SecondNearest)
CreateVisualEffectObject("SPCALLLI",SecondNearest)
CreateVisualEffectObject("SPFIREPI",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("SPFLADOW",SecondNearest)
CreateVisualEffectObject("CGALTERA",SecondNearest)
CreateVisualEffectObject("CGILLUSI",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("MMAGICH",SecondNearest)
CreateVisualEffectObject("SPBASEWT",SecondNearest)
CreateVisualEffectObject("SPBEHBLA",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("SPCMWOUI",SecondNearest)
CreateVisualEffectObject("SPCCWOUI",SecondNearest)
CreateVisualEffectObject("SPCHLGT1",SecondNearest)
ActionOverride(ThirdNearest,DestroyAllEquipment())
CallLightning(ThirdNearest)
Kill(ThirdNearest)
ActionOverride(ThirdNearest,DropInventory())
ActionOverride(ThirdNearest,DestroySelf())
ActionOverride(ThirdNearest,Enemy())
ActionOverride(ThirdNearest,Deactivate())
ActionOverride(ThirdNearest,LeaveParty())
DisplayStringHead(Myself,60500)
ForceSpell(SecondNearest,FLASHY_3)
ActionOverride(SecondNearest,PlayDead(5))
CreateVisualEffectObject("SPROTECT",Myself)
CreateVisualEffectObject("SPRWRA2I",Myself)
CreateVisualEffectObject("SPRAISED",Myself)
CreateVisualEffectObject("SPRWRATI",Myself)
CreateVisualEffectObject("SPUNHOLY",Myself)
CreateVisualEffectObject("SPWIRBLA",Myself)
CreateVisualEffectObject("SPROTECT",Myself)
SmallWait(30)
CreateVisualEffectObject("SPMAGMIS",SecondNearest)
CreateVisualEffectObject("SPCALLLI",SecondNearest)
CreateVisualEffectObject("SPFIREPI",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("SPFLADOW",SecondNearest)
CreateVisualEffectObject("CGALTERA",SecondNearest)
CreateVisualEffectObject("CGILLUSI",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("MMAGICH",SecondNearest)
CreateVisualEffectObject("SPBASEWT",SecondNearest)
CreateVisualEffectObject("SPBEHBLA",SecondNearest)
SmallWait(5)
CreateVisualEffectObject("SPCMWOUI",SecondNearest)
CreateVisualEffectObject("SPCCWOUI",SecondNearest)
CreateVisualEffectObject("SPCHLGT1",SecondNearest)
ActionOverride(SecondNearest,DestroyAllEquipment())
CallLightning(SecondNearest)
Kill(SecondNearest)
ActionOverride(SecondNearest,DropInventory())
ActionOverride(SecondNearest,DestroySelf())
ActionOverride(SecondNearest,Enemy())
ActionOverride(SecondNearest,Deactivate())
ActionOverride(SecondNearest,LeaveParty())
SmallWait(30)
EndCutSceneMode()
END

Hope this helps you. This is all I am prepared to share at the moment, but there is more. Like I said before, this has really no use in modding except for maybe the general knowledge. Having this type of creature in your game to monitor conditions cannot be destroyed easily and will ruin your normal game. Also, having your character with these immunities will not only take all the fun out of BG2, you the NPC's will fail to see you at all in most cases and there will be no plot whatsoever. Just a warning. Enjoy

Cuv