Mirage Source

Free ORPG making software.
It is currently Sun Apr 28, 2024 4:02 pm

All times are UTC


Forum rules


Make sure your tutorials are kept up to date with the latest MS4 releases.



Post new topic Reply to topic  [ 1254 posts ]  Go to page 1, 2, 3, 4, 5 ... 51  Next
Author Message
PostPosted: Fri Oct 17, 2008 10:37 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
100% working and tested!
If it doesnt work thats your fault for messing something up.

SPOILER: (click to show)
Open up frmMirage and add a command button called
btnAdmin

double click and a code window will pop up, Put this inbetween Private Sub btnAdmin_Click() and End Sub right under it.
Code:
    If GetPlayerAccess(MyIndex) >= ADMIN_MONITER Then
        frmAdmin.Visible = True
        Else
    If GetPlayerAccess(MyIndex) >= 0 Then
        frmAdmin.Visible = False
     Call AddText("You cannot open up the admin menu.", BrightRed)
    End If
  End If


You can add a F1 Or a button if you want..If you want to follow what I put above click the spoiler...(I tested it but most people might want something else)

Then download frmAdmin and add it to the src Folder.

RAPIDSHARE - http://rapidshare.com/files/155030086/frmAdmin.frm.html
MEGAUPLOAD - http://www.megaupload.com/?d=1QE92IQ1


Then you done! Thanks Credits to

10% Me
70% Doomteam1
20% For my lungs letting me breath to give oxygen to my brain.


Last edited by Dane on Fri Oct 17, 2008 11:22 pm, edited 1 time in total.

Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:02 pm 
Offline
Knowledgeable
User avatar

Joined: Tue May 30, 2006 1:42 am
Posts: 346
Location: Florida
Why do you make a btnAdmin, and that button is viewable to everyone who is or is not a admin, so go into frmMirage and in form_load add
Code:
If GetPlayerAccess(MyIndex) >= ADMIN_MONITER Then
        btnAdmin.Visible = True
        Else
    If GetPlayerAccess(MyIndex) >= 0 Then
        btnAdmin.Visible = False
     Call AddText("You do NOT have access to that selection.", BrightRed)
    End If
  End If

then make btnAdmin's visibilty false through it's own properties
(I think that will work, do not qoute me on it though)
and add the f1 key to form key up the way it was done in the old tuts

_________________
shut your manpleaser
http://www.kazmostech.com


Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:03 pm 
Offline
Regular
User avatar

Joined: Sun Mar 02, 2008 2:21 am
Posts: 50
I thought ADMIN_MONITER had been changed already?

_________________
Image


Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:07 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
Thanks dark X and Hikaru I didnt change my moniter =\


Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:08 pm 
Offline
Knowledgeable
User avatar

Joined: Tue May 30, 2006 1:42 am
Posts: 346
Location: Florida
check that code before you use it, and whats diffrent between this one and the other one? didn't care to check 'cause I don't use MS4

_________________
shut your manpleaser
http://www.kazmostech.com


Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:10 pm 
Offline
Persistant Poster
User avatar

Joined: Fri Aug 15, 2008 3:11 pm
Posts: 633
thanks for giving me credit
and nice

_________________
╔╗╔═╦═╦══╦═══╗
║║║║║║║╔╗║╔═╗║
║║║║║║║╚╝║║║║║
║╚╣║║║║╔╗║╚═╝║
╚═╩╩═╩╩╝╚╩═══╝


╔╦═╦╦════╦═══╗
║║║║╠═╗╔═╣╔══╝
║║║║║║║║╚═╗
║║║║║║║║╔═╝
╚═╩═╝╚╝╚╝ ?


Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:20 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
np doom.


Top
 Profile  
 
PostPosted: Fri Oct 17, 2008 11:44 pm 
Offline
Knowledgeable
User avatar

Joined: Tue May 30, 2006 1:42 am
Posts: 346
Location: Florida
Now Open frmMirage and in sub Form_KeyUp()
Right under:
Code:
Call CheckInput(0, KeyCode, Shift)

Add:
Code:
If KeyCode = vbKeyF1 Then
If Player(MyIndex).Access > 0 Then
frmAdmin.Visible = False

frmAdmin.Visible = True
End If
End If

there is the code for you Night, makes it so when you push f1 the admin panel appears.

_________________
shut your manpleaser
http://www.kazmostech.com


Top
 Profile  
 
PostPosted: Sat Oct 18, 2008 2:56 am 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
you forgot Else.. You put a space instead...(I think.)

