Hotel Map Moral
Printed From: Mirage Source
Category: Tutorials
Forum Name: Temporary Archive (Read Only)
Forum Discription: Temporary 3.0.3 archive tutorials, will be deleted when converted.
URL: http://ms.shannaracorp.com/backup-forums/forum_posts.asp?TID=202
Printed Date: 20 December 2006 at 5:53pm Software Version: Web Wiz Forums 8.01 - http://www.webwizforums.com
Topic: Hotel Map Moral
Posted By: Sync
Subject: Hotel Map Moral
Date Posted: 11 February 2006 at 3:28pm
Difficulty: Easy 2/5
Originaly Posted By: Dragoons Master
Hotel Map Moral Very fun and easy
CLIENT SIDE:
modGameLogic, under:
' Party request
add:
' Map inn If LCase(Mid(MyText, 1, 10)) = "/sleep" Then Call SendInnSleep MyText = "" Exit Sub End If
in modClientTCP, under :
Sub SendJoinParty()
add, this sub:
Sub SendInnSleep() Dim Packet As String Packet = "INNSLEEP" & SEP_CHAR & END_CHAR Call SendData(Packet) End Sub
In frmMapProperties add to the list of cmbMoral a new line and type on it "Inn"
SERVER SIDE:
In modClientTCP, under:
' :: Respawn map packet ::
add:
' :::::::::::::::::::::::::: ' :: Sleep Request packet :: ' :::::::::::::::::::::::::: If LCase(Parse(0)) = "innsleep" Then If Map(GetPlayerMap(Index)).Moral = MAP_MORAL_INN Then Call TakeItem(Index, 1, 100) 'Change the valeu from 1(ItemNum) for the # you want and 100(GetValue) from the # you want Call SetPlayerHP(Index, GetPlayerMaxHP(Index)) Call SetPlayerMP(Index, GetPlayerMaxMP(Index)) Call SetPlayerSP(Index, GetPlayerMaxSP(Index)) Call SendHP(Index) Call SendMP(Index) Call SendSP(Index) Call PlayerMsg(Index, "You sleep...", White) Else Call PlayerMsg(Index, "You cant sleep here...", White) End If Exit Sub End If
Done!
Can some 1 post an add to this, that if inn is selected on cmdMoral in frmMapProperties it apears 2 txtboxes and on it you type the item and the value that you wana get?
Edit: Forgot to add the type
Server and client, in modTypes
unde:
Public Const MAP_MORAL_SAFE = 1
add:
Public Const MAP_MORAL_INN = 2
|
|