Sign in to follow this  
Followers 0
Tsukihime

feature
Actor Requirement

3 posts in this topic

Feature: Actor Requirement

-Tsukihime

 

This script allows you to set actor requirements for weapons and armors.

 

Download

 

Script: http://db.tt/Q0t35QUJ

Required: Feature Manager

 

Usage

 

Tag weapons/armors with

 

<ft: actor_req id>

 

Where `id` is the actor ID in the database.

The requirement means that only specific actors may equip it. Your actor must be able to equip the type of weapon/armor.

Edited by Tsukihime
oriceles likes this

Share this post


Link to post
Share on other sites

Hello Tsukihime, I think (I think heh..) you have made an error in your script.

 

Assuming our command as NOTETAG must be: actor_req..

Why is there 'class_req' in this block of ruby code:

  alias :ft_actor_req_armor_ok? :feature_equip_armor_ok?
  def feature_equip_armor_ok?(item)
    set = item_features_set(item, :class_req, 0) ## HERE
    return false if !(set.empty? || set.include?(@actor_id))
    ft_actor_req_armor_ok?(item)
  end

So.. This is why it seems the right code should be:

  alias :ft_actor_req_armor_ok? :feature_equip_armor_ok?
  def feature_equip_armor_ok?(item)
    set = item_features_set(item, :actor_req, 0)
    return false if !(set.empty? || set.include?(@actor_id))
    ft_actor_req_armor_ok?(item)
  end

No?

 

By the way... Your scripts are amazing, I will use some for sure, and if one day I want sell my games, be sure I'll buy a commercial license from you!

Share this post


Link to post
Share on other sites

I hate to be a bother, but I was wondering if you could repost this. Only, the link doesn't work anymore. :3

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

  • Recently Browsing   0 members

    No registered users viewing this page.