If KeyCode = vbKeyF1 Then
If Player(MyIndex).Access > 0 Then
frmAdmin.Visible = False
Else
frmAdmin.Visible = True
End If
End If


Top
 Profile  
 
PostPosted: Sat Oct 18, 2008 9:13 pm 
Offline
Knowledgeable
User avatar

Joined: Tue May 30, 2006 1:42 am
Posts: 346
Location: Florida
I just c&p'd from the old forums, so just change it as needed, why not add the posts I made into yours then put your button codes in there so that people who are new will know what your talking about.

_________________
shut your manpleaser
http://www.kazmostech.com


Top
 Profile  
 
PostPosted: Sun Oct 19, 2008 10:16 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
I think ill just remake this whole thing sence i COMPLETELY Changed my admin panel lol. also

Please help..I changed something in my frmMirage and now when i hit enter to send a message on chat it doesnt send and it makes a DING sound...Like a low dong like...You know what i mean... here is my frm mirage code..

Code:
Option Explicit

Private Sub btnAdmin_Click()
    If GetPlayerAccess(MyIndex) >= 1 Then
        frmAdmin.Visible = True
        Else
    If GetPlayerAccess(MyIndex) >= 0 Then
        frmAdmin.Visible = False
     Call AddText("You cannot open up the admin menu.", BrightRed)
    End If
  End If
End Sub


' ******************************************
' **            Mirage Source 4           **
' ******************************************

Private Sub Form_Load()
    frmMirage.Width = 10080
End Sub

Private Sub Form_Unload(Cancel As Integer)
    Call DestroyGame
End Sub

' Winsock event
Private Sub Socket_DataArrival(ByVal bytesTotal As Long)
    If IsConnected Then
        Call IncomingData(bytesTotal)
    End If
End Sub


Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
    Call CheckInput(1, KeyCode, Shift)
End Sub

Private Sub Form_KeyUp(KeyCode As Integer, Shift As Integer)
    Call CheckInput(0, KeyCode, Shift)
End Sub

Private Sub picScreen_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)

    If InEditor Then
        Call MapEditorMouseDown(Button, Shift, X, Y)
    Else
        Call PlayerSearch
    End If
   
    Call SetFocusOnChat
End Sub

Private Sub picScreen_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    CurX = X \ PIC_X
    CurY = Y \ PIC_Y
   
    If InEditor Then
        shpLoc.Visible = False
       
        If Button = vbLeftButton Or Button = vbRightButton Then
            Call MapEditorMouseDown(Button, Shift, X, Y)
        End If
    End If

End Sub

Private Sub txtMyChat_Change()
    MyText = txtMyChat
End Sub

Private Sub txtChat_GotFocus()
    SetFocusOnChat
End Sub

Private Sub picInventory_Click()
    Call UpdateInventory
    picInv.Visible = True
End Sub

Private Sub lblUseItem_Click()
    Call SendUseItem(frmMirage.lstInv.ListIndex + 1)
End Sub

Private Sub lblDropItem_Click()
Dim Value As Long
Dim InvNum As Long

    InvNum = frmMirage.lstInv.ListIndex + 1

    If GetPlayerInvItemNum(MyIndex, InvNum) > 0 Then
        If GetPlayerInvItemNum(MyIndex, InvNum) <= MAX_ITEMS Then
            If Item(GetPlayerInvItemNum(MyIndex, InvNum)).Type = ITEM_TYPE_CURRENCY Then
                ' Show them the drop dialog
                frmDrop.Show vbModal
            Else
                Call SendDropItem(frmMirage.lstInv.ListIndex + 1, 0)
            End If
        End If
    End If
End Sub

Private Sub lblCast_Click()
    If Player(MyIndex).Spell(lstSpells.ListIndex + 1) > 0 Then
        If GetTickCount > Player(MyIndex).AttackTimer + 1000 Then
            If Player(MyIndex).Moving = 0 Then
                Call SendData(CCast & SEP_CHAR & lstSpells.ListIndex + 1 & END_CHAR)
                Player(MyIndex).Attacking = 1
                Player(MyIndex).AttackTimer = GetTickCount
                Player(MyIndex).CastedSpell = YES
            Else
                Call AddText("Cannot cast while walking!", BrightRed)
            End If
        End If
    Else
        Call AddText("No spell here.", BrightRed)
    End If
End Sub

Private Sub lblCancel_Click()
    picInv.Visible = False
End Sub

