WimpleDesigns
Member
I tried Using this script i found Its a Runescape Chat Script for Netplay Plus and I Tried using it but i got an error...
http://img182.imageshack.us/img182/5069/image8wg6.png[/img]
I dont know what it means can you guys help?
heres the script
http://img182.imageshack.us/img182/5069/image8wg6.png[/img]
I dont know what it means can you guys help?
heres the script
#===============================================================================
# ** Scene_Chat (2)
#-------------------------------------------------------------------------------
# Author Shark_Tooth
# Version 1.0
# Date 11-04-06
# Controls
# F5 makes it visible/active. You can click on the map to disable it and
# click on the chat again to make it active.
#===============================================================================
SDK.log("Chat2", "Shark_Tooth", "1.0", " 24-05-06")
if SDK.state('Chat2') == true and User_Edit::CHAT_SYSTEM == 'Chat[2]'
class Scene_Map
#-------------------------------------------------------------------------
alias st_rchat_main_draw main_draw
alias st_rchat_update_systems update_systems
alias st_rchat_main_dispose main_dispose
#-------------------------------------------------------------------------
# * Main Draw
#--------------------------------------------------------------------------
def main_draw
#Calls the chat windows but hides it
@rChat_window = Window_Chat.new #Calls the chat window
@rChat_window.active = false #Disables it
@rChat_window.visible = false #Hides it
@rChat_window.z += 9000 #Makes it appear on top
@rChat_window.height = 116 #Makes the window smaller
@rChat_window.y = 316 #Moves it down
@rInput_window = Window_ChatInput.new #Calls the input window
@rInput_window.active = false #Disables it
@rInput_window.visible = false #Hides it
@rInput_window.z += 9000 #Makes it uppear on top
#Calls the other windows in Scene Map
st_rchat_main_draw
end
#--------------------------------------------------------------------------
# * Main Dispose
#--------------------------------------------------------------------------
def main_dispose
#Disposes the chat windows.
@rChat_window.dispose
@rInput_window.dispose
st_rchat_main_dispose
end
#--------------------------------------------------------------------------
# * Update Systems
#--------------------------------------------------------------------------
def update_systems
st_rchat_update_systems
update_rchat
end
#--------------------------------------------------------------------------
# * Update rChat
#--------------------------------------------------------------------------
def update_rchat
if Input.trigger?(Input::F5) and @rChat_window.visible == false
@rChat_window.active = true
@rChat_window.visible = true
@rInput_window.active = true
@rInput_window.visible = true
elsif Input.trigger?(Input::F5) and @rChat_window.visible == true
@rChat_window.active = false
@rChat_window.visible = false
@rInput_window.active = false
@rInput_window.visible = false
return
end
update_mouse_rcontrols if @rInput_window.visible or @rChat_window.visible
return if @rInput_window.active == false or @rChat_window.active == false
#update keys
update_rup_keys if !Input.pressed?(Input::Shift)
update_rlow_keys if Input.pressed?(Input::Shift)
#Updates Enter, Space, F5, ESC, F6
update_rcontrols
# Update Background and windows
@rChat_window.update if $game_temp.chat_refresh
@rInput_window.update if @rInput_window.old_text != @rInput_window.text.size
end
#--------------------------------------------------------------------------
# * Update Mouse rcontrols
#--------------------------------------------------------------------------
def update_mouse_rcontrols
#Checks if Left Mouse Buttons is pressed
if Input.pressed?(Input::Mouse_Left)
#Checks the position of the mouse and enables/disables chat
if mouse_over?(@rChat_window) or mouse_over?(@rInput_window)
$game_system.se_play($data_system.decision_se) if not @rInput_window.active
@rInput_window.active = true
@rChat_window.active = true
return true
end
@rInput_window.active = false
@rChat_window.active = false
return false
end
end
#--------------------------------------------------------------------------
# Check Mouse over window?
#--------------------------------------------------------------------------
def mouse_over?(window)
if $mouse.x > window.x and $mouse.x < window.x + window.width and
$mouse.y > window.y and $mouse.y < window.y + window.height
return true
end
return false
end
#-------------------------------------------------------------------------
# * Updates Enter, Space, F5, ESC, F6
#-------------------------------------------------------------------------
def update_rcontrols
# Sends chat message.
if Input.triggerd?(13)
if @rInput_window.text.size == 0
$game_system.se_play($data_system.buzzer_se)
return
elsif User_Edit::ENABLE_MC
for mp in Network::Main.mapplayers.values
next if mp == nil
next if mp.map_id != $game_map.map_id
name = Network::Main.name
textss = @rInput_window.text
Network::Main.mchat(mp.netid,"#{name}) #{textss}")
end
name = Network::Main.name
textss = @rInput_window.text
id = Network::Main.id
Network::Main.mchat(id,"#{name}) #{textss}")
@rInput_window.text.clear
return
else
name = Network::Main.name
Network::Main.socket.send("<chat>#{name}) #{@rInput_window.text}</chat>\n")
@rInput_window.text.clear
return
end
end
# Clear the Chat Log
$game_temp.chat_log.clear if Input.triggerd?(Input::Fkeys[6])
#Space
@rInput_window.text.push(" ") if Input.triggerd?(Input::Space)
# Removes last entry in test.
@rInput_window.text.delete_at(-1) if Input.triggerd?(Input::Back) and @rInput_window.text.size != 0
end
#-------------------------------------------------------------------------
# * Updates UpperKeys
#-------------------------------------------------------------------------
def update_rup_keys
#Checks for Numberkeys input.
for key in Input::Numberkeys.keys
@rInput_window.text.push(key.to_s) if Input.triggerd?(Input::Numberkeys[key])
end
#Checks for Letter input.
for key in Input::Letters.keys
@rInput_window.text.push(key.downcase.to_s) if Input.triggerd?(Input::Letters[key])
end
#Checks for other keys
@rInput_window.text.push("-") if Input.triggerd?(Input::Underscore)
@rInput_window.text.push(".") if Input.triggerd?(Input::Dot)
@rInput_window.text.push(",") if Input.triggerd?(Input::Comma)
@rInput_window.text.push("/") if Input.triggerd?(Input::Backslash)
@rInput_window.text.push("'") if Input.triggerd?(Input::Quote)
@rInput_window.text.push("=") if Input.triggerd?(Input::Equal)
end
#-------------------------------------------------------------------------
# * Updates LowerKeys
#-------------------------------------------------------------------------
def update_rlow_keys
#Checks for Numberkeys input.
for key in Input::Numberkeys.keys
if Input.triggerd?(Input::Numberkeys[key])
@rInput_window.text.push("!") if key == 1
@rInput_window.text.push("@") if key == 2
@rInput_window.text.push("#") if key == 3
@rInput_window.text.push("$") if key == 4
@rInput_window.text.push("%") if key == 5
@rInput_window.text.push("^") if key == 6
@rInput_window.text.push("&") if key == 7
@rInput_window.text.push("*") if key == 8
@rInput_window.text.push("(") if key == 9
@rInput_window.text.push(")") if key == 0
end
end
#Checks for Letter input.
for key in Input::Letters.keys
@rInput_window.text.push(key.upcase.to_s) if Input.triggerd?(Input::Letters[key])
end
#Checks for Other keys
@rInput_window.text.push("_") if Input.triggerd?(Input::Underscore)
@rInput_window.text.push(">") if Input.triggerd?(Input::Dot)
@rInput_window.text.push("<") if Input.triggerd?(Input::Comma)
@rInput_window.text.push("?") if Input.triggerd?(Input::Backslash)
@rInput_window.text.push("''") if Input.triggerd?(Input::Quote)
@rInput_window.text.push("+") if Input.triggerd?(Input::Equal)
end
end
#-------------------------------------------------------------------------
# End Enable SDK Check
#-------------------------------------------------------------------------
end
# ** Scene_Chat (2)
#-------------------------------------------------------------------------------
# Author Shark_Tooth
# Version 1.0
# Date 11-04-06
# Controls
# F5 makes it visible/active. You can click on the map to disable it and
# click on the chat again to make it active.
#===============================================================================
SDK.log("Chat2", "Shark_Tooth", "1.0", " 24-05-06")
if SDK.state('Chat2') == true and User_Edit::CHAT_SYSTEM == 'Chat[2]'
class Scene_Map
#-------------------------------------------------------------------------
alias st_rchat_main_draw main_draw
alias st_rchat_update_systems update_systems
alias st_rchat_main_dispose main_dispose
#-------------------------------------------------------------------------
# * Main Draw
#--------------------------------------------------------------------------
def main_draw
#Calls the chat windows but hides it
@rChat_window = Window_Chat.new #Calls the chat window
@rChat_window.active = false #Disables it
@rChat_window.visible = false #Hides it
@rChat_window.z += 9000 #Makes it appear on top
@rChat_window.height = 116 #Makes the window smaller
@rChat_window.y = 316 #Moves it down
@rInput_window = Window_ChatInput.new #Calls the input window
@rInput_window.active = false #Disables it
@rInput_window.visible = false #Hides it
@rInput_window.z += 9000 #Makes it uppear on top
#Calls the other windows in Scene Map
st_rchat_main_draw
end
#--------------------------------------------------------------------------
# * Main Dispose
#--------------------------------------------------------------------------
def main_dispose
#Disposes the chat windows.
@rChat_window.dispose
@rInput_window.dispose
st_rchat_main_dispose
end
#--------------------------------------------------------------------------
# * Update Systems
#--------------------------------------------------------------------------
def update_systems
st_rchat_update_systems
update_rchat
end
#--------------------------------------------------------------------------
# * Update rChat
#--------------------------------------------------------------------------
def update_rchat
if Input.trigger?(Input::F5) and @rChat_window.visible == false
@rChat_window.active = true
@rChat_window.visible = true
@rInput_window.active = true
@rInput_window.visible = true
elsif Input.trigger?(Input::F5) and @rChat_window.visible == true
@rChat_window.active = false
@rChat_window.visible = false
@rInput_window.active = false
@rInput_window.visible = false
return
end
update_mouse_rcontrols if @rInput_window.visible or @rChat_window.visible
return if @rInput_window.active == false or @rChat_window.active == false
#update keys
update_rup_keys if !Input.pressed?(Input::Shift)
update_rlow_keys if Input.pressed?(Input::Shift)
#Updates Enter, Space, F5, ESC, F6
update_rcontrols
# Update Background and windows
@rChat_window.update if $game_temp.chat_refresh
@rInput_window.update if @rInput_window.old_text != @rInput_window.text.size
end
#--------------------------------------------------------------------------
# * Update Mouse rcontrols
#--------------------------------------------------------------------------
def update_mouse_rcontrols
#Checks if Left Mouse Buttons is pressed
if Input.pressed?(Input::Mouse_Left)
#Checks the position of the mouse and enables/disables chat
if mouse_over?(@rChat_window) or mouse_over?(@rInput_window)
$game_system.se_play($data_system.decision_se) if not @rInput_window.active
@rInput_window.active = true
@rChat_window.active = true
return true
end
@rInput_window.active = false
@rChat_window.active = false
return false
end
end
#--------------------------------------------------------------------------
# Check Mouse over window?
#--------------------------------------------------------------------------
def mouse_over?(window)
if $mouse.x > window.x and $mouse.x < window.x + window.width and
$mouse.y > window.y and $mouse.y < window.y + window.height
return true
end
return false
end
#-------------------------------------------------------------------------
# * Updates Enter, Space, F5, ESC, F6
#-------------------------------------------------------------------------
def update_rcontrols
# Sends chat message.
if Input.triggerd?(13)
if @rInput_window.text.size == 0
$game_system.se_play($data_system.buzzer_se)
return
elsif User_Edit::ENABLE_MC
for mp in Network::Main.mapplayers.values
next if mp == nil
next if mp.map_id != $game_map.map_id
name = Network::Main.name
textss = @rInput_window.text
Network::Main.mchat(mp.netid,"#{name}) #{textss}")
end
name = Network::Main.name
textss = @rInput_window.text
id = Network::Main.id
Network::Main.mchat(id,"#{name}) #{textss}")
@rInput_window.text.clear
return
else
name = Network::Main.name
Network::Main.socket.send("<chat>#{name}) #{@rInput_window.text}</chat>\n")
@rInput_window.text.clear
return
end
end
# Clear the Chat Log
$game_temp.chat_log.clear if Input.triggerd?(Input::Fkeys[6])
#Space
@rInput_window.text.push(" ") if Input.triggerd?(Input::Space)
# Removes last entry in test.
@rInput_window.text.delete_at(-1) if Input.triggerd?(Input::Back) and @rInput_window.text.size != 0
end
#-------------------------------------------------------------------------
# * Updates UpperKeys
#-------------------------------------------------------------------------
def update_rup_keys
#Checks for Numberkeys input.
for key in Input::Numberkeys.keys
@rInput_window.text.push(key.to_s) if Input.triggerd?(Input::Numberkeys[key])
end
#Checks for Letter input.
for key in Input::Letters.keys
@rInput_window.text.push(key.downcase.to_s) if Input.triggerd?(Input::Letters[key])
end
#Checks for other keys
@rInput_window.text.push("-") if Input.triggerd?(Input::Underscore)
@rInput_window.text.push(".") if Input.triggerd?(Input::Dot)
@rInput_window.text.push(",") if Input.triggerd?(Input::Comma)
@rInput_window.text.push("/") if Input.triggerd?(Input::Backslash)
@rInput_window.text.push("'") if Input.triggerd?(Input::Quote)
@rInput_window.text.push("=") if Input.triggerd?(Input::Equal)
end
#-------------------------------------------------------------------------
# * Updates LowerKeys
#-------------------------------------------------------------------------
def update_rlow_keys
#Checks for Numberkeys input.
for key in Input::Numberkeys.keys
if Input.triggerd?(Input::Numberkeys[key])
@rInput_window.text.push("!") if key == 1
@rInput_window.text.push("@") if key == 2
@rInput_window.text.push("#") if key == 3
@rInput_window.text.push("$") if key == 4
@rInput_window.text.push("%") if key == 5
@rInput_window.text.push("^") if key == 6
@rInput_window.text.push("&") if key == 7
@rInput_window.text.push("*") if key == 8
@rInput_window.text.push("(") if key == 9
@rInput_window.text.push(")") if key == 0
end
end
#Checks for Letter input.
for key in Input::Letters.keys
@rInput_window.text.push(key.upcase.to_s) if Input.triggerd?(Input::Letters[key])
end
#Checks for Other keys
@rInput_window.text.push("_") if Input.triggerd?(Input::Underscore)
@rInput_window.text.push(">") if Input.triggerd?(Input::Dot)
@rInput_window.text.push("<") if Input.triggerd?(Input::Comma)
@rInput_window.text.push("?") if Input.triggerd?(Input::Backslash)
@rInput_window.text.push("''") if Input.triggerd?(Input::Quote)
@rInput_window.text.push("+") if Input.triggerd?(Input::Equal)
end
end
#-------------------------------------------------------------------------
# End Enable SDK Check
#-------------------------------------------------------------------------
end