01-06-2006, 09:58 PM
Originally posted by grimsk8ter11
Difficulty: 1/5
Full copy and paste, but it does explain stuff, int he first one so you actually get it
EditorInit() - Replace the WHOLE sub with
Well theres really nto much to explain, instead of opening another file to memory, it losds the editors images directly from the current surfaces using BitBlt to move them from the surface to the pic boxes.
ItemEditorInit() - Replace the whole sub
[code]
Public Sub ItemEditorInit()
'*********************************************************** *****
'* WHEN WHO WHAT
'* ---- --- ----
'* 07/12/2005 Shannara Added gfx constant.
'* 10/29/2005 Grim Now loads from Item surface
'*********************************************************** *****
Dim DC As Long
DC = DD_ItemSurf.GetDC
Call BitBlt(frmItemEditor.picItems.hdc, 0, 0, DDSD_Item.lWidth, DDSD_Item.lHeight, DC, 0, 0, vbSrcCopy)
DD_ItemSurf.ReleaseDC (DC)
frmItemEditor.txtName.Text = Trim(Item(EditorIndex).Name)
frmItemEditor.scrlPic.Value = Item(EditorIndex).Pic
frmItemEditor.cmbType.ListIndex = Item(EditorIndex).Type
If (frmItemEditor.cmbType.ListIndex >= ITEM_TYPE_WEAPON) And (frmItemEditor.cmbType.ListIndex = ITEM_TYPE_POTIONADDHP) And (frmItemEditor.cmbType.ListIndex
Difficulty: 1/5
Full copy and paste, but it does explain stuff, int he first one so you actually get it
EditorInit() - Replace the WHOLE sub with
Code:
Public Sub EditorInit()
'*********************************************************** *****
'* WHEN WHO WHAT
'* ---- --- ----
'* 07/12/2005 Shannara Added gfx constants.
'* 10/29/2005 Grim Now loads from Tile surface
'*********************************************************** *****
Dim DC As Long
SaveMap = Map
InEditor = True
frmMirage.picMapEditor.Visible = True
With frmMirage.picBackSelect
.Width = 7 * PIC_X
.Height = 255 * PIC_Y
End With
DC = DD_TileSurf.GetDC
Call BitBlt(frmMirage.picBackSelect.hdc, 0, 0, DDSD_Tile.lWidth, DDSD_Tile.lHeight, DC, 0, 0, vbSrcCopy)
DD_TileSurf.ReleaseDC (DC)
End Sub
Well theres really nto much to explain, instead of opening another file to memory, it losds the editors images directly from the current surfaces using BitBlt to move them from the surface to the pic boxes.
ItemEditorInit() - Replace the whole sub
[code]
Public Sub ItemEditorInit()
'*********************************************************** *****
'* WHEN WHO WHAT
'* ---- --- ----
'* 07/12/2005 Shannara Added gfx constant.
'* 10/29/2005 Grim Now loads from Item surface
'*********************************************************** *****
Dim DC As Long
DC = DD_ItemSurf.GetDC
Call BitBlt(frmItemEditor.picItems.hdc, 0, 0, DDSD_Item.lWidth, DDSD_Item.lHeight, DC, 0, 0, vbSrcCopy)
DD_ItemSurf.ReleaseDC (DC)
frmItemEditor.txtName.Text = Trim(Item(EditorIndex).Name)
frmItemEditor.scrlPic.Value = Item(EditorIndex).Pic
frmItemEditor.cmbType.ListIndex = Item(EditorIndex).Type
If (frmItemEditor.cmbType.ListIndex >= ITEM_TYPE_WEAPON) And (frmItemEditor.cmbType.ListIndex = ITEM_TYPE_POTIONADDHP) And (frmItemEditor.cmbType.ListIndex