Private Sub lblSpellsCancel_Click()
    picPlayerSpells.Visible = False
End Sub

Private Sub lstinv_GotFocus()
On Error Resume Next
    frmMirage.picScreen.SetFocus
End Sub

Private Sub lstspells_GotFocus()
On Error Resume Next
    frmMirage.picScreen.SetFocus
End Sub

Private Sub picSpells_Click()
    Call SendData(CSpells & END_CHAR)
End Sub

Private Sub picStats_Click()
    Call SendData(CGetStats & END_CHAR)
End Sub

Private Sub picTrain_Click()
    frmTraining.Show vbModal
End Sub

Private Sub picTrade_Click()
    Call SendData(CTrade & END_CHAR)
End Sub

Private Sub picQuit_Click()
    isLogging = True
    InGame = False
    Call SendData(CQuit & END_CHAR)
    Call DestroyTCP
End Sub

' // MAP EDITOR STUFF //

Private Sub optLayers_Click()
    If optLayers.Value Then
        fraLayers.Visible = True
        fraAttribs.Visible = False
    End If
End Sub

Private Sub optAttribs_Click()
    If optAttribs.Value Then
        fraLayers.Visible = False
        fraAttribs.Visible = True
    End If
End Sub

Private Sub picBackSelect_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    Call MapEditorChooseTile(Button, Shift, X, Y)
End Sub
 
Private Sub picBackSelect_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    shpLoc.Top = (Y \ PIC_Y) * PIC_Y
    shpLoc.Left = (X \ PIC_X) * PIC_X
   
    shpLoc.Visible = True
End Sub

Private Sub cmdSend_Click()
    Call MapEditorSend
End Sub

Private Sub cmdCancel_Click()
    Call MapEditorCancel
End Sub

Private Sub cmdProperties_Click()
    frmMapProperties.Show vbModal
End Sub

Private Sub optWarp_Click()
    frmMapWarp.Show vbModal
End Sub

Private Sub optItem_Click()
    frmMapItem.Show vbModal
End Sub

Private Sub optKey_Click()
    frmMapKey.Show vbModal
End Sub

Private Sub optKeyOpen_Click()
    frmKeyOpen.Show vbModal
End Sub

Private Sub scrlPicture_Change()
    Call MapEditorTileScroll
End Sub

Private Sub cmdFill_Click()
    MapEditorFillLayer
End Sub

Private Sub cmdClear_Click()
    Call MapEditorClearLayer
End Sub

Private Sub cmdClear2_Click()
    Call MapEditorClearAttribs
End Sub

Private Sub scrlTileSet_Change()

    frmMirage.scrlPicture.Max = (frmMirage.picBackSelect.Height \ PIC_Y) - (frmMirage.picBack.Height \ PIC_Y)

    Map.TileSet = scrlTileSet.Value
    lblTileset = scrlTileSet.Value
   
    Call InitTileSurf(scrlTileSet)
   
    Call BltMapEditor
    Call BltMapEditorTilePreview
End Sub


Anything wrong?


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 4:14 am 
Offline
Regular

Joined: Wed Jan 16, 2008 8:50 pm
Posts: 60
Ok, so I looked through your code, and as far as I can tell everything looks fine (except one little error I will point out in a minute). I think the problem may be in your Sub HandleKeyPresses. I will post my On Return part of the sub below.

SPOILER: (click to show)
Code:
    ' Handle when the player presses the return key
    If KeyAscii = vbKeyReturn Then
        ' Broadcast message
        If Left$(ChatText, 1) = "'" Then
            ChatText = Mid$(ChatText, 2, Len(ChatText) - 1)
            If Len(ChatText) > 0 Then
                Call BroadcastMsg(ChatText)
            End If
            MyText = vbNullString
            frmMirage.txtMyChat.Text = vbNullString
            Exit Sub
        End If
       
        ' Emote message
        If Left$(ChatText, 1) = "-" Then
            MyText = Mid$(ChatText, 2, Len(ChatText) - 1)
            If Len(ChatText) > 0 Then
                Call EmoteMsg(ChatText)
            End If
            MyText = vbNullString
            frmMirage.txtMyChat.Text = vbNullString
            Exit Sub
        End If
       
        ' Player message
        If Left$(ChatText, 1) = "!" Then
            ChatText = Mid$(ChatText, 2, Len(ChatText) - 1)
            Name = vbNullString
                   
            ' Get the desired player from the user text
            For i = 1 To Len(ChatText)
                If Mid$(ChatText, i, 1) <> " " Then
                    Name = Name & Mid$(ChatText, i, 1)
                Else
                    Exit For
                End If
            Next i
                   
            ' Make sure they are actually sending something
            If Len(ChatText) - i > 0 Then
                MyText = Mid$(ChatText, i + 1, Len(ChatText) - i)
                   
                ' Send the message to the player
                Call PlayerMsg(ChatText, Name)
            Else
                Call AddText("Usage: !playername msghere", AlertColor)
            End If
            MyText = vbNullString
            frmMirage.txtMyChat.Text = vbNullString
            Exit Sub
        End If
       
        ' Global Message
        If Left$(ChatText, 1) = vbQuote Then
            If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                ChatText = Mid$(ChatText, 2, Len(ChatText) - 1)
                If Len(ChatText) > 0 Then
                    Call GlobalMsg(ChatText)
                End If
                MyText = vbNullString
                frmMirage.txtMyChat.Text = vbNullString
                Exit Sub
            End If
        End If
   
        ' Admin Message
        If Left$(ChatText, 1) = "=" Then
            If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                ChatText = Mid$(ChatText, 2, Len(ChatText) - 1)
                If Len(ChatText) > 0 Then
                    Call AdminMsg(MyText)
                End If
                MyText = vbNullString
                frmMirage.txtMyChat.Text = vbNullString
                Exit Sub
            End If
        End If
           
        If Left$(MyText, 1) = "/" Then
            Command = Split(MyText, " ")
           
            Select Case Command(0)
                Case "/help"
                    Call AddText("Social Commands:", HelpColor)
                    Call AddText("'msghere = Broadcast Message", HelpColor)
                    Call AddText("-msghere = Emote Message", HelpColor)
                    Call AddText("!namehere msghere = Player Message", HelpColor)
                    Call AddText("Available Commands: /help, /info, /who, /fps, /inv, /stats, /train, /trade, /party, /join, /leave", HelpColor)
                                   
                Case "/info"
                    ' Checks to make sure we have more than one string in the array
                    If UBound(Command) >= 1 Then
                        Call SendData(CPlayerInfoRequest & SEP_CHAR & Command(1) & END_CHAR)
                    End If
           
                ' Whos Online
                Case "/who"
                    SendWhosOnline
                               
                ' Checking fps
                Case "/fps"
                    BFPS = Not BFPS
                                           
                ' Show inventory
                Case "/inv"
                    UpdateInventory
                    frmMirage.picInv.Visible = True
               
                ' Request stats
                Case "/stats"
                    SendData CGetStats & END_CHAR
           
                ' Show training
                Case "/train"
                    frmTraining.Show vbModal
                           
                ' Request stats
                Case "/trade"
                    SendData CTrade & END_CHAR
                   
                ' Party request
                Case "/party"
                    ' Make sure they are actually sending something
                    If UBound(Command) >= 1 Then
                        Call SendPartyRequest(Command(1))
                    Else
                        Call AddText("Usage: /party playernamehere", AlertColor)
                    End If
                   
                ' Join party
                Case "/join"
                    SendJoinParty
               
                ' Leave party
                Case "/leave"
                    SendLeaveParty
               
                ' // Moniter Admin Commands //
                ' Admin Help
                Case "/admin"
                    If GetPlayerAccess(MyIndex) > 0 Then
                        Call AddText("Social Commands:", HelpColor)
                        Call AddText("""msghere = Global Admin Message", HelpColor)
                        Call AddText("=msghere = Private Admin Message", HelpColor)
                        Call AddText("Available Commands: /admin, /loc, /mapeditor, /warpmeto, /warptome, /warpto, /setsprite, /mapreport, /kick, /ban, /edititem, /respawn, /editnpc, /motd, /editshop, /editspell", HelpColor)
                    End If
               
                ' Kicking a player
                Case "/kick"
                    If GetPlayerAccess(MyIndex) > 0 Then
                        If UBound(Command) >= 1 Then
                            SendKick Command(1)
                        End If
                    End If
                           
                ' // Mapper Admin Commands //
                ' Location
                Case "/loc"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        BLoc = Not BLoc
                    End If
               
                ' Map Editor
                Case "/mapeditor"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        SendRequestEditMap
                    End If
                Case "/editmap"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        SendRequestEditMap
                    End If
               
                ' Warping to a player
                Case "/warpmeto"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        If UBound(Command) >= 1 Then
                            WarpMeTo Command(1)
                        End If
                    End If
                           
                ' Warping a player to you
                Case "/warptome"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        If UBound(Command) >= 1 Then
                            WarpToMe Command(1)
                        End If
                    End If
                           
                ' Warping to a map
                Case "/warpto"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        If UBound(Command) Then
                            n = CLng(Command(1))
                       
                            ' Check to make sure its a valid map #
                            If n > 0 And n <= MAX_MAPS Then
                                Call WarpTo(n)
                            Else
                                Call AddText("Invalid map number.", Red)
                            End If
                        End If
                    End If
               
                ' Setting sprite
                Case "/setsprite"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        If UBound(Command) >= 1 Then
                            SendSetSprite CLng(Command(1))
                        End If
                    End If
               
                ' Map report
                Case "/mapreport"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        SendData CMapReport & END_CHAR
                    End If
           
                ' Respawn request
                Case "/respawn"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        SendMapRespawn
                    End If
           
                ' MOTD change
                Case "/motd"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        If UBound(Command) >= 1 Then
                            'If Len(MyText) > 0 Then
                                SendMOTDChange Command(1)
                            'End If
                        End If
                    End If
               
                ' Check the ban list
                Case "/banlist"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        SendBanList
                    End If
               
                ' Banning a player
                Case "/ban"
                    If GetPlayerAccess(MyIndex) >= ADMIN_MAPPER Then
                        If UBound(Command) >= 1 Then
                            SendBan Command(1)
                        End If
                    End If
               
                ' // Developer Admin Commands //
                ' Editing item request
                Case "/edititem"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditItem
                    End If
                Case "/itemeditor"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditItem
                    End If
               
                ' Editing npc request
                Case "/editnpc"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditNpc
                    End If
                Case "/npceditor"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditNpc
                    End If
               
                ' Editing shop request
                Case "/editshop"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditShop
                    End If
                Case "/shopeditor"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditShop
                    End If
           
                ' Editing spell request
                Case "/editspell"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditSpell
                    End If
                Case "/spelleditor"
                    If GetPlayerAccess(MyIndex) >= ADMIN_DEVELOPER Then
                        SendRequestEditSpell
                    End If
               
                ' // Creator Admin Commands //
                ' Giving another player access
                Case "/setaccess"
                    If GetPlayerAccess(MyIndex) >= ADMIN_CREATOR Then
                        If UBound(Command) >= 2 Then
                            SendSetAccess Command(2), CLng(Command(1))
                        End If
                    End If
               
                ' Ban destroy
                Case "/destroybanlist"
                    If GetPlayerAccess(MyIndex) >= ADMIN_CREATOR Then
                        SendBanDestroy
                    End If
               
                Case Else
                    AddText "Not a valid command!", HelpColor
            End Select
           
            MyText = vbNullString
            frmMirage.txtMyChat.Text = vbNullString
            Exit Sub
        End If
       
        ' Say message
        If Len(ChatText) > 0 Then
            Call SayMsg(ChatText)
        End If
        MyText = vbNullString
        frmMirage.txtMyChat.Text = vbNullString
        Exit Sub
    End If




Now thats out of the way, let me point out something in the Sub btnAdmin_Click().

If you look at it

SPOILER: (click to show)
Code:
Private Sub btnAdmin_Click()
    If GetPlayerAccess(MyIndex) >= 1 Then
        frmAdmin.Visible = True
        Else
    If GetPlayerAccess(MyIndex) >= 0 Then
        frmAdmin.Visible = False
     Call AddText("You cannot open up the admin menu.", BrightRed)
    End If
  End If
End Sub


You will notice that it checks to see if your access is greater than or equal too 1, in which case it makes the form visible. Imediately after that, it checks to see if your access is GREATER than or equal to ZERO and then set the form visible to false. So you have one if making the form visible, and the next one making it not so visible.

This should work though, if im not mistaken

SPOILER: (click to show)
Code:
Private Sub btnAdmin_Click()
    If GetPlayerAccess(MyIndex) >= 1 Then
        frmAdmin.Visible = True
    Else
        frmAdmin.Visible = False
        Call AddText("You cannot open up the admin menu.", BrightRed)
    End If
End Sub


If I'm reading this Sub btnAdmin_click wrong, please let me know, although it seems to make sense to me.

Also if you want the btnAdmin to be visible to only admins, just add this in the Sub Form_Load right underneath
Code:
frmMirage.Width = 10080

Sure you can still edit the client to show the button, but with proper checks on the server side, it shouldn't matter.

SPOILER: (click to show)
Code:
    If GetPlayerAccess(MyIndex) >= 1 Then
        frmMirage.btnAdmin.Visible = True
    Else
        frmMirage.btnAdmin.Visible = False


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 4:51 am 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
Where is the Sub HandleKeyPresses? frmMirage? if it is then i must have deleted it by accident


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 5:10 am 
Offline
Persistant Poster
User avatar

Joined: Tue May 30, 2006 2:07 am
Posts: 836
Location: Nashville, Tennessee, USA
Google Talk: rs.ruggles@gmail.com
Should be in a module somewhere. Probably game logic.

_________________
I'm on Facebook! Google Plus My Youtube Channel My Steam Profile

Image


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 8:17 am 
Offline
Regular

Joined: Wed Jan 16, 2008 8:50 pm
Posts: 60
Yeah, it is in modGameLogic. If you are having trouble finding it, just ctrl + F Sub HandleKeypresses and it should pop up.


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 4:48 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
I replaced mine with no errors and still the same thing..I hit enter and nothing happens


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 9:17 pm 
Offline
Regular

Joined: Wed Jan 16, 2008 8:50 pm
Posts: 60
Take the last couple of things you have added in, and comment them out one at a time. Once it starts letting you send the error message, uncomment everything except the last thing you commented out, also one at a time. This will narrow it down to what lines are causing the error. You might also me able to use this to find which line in the sub/mod/etc. is causing the error, but that would take a little more though. If you find the line thats causing the error, and still can't figure it out, then put the code here, and I'll look over it for you.


Top
 Profile  
 
PostPosted: Mon Oct 20, 2008 11:51 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
How am I suppost to find it when there isnt an error. =\


Top
 Profile  
 
PostPosted: Tue Oct 21, 2008 1:49 am 
Offline
Community Leader
User avatar

Joined: Sun May 28, 2006 10:29 pm
Posts: 1762
Location: Salt Lake City, UT, USA
Google Talk: Darunada@gmail.com
step through the code until it stops?

_________________
I'm on Facebook! Google Plus LinkedIn My Youtube Channel Send me an email Call me with Skype Check me out on Bitbucket Yup, I'm an EVE Online player!
Why not try my app, ColorEye, on your Android devlce?
Do you like social gaming? Fight it out in Battle Juice!

I am a professional software developer in Salt Lake City, UT.


Top
 Profile  
 
PostPosted: Tue Oct 21, 2008 6:10 pm 
Offline
Regular
User avatar

Joined: Tue Sep 30, 2008 6:04 pm
Posts: 47
>.< I dont know what to search in lol.


Top
 Profile  
 
PostPosted: Sat Dec 13, 2008 10:21 pm 
Offline
Regular
User avatar

Joined: Tue Jun 03, 2008 6:22 pm
Posts: 50
Quote:
Open up frmMirage and add a command button called
btnAdmin


Sorry <- Complete noob... lol
How do i add a command button '?

i looked everywhere and cant seem to find anything like this...
lol i even tried google..
and still..
any help for a nooby ?


Top
 Profile  
 
PostPosted: Sat Dec 13, 2008 11:30 pm 
Offline
Persistant Poster
User avatar

Joined: Tue May 30, 2006 2:07 am
Posts: 836
Location: Nashville, Tennessee, USA
Google Talk: rs.ruggles@gmail.com
Image

_________________
I'm on Facebook! Google Plus My Youtube Channel My Steam Profile

Image


Top
 Profile  
 
PostPosted: Sat Dec 13, 2008 11:52 pm 
Offline
Regular
User avatar

Joined: Tue Jun 03, 2008 6:22 pm
Posts: 50
thank you rian, but im still getting a variable not defined compile error
leading me to ADMIN_MONITER


Top
 Profile  
 
PostPosted: Sun Dec 14, 2008 1:10 am 
Offline
Regular

Joined: Wed Jan 16, 2008 8:50 pm
Posts: 60
I believe admin_moniter has been corrected to admin_monitor. Change that in the code, should work.


Top
 Profile  
 
PostPosted: Sun Dec 14, 2008 2:37 am 
Offline
Regular
User avatar

Joined: Tue Jun 03, 2008 6:22 pm
Posts: 50
lol well that fixed that problem death. lol
but then i got introduced to another crap load of other problems..
oh well :\

thanks guys for helping me.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1254 posts ]  Go to page 1, 2, 3, 4, 5 ... 51  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 42 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group