Jump to content


Photo

BG1: Your Item Only


  • Please log in to reply
6 replies to this topic

#1 Drifter

Drifter
  • Member
  • 4 posts

Posted 13 September 2008 - 12:06 AM

I created a blade a long time ago that only my main character could use, ala Xan's moonblade. I wanted to create something like that again...

Unfortunately I cannot, for the life of me, remember how I did it! I've tried looking through my documents but they don't contain anything of the sort.

If this sounds familiar and someone knows how where I got this information from, I'd appreciate it if you could point me in the right direction.

#2 Icendoan

Icendoan

    "An Infinite Deal of Nothing"

  • Member
  • 1723 posts

Posted 13 September 2008 - 12:36 AM

You make it useable only by your PC's class and kit, with their exact stat requirements.

Icen
Proud member of the 'I HATE Elminster!' Club!

Mods in development: Keeping Yoshimo

#3 Jarno Mikkola

Jarno Mikkola

    The Imp in his pink raincoat.

  • Member
  • 10911 posts

Posted 13 September 2008 - 12:38 AM

...

What editor are you using? As for making item that can't be used by anyone else than a specific char, it's kinda depends on the char... class, alignment and stat requirements are easy to do, after you know the characters class, alignment and stats. :doh:

Deactivated account. The user today is known as The Imp.


#4 Drifter

Drifter
  • Member
  • 4 posts

Posted 13 September 2008 - 01:16 AM

I used IEEP to create back in the day but it took a lil' bump to the noggin so I've been using DLTCEP lately.

Heh, don't I feel silly. I could've sworn that I had read an article/tutorial on making an item for your character only through use of something other than stats and class. Mayhap I was mistaken?

EDIT: Now that I think about it, for Xan, that was probably something hard-coded into the game itself, no?
StrRef 10220: ((This blade resists any attempt at using it. Likely it is attuned to its owner and none other can wield it. The hilt bears the name "XAN." ))

Edited by Drifter, 13 September 2008 - 01:28 AM.


#5 vilkacis

vilkacis

    Rashemen REPRESENT! Word to yo hamsta!

  • Modder
  • 1571 posts

Posted 13 September 2008 - 11:26 AM

I remember reading a tutorial *way* back that had various scripts that would hit any non-approved user with a lightning bolt and make them drop the item.

...found it: Complicated item making from the ground up by Lone Wolf over at the Pocket Plane boards.

Of course, it probably uses a lot of tools from 2004 or so, so it may not be very helpful, but it may be worth a look for inspiration.

#6 GeN1e

GeN1e

    A very GAR character

  • Modder
  • 1604 posts

Posted 13 September 2008 - 11:58 AM

180th "can't use item" opcode is a good way. You'll have to find a suitable way to apply it to all non-protagonist NPCs, though.
You also can include checks into baldur.bcs
IF
OR(5)
HasItem("PConly",Player2)
HasItem("PConly",Player3)
HasItem("PConly",Player4)
HasItem("PConly",Player5)
HasItem("PConly",Player6)
THEN
RESPONE #100
ActionOverride(Player2,DropItem("PConly",[0.0]))
ActionOverride(Player3,DropItem("PConly",[0.0]))
ActionOverride(Player4,DropItem("PConly",[0.0]))
ActionOverride(Player5,DropItem("PConly",[0.0]))
ActionOverride(Player6,DropItem("PConly",[0.0]))
END

PS It would better to use HasItemEquipped instead of HasItem, but the former seem to present in BG2 only.

Edited by GeN1e, 13 September 2008 - 12:02 PM.

Retired from modding.


#7 Drifter

Drifter
  • Member
  • 4 posts

Posted 13 September 2008 - 12:06 PM

Thanks vilkacis, that's actually one of the tuts that I have. It didn't really do it for me though.
By the by, awesome avatar. :)

GeN1e, seems sound. I'll see if I can't get that to work. My IE coding skills are a bit weak, that won't stop me from trying though.
Thanks.