<%@ LANGUAGE=VBScript codepage ="936" %>
<%Response.Expires=0
Response.ExpiresAbsolute = Now() - 1
Response.AddHeader "Pragma","No-Cache"
Response.AddHeader "Cache-Control","Private"
Response.CacheControl = "No-Cache"

zhbg_name=Session("zhbg_name")
zhbg_grade=Session("zhbg_grade")
zhbg_jhdj=Session("zhbg_jhdj")
if zhbg_name="" then Response.Redirect "../../error.asp?id=440"
if Instr(LCase(Application("zhbg_useronlinename"&session("nowinroom")))," "&LCase(zhbg_name)&" ")=0 then
	Response.Write "<script Language=Javascript>alert('你不能进行操作，进行此操作必须进入聊天室！');location.href = 'javascript:history.go(-1)';</script>"
	Response.End
end if
if zhbg_jhdj<10 then
	Response.Write "<script language=JavaScript>{alert('提示：你不够10级，还是先练练技术吧!');location.href = 'javascript:history.go(-1)';}</script>"
	Response.End 
end if
Set conn=Server.CreateObject("ADODB.CONNECTION")
Set rs=Server.CreateObject("ADODB.RecordSet")
conn.open Application("zhbg_usermdb")
rs.open "select 体力,状态,道德 from 用户 where 姓名='" & zhbg_name &"'",conn,2,2
if rs("体力")<10000 then
    Response.Write "<script language=JavaScript>{alert('提示：你的体力不够1万，先练练吧!');location.href = 'javascript:history.go(-1)';}</script>"
	Response.End 
end if
if rs("状态")="死" then
    Response.Write "<script language=JavaScript>{alert('提示：你已经死了，先去复活吧!');location.href = 'javascript:history.go(-1)';}</script>"
	Response.End 
end if
if rs("道德")<500 then
    Response.Write "<script language=JavaScript>{alert('提示：你的道德不够500，谁敢相信你?');location.href = 'javascript:history.go(-1)';}</script>"
	Response.End 
end if
Session("diaoyu")=now()
Response.Redirect "diao.asp"
%>