[Script] [ACE] Script Disabler
[align=center][size=large]Script Disabler[/size]
Version: 1.1
Author: TDS
Date: August 2, 2012[/align]
[chapter]Giới thiệu[/chapter]
Script này giúp bạn "tắt" các script khác. Dùng để test các script giống nhau hoặc là tìm mấy cái script nào gây lỗi với nhau thì rất good.
[chapter]Cách dùng[/chapter]

[chapter]Script[/chapter]
Credit: TDS
Chỉ sử dụng cho dự án miễn phí.
[chapter]Đôi lời tác giả[/chapter]
Có nhiều cách để "tắt script như là: thêm "__END__" vào trên cùng của script, hoặc đơn giản là đặt dưới main, và cái script này chỉ là 1 sự lựa chọn khác và nó giúp tôi rất nhiều khi làm việc với số lượng lớn script, tôi nghĩ nó sẽ giúp ích cho các scripter khác.
[chapter]Đôi lời người viết:[/chapter]
Tuy hơi cũ nhưng mà chất. :thoaimai:
Version: 1.1
Author: TDS
Date: August 2, 2012[/align]
[chapter]Giới thiệu[/chapter]
Script này giúp bạn "tắt" các script khác. Dùng để test các script giống nhau hoặc là tìm mấy cái script nào gây lỗi với nhau thì rất good.
[chapter]Cách dùng[/chapter]

[chapter]Script[/chapter]
#==============================================================================
# ** TDS_Script_Disabler
# Ver: 1.1
#------------------------------------------------------------------------------
# * Description:
# This Script allows you to disable a group of scripts.
#------------------------------------------------------------------------------
# * Features:
# Disable scripts.
#------------------------------------------------------------------------------
# * Instructions:
#
# To disable a group of scripts make 2 new blank scripts and in their name
# add this:
#
# <Disabled_Scripts>
#
# </Disabled_Scripts>
#
# Any scripts put between these 2 new scripts will be disabled at the start
# of the game.
#------------------------------------------------------------------------------
# * Notes:
# The script names are the names on the left side box not inside the script
# itself.
#
# There is no limit to the amount of scripts groups you can disable.
#------------------------------------------------------------------------------
# WARNING:
#
# Do not release, distribute or change my work without my expressed written
# consent, doing so violates the terms of use of this work.
#
# If you really want to share my work please just post a link to the original
# site.
#
# * Not Knowing English or understanding these terms will not excuse you in any
# way from the consequenses.
#==============================================================================
# * Import to Global Hash *
#==============================================================================
($imported ||= {})[:TDS_Script_Disabler] = true
# Scripts Delete List Array
delete_list = []
# Delete Activd Flag
delete_active = false
# Go through Scripts
$RGSS_SCRIPTS.each_with_index {|data, i|
# Activate or Deactivate Delete Active Flag
delete_active = true if data.at(1) =~ /<Disabled_Scripts>/i
delete_active = false if data.at(1) =~ /<\/Disabled_Scripts>/i
# Add Script Data to Delete Scripts if delete flag is active
delete_list << i if delete_active
}
# Clear Text in Scripts
delete_list.each {|i| $RGSS_SCRIPTS[i][2] = $RGSS_SCRIPTS[i][3] = ""}
# Clear All Delete Values
delete_list = delete_active = delete_list = nil
[chapter]Credit và Điều khoản sử dụng[/chapter]Credit: TDS
Chỉ sử dụng cho dự án miễn phí.
[chapter]Đôi lời tác giả[/chapter]
Có nhiều cách để "tắt script như là: thêm "__END__" vào trên cùng của script, hoặc đơn giản là đặt dưới main, và cái script này chỉ là 1 sự lựa chọn khác và nó giúp tôi rất nhiều khi làm việc với số lượng lớn script, tôi nghĩ nó sẽ giúp ích cho các scripter khác.
[chapter]Đôi lời người viết:[/chapter]
Tuy hơi cũ nhưng mà chất. :thoaimai:
Comments
THAM GIA GROUP CỦA TTC TRÊN FACEBOOK
THAM GIA GROUP CỦA TTC TRÊN FACEBOOK