MessageHistory

Stores the messages you send and allows you to recall them with ctrl+up and ctrl+down; Your current message is at the end of ctrl+down if you don't start typing.

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==   
// @name            MessageHistory
// @namespace       skyboy@kongregate
// @author          skyboy
// @version         1.1.0
// @description     Stores the messages you send and allows you to recall them with ctrl+up and ctrl+down; Your current message is at the end of ctrl+down if you don't start typing.
// @include         http://www.kongregate.com/games/*/*
// @homepage        http://userscripts.org/scripts/show/73998
// ==/UserScript==   
if (/^\/?games\/[^\/]+\/[^\/?]+(\?.*)?$/.test(window.location.pathname))
setTimeout(function() {
	window.location.assign("javascript:void(document.observe('holodeck:ready',function(Q){(Q=ChatDialogue.prototype).onKeyUp=function(a){if (!this.msgs){this.msgs=[];this.cInx=0}if(a.ctrlKey||a.keyCode==17){switch(a.keyCode){case 38:if(!this.oldMsg&&this.cInx==0)this.oldMsg=this.value;if(this.cInx<this.msgs.length)this.value=this.msgs[this.msgs.length-(++this.cInx)];return;case 40:if(this.cInx>1){this.value=this.msgs[this.msgs.length-(--this.cInx)];}else{this.value=this.oldMsg||''};case 17:return;}}this.oldMsg='';this.cInx=0}; ChatDialogue.prototype.onKeyDown=function(a){if(a.keyCode==13&&this.value.trim()!=''){if(!this.msgs){this.msgs=[];this.cInx=0}this.msgs.push(this.value);this.oldMsg='';this.cInx=0}};var q=ChatDialogue.prototype.initialize;ChatDialogue.prototype.initialize=function(){q.apply(this, arguments);var b=this._input_node;b.observe('keyup',this.onKeyUp);b.observe('keydown',this.onKeyDown)};holodeck.chatWindow()._rooms.each(function(T){T=T.value._chat_dialogue._input_node.observe('keyup',Q.onKeyUp).observe('keydown',Q.onKeyDown)})}))");
}, 1250);