08-10-2008, 08:53 PM
Tested and working
Mp Attribute Tile
:: SERVER SIDE ::
In modTypes, add:
In modGamelogic, go to Sub PlayerMove, and add:
:: CLIENT SIDE ::
In modTypes, add:
In modGamelogic, find:
Beneath that, add:
Find:
Beneath that, add:
Ok go in to frmMirage, or frmMapEditor which everone that you have and make a option button call it optMP and your done.
Also side note, if you have converted to having frmMapEditor change the above code to:
Ok here's a extra code set for the stamina
SP Attribute Tile
:: SERVER SIDE ::
In modTypes, add:
In modGamelogic, go to Sub PlayerMove, and add:
:: CLIENT SIDE ::
In modTypes, add:
In modGamelogic, find:
Beneath that, add:
Find:
Beneath that, add:
Ok go in to frmMirage, or frmMapEditor which everone that you have and make a option button call it optSP and your done.
Also side note, if you have converted to having frmMapEditor change the above code to:
Mp Attribute Tile
:: SERVER SIDE ::
In modTypes, add:
Code:
Public Const TILE_TYPE_MP = 11
Code:
If Map(GetPlayerMap(Index)).Tile(GetPlayerX(Index), GetPlayerY(Index)).Type = TILE_TYPE_MP Then
Call SetPlayerMP(Index, GetPlayerMaxMP(Index))
Call SendMP(Index)
Call PlayerMsg(Index, "You feel a sudden rush of energy through your body as you regain mana!", BrightBlue)
End If
:: CLIENT SIDE ::
In modTypes, add:
Code:
Public const TILE_TYPE_MP = 11
Code:
If .Type = TILE_TYPE_BLOCKED Then Call DrawText(TexthDC, x * PIC_X + 8, y * PIC_Y + 8, "B", QBColor(BrightRed))
Code:
If .Type = TILE_TYPE_MP Then Call DrawText(TexthDC, x * PIC_X + 8, y * PIC_Y + 8, "MP", QBColor(BrightGreen))
Code:
If frmMirage.optWarp.Value = True Then
.Type = TILE_TYPE_WARP
.Data1 = EditorWarpMap
.Data2 = EditorWarpX
.Data3 = EditorWarpY
End If
Code:
If frmMirage.optMP.Value = True Then
.Type = TILE_TYPE_MP
.Data1 = 0
.Data2 = 0
.Data3 = 0
End If
Also side note, if you have converted to having frmMapEditor change the above code to:
Code:
If frmMapeditor.optMP.Value = True Then
.Type = TILE_TYPE_MP
.Data1 = 0
.Data2 = 0
.Data3 = 0
End If
SP Attribute Tile
:: SERVER SIDE ::
In modTypes, add:
Code:
Public Const TILE_TYPE_SP = 12
Code:
If Map(GetPlayerMap(Index)).Tile(GetPlayerX(Index), GetPlayerY(Index)).Type = TILE_TYPE_SP Then
Call SetPlayerSP(Index, GetPlayerMaxSP(Index))
Call SendSP(Index)
Call PlayerMsg(Index, "You feel a sudden rush of energy through your body as you regain Stamina!", BrightYellow)
End If
:: CLIENT SIDE ::
In modTypes, add:
Code:
Public const TILE_TYPE_SP = 12
Code:
If .Type = TILE_TYPE_BLOCKED Then Call DrawText(TexthDC, x * PIC_X + 8, y * PIC_Y + 8, "B", QBColor(BrightRed))
Code:
If .Type = TILE_TYPE_SP Then Call DrawText(TexthDC, x * PIC_X + 8, y * PIC_Y + 8, "SP", QBColor(BrightYellow))
Code:
If frmMirage.optWarp.Value = True Then
.Type = TILE_TYPE_WARP
.Data1 = EditorWarpMap
.Data2 = EditorWarpX
.Data3 = EditorWarpY
End If
Code:
If frmMirage.optMP.Value = True Then
.Type = TILE_TYPE_SP
.Data1 = 0
.Data2 = 0
.Data3 = 0
End If
Also side note, if you have converted to having frmMapEditor change the above code to:
Code:
If frmMapeditor.optMP.Value = True Then
.Type = TILE_TYPE_SP
.Data1 = 0
.Data2 = 0
.Data3 = 0
End If