Author Topic: Question About Getting a Value From Item Property  (Read 3467 times)

0 Members and 1 Guest are viewing this topic.

Offline PauloniusTopic starter

  • Elite
  • *
  • *
  • Posts: 2040
  • Activity:
    0%
  • Reputation Power: 29
  • Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.
  • Respect: +304
  • Referrals: 1
    • View Profile
Question About Getting a Value From Item Property
« on: November 13, 2009, 11:42:31 AM »
0
I am working on an imbue script and I need to be able to determine the value for physical resist on an item to build a check to see if the script has successfully imbued the target.  I guess what I need is a line or two of code after an event property that will pull the number off and assign it to a variable:


Event Property %ImbueItem

Set %ImbueItemPhysicalResist [Code I can't figure out that pulls off the number after Physical Resist]

Anyone got any ideas?
This coin declares Caesar is "Dictator for Life." He did serve as Dictator for the remainder of his life, but his life would end only a few weeks after this issue. For Caesar to put his image on coins and essentially declare himself king was too much for Brutus and his republican allies.

"If everything seems under control, you're not going fast enough'
-Mario Andretti

"If everyone is thinking alike, someone isn't thinking."
- General George Patton Jr

Offline Superslayer

  • Elite
  • *
  • *
  • Posts: 1006
  • Activity:
    0%
  • Reputation Power: 14
  • Superslayer barely matters.Superslayer barely matters.
  • Gender: Male
  • Well what do you drink? Not tea.
  • Respect: +100
  • Referrals: 0
    • View Profile
Re: Question About Getting a Value From Item Property
« Reply #1 on: November 13, 2009, 01:18:55 PM »
0
I'm gonna guess that using strings may be of use. After you event property the item, set it as the #strres and crop to your likings to get the physical resist and set that as your pre/base line for comparison. Then imbue, and check the same attributes via event property and probably compare string results.  That's what I'd do, just keep it simple and stable to start.

Offline cgeorgemo

  • Hero Member
  • *
  • Posts: 586
  • Activity:
    0%
  • Reputation Power: 5
  • cgeorgemo has no influence.
  • Gender: Male
  • I'm Brian...cgeorgemo is Curious George Missouri
  • Respect: +36
  • Referrals: 1
    • View Profile
Re: Question About Getting a Value From Item Property
« Reply #2 on: November 13, 2009, 02:05:38 PM »
0
Just check the journal to see if you've got the message you successfully imbue the item.
Why wouldn't that work?
If you are imbuing physical resist it shouldn't be any different than the script we used to make fragment's checks for success when we threw Hit Life Leech on something.
Sarcasm is your body's natural defense against stupidity.

Offline PauloniusTopic starter

  • Elite
  • *
  • *
  • Posts: 2040
  • Activity:
    0%
  • Reputation Power: 29
  • Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.Paulonius is on the verge of being accepted.
  • Respect: +304
  • Referrals: 1
    • View Profile
Re: Question About Getting a Value From Item Property
« Reply #3 on: November 14, 2009, 02:54:03 AM »
0
What would be the fun in that?

It required a bit more work than I had hoped, but I figured it out.

http://www.scriptuo.com/index.php?topic=3343.0
This coin declares Caesar is "Dictator for Life." He did serve as Dictator for the remainder of his life, but his life would end only a few weeks after this issue. For Caesar to put his image on coins and essentially declare himself king was too much for Brutus and his republican allies.

"If everything seems under control, you're not going fast enough'
-Mario Andretti

"If everyone is thinking alike, someone isn't thinking."
- General George Patton Jr

Tags: