Request Mir 2 - Crystal - Script help

Destroyer1987

Racoon
Dedicated Member
Feb 15, 2013
82
9
35
In The Shadows
Hi,

After a simple global shout npc script.

I have a basic knowledge of scripting, as learning myself.

But cannot get a global npc to work. Just want a simple script costing gold for a global shout over server.

Any help is appreciated, using mir wiki to script but stuck on this one.
 

Sanjian

Just a Mir2 Fan
VIP
Apr 28, 2011
3,957
5
2,074
350
East Sussex
Hi,

After a simple global shout npc script.

I have a basic knowledge of scripting, as learning myself.

But cannot get a global npc to work. Just want a simple script costing gold for a global shout over server.

Any help is appreciated, using mir wiki to script but stuck on this one.

take a look at this section from the wiki

Code:
[h=3]Input Request[/h] You can ask for a players input by requesting a value to be entered.  This is achieved by using two "@@" symbols instead of one in a button.  Once the response is inputted it will be stored in the value %INPUTSTR  for the remainder of the page. 
 [@MAIN]
#SAY
Q. How many classes are there in Mir?
<Answer Question/@@QUESTION>

[@@QUESTION]
#ACT
MOV A1 %INPUTSTR
LOCALMESSAGE "You entered <$OUTPUT(A1)>" Hint

now you can output something someones inputted you just have to play around with it

off the top of my head and havent tested this.

Code:
[@Main]
#SAY
You can pay 1k for a global shout

<Global Shout/@globalshout>

[@globalshout]
#IF
CHECKGOLD >= 1000
#ACT
TAKEGOLD 1000
GOTO @globalshoutpaid
#ELSESAY
you dont have 1k


[@globalshoutpaid]
#SAY
What do you wish to shout?

<Input/@@inputglobalshout>

[@@inputglobalshout]
#ACT
MOV A1 %INPUTSTR
GLOBALMESSAGE "<$USERNAME>: <$OUTPUT(A1)>" System

i tested this in game and works fine just needs tyding up
 
Upvote 0

Destroyer1987

Racoon
Dedicated Member
Feb 15, 2013
82
9
35
In The Shadows
I have another question rather then making a new thread.

How do you create your own autopatcher? What program do people use? Would a program like this be used to make custom interface as well?

Again sorry for all questions. Trying to learn as much as I can.
 
Upvote 0

LightBringer

Primordial GM
Veteran
Primordial
Game Master
Feb 13, 2014
3,838
1
1,751
260
I have another question rather then making a new thread.

How do you create your own autopatcher? What program do people use? Would a program like this be used to make custom interface as well?

Again sorry for all questions. Trying to learn as much as I can.

There is an autopatcher client with the source code AFAIK.
You need to upload your client to a host and configure the autopatcher accordingly.

custom interfaces, you need to get your images then add them in via the source code.
 
  • Like
Reactions: Destroyer1987
Upvote 0