|
-
February 18th, 2008, 07:39 PM
#1
Extract From .exe
Hey guys,
I well with the last problem i got fixed.
BUT
now all my graphics are inside my .exe file.
I like that, now no one can edit my graphics, but yet i cant even use them =/
i beilve i need to use the get command
Code:
Open sFile For Binary Access Read As #ifreefile
Get #ifreefile, , sBuf
but how do i use this?
im new to all this lol, and cant find it on internet i dont knw what i need to search for.
Thanks for all the helps guys
-
February 18th, 2008, 07:58 PM
#2
Re: Extract From .exe
Hey im gonna wirte down all my code sorry i dident put in last post but here it is
This is on server side to say that they are patching and what files
Code:
Case "CHR(PATCH)"
SendPatch "Patch\game.exe", "game.exe", pintWinsockNo
SendPatch "Patch\toolbar6.jpg", "\Graphics\toolbar6.jpg", pintWinsockNo
SendPatch "Patch\desktop.jpg", "\Graphics\desktop.jpg", pintWinsockNo
SendPatch "Patch\dropdown1.jpg", "\Graphics\dropdown.jpg", pintWinsockNo
SendPatch "Patch\lloginscreen.jpg", "\Graphics\lloginscreen.jpg", pintWinsockNo
SendPatch "Patch\messenger.jpg", "\Graphics\messenger.jpg", pintWinsockNo
Code:
Public Sub SendPatch(sFile As String, sSaveAs As String, intwinsock As Integer)
On Error GoTo ErrHandler
Dim sSend As String, sBuf As String
Dim ifreefile As Integer
Dim lRead As Long, lLen As Long, lThisRead As Long, lLastRead As Long
ifreefile = FreeFile
' Open file for binary access:
Open sFile For Binary Access Read As #ifreefile
lLen = LOF(ifreefile)
' Loop through the file, loading it up in chunks of 64k:
Do While lRead < lLen
lThisRead = 65536
If lThisRead + lRead > lLen Then
lThisRead = lLen - lRead
End If
If Not lThisRead = lLastRead Then
sBuf = Space$(lThisRead)
End If
Get #ifreefile, , sBuf
lRead = lRead + lThisRead
sSend = sSend & sBuf
Loop
lTotal = lLen
Close ifreefile
bSendingFile = True
'// Send the file notification
frmServer.wskServer(intwinsock).SendData "FILE" & sSaveAs
DoEvents
'// Send the file
frmServer.wskServer(intwinsock).SendData sSend
DoEvents
'// Finished
frmServer.wskServer(intwinsock).SendData "FILEEND"
bSendingFile = False
Exit Sub
ErrHandler:
MsgBox "Err " & Err & " : " & Error
-
February 18th, 2008, 08:27 PM
#3
Re: Extract From .exe
What are you trying to do? You are creating new files.
-
February 18th, 2008, 08:32 PM
#4
Re: Extract From .exe
well at first i was trying to extract the files to the users computer. in a folder called Graphics,
but then it made my .exe file bigger and i found out all the pictures i tryed to send over is now in my .exe file, now i need to extract them and put it i guess as a temp file. so when i close the client all the files get deleted.
so basicly
Open client, then it extracts the pictures to \graphics then after client unloads to deletes all the graphics
-
February 18th, 2008, 08:42 PM
#5
Re: Extract From .exe
What do you mean the jpg's are 'in the .exe' ???
-
February 18th, 2008, 08:47 PM
#6
Re: Extract From .exe
Be nice to Harley riders...
-
February 18th, 2008, 08:58 PM
#7
Re: Extract From .exe
You don't replace them like that. You could use a Resource File, but you'd have to replace the exe, which you're doing
-
February 19th, 2008, 07:50 AM
#8
Re: Extract From .exe
It looks a little as if you send secretely an executable to the other computer which is connected to your game...
What is this going to be?
-
February 19th, 2008, 01:05 PM
#9
Re: Extract From .exe
If your images are CURRENTLY stored in the exe like you said in your first post, then you already know how to extract them as you said. The code that you posted to replace an exe has little to do with the question or problem.
Hope you aren't playing with us here.
-
February 19th, 2008, 02:15 PM
#10
Re: Extract From .exe
That's what I was starting to wonder...
-
February 19th, 2008, 04:15 PM
#11
Re: Extract From .exe
Im not playing with you guys,
i am being honest i really dont knw how to extract them out,
i have tryed using other code to extract it but its not working,
Like at first when i set the .exe threw winsock.
it was 1.25 mb big
then i sent 5 pictures that were suppose to save to
/graphics
but it never did so i moved the .exe file to my patch folder were the patches come form and then the .exe file was
3.25 mb big, not 1.25 mb big
and when i tryed to extract the the pictures from the .exe nothing comes out, so i dont knw if its in the .exe as
/graphics
or
game.exe/graphics
i really have no clue i wouldent be wasting your guys time if i knew how to do this,
-
February 19th, 2008, 04:27 PM
#12
Re: Extract From .exe
Do you have an ImageList that is in a Resource File that is compiled into your EXE so that Images don't have to be stored on disk separately?
-
February 19th, 2008, 04:45 PM
#13
Re: Extract From .exe
so i could just use the images off my .exe? insted of extracting them off??
-
February 19th, 2008, 04:48 PM
#14
Re: Extract From .exe
ohhh kk sorry no i dont have a image list,
in my game i just added one and saw what it did.
but the problem is that it use to all be seperated untill i send the .exe with the graphics at the same time, it has everything todo with the code thats the problem, they have methods of extracting stuff out of .exe file
same way as world of warcraft is
inside the wow.exe
it has all the images and data so ppl cant edit them, so when they do patches it just edits the .exe file nothing else
-
February 19th, 2008, 05:36 PM
#15
Re: Extract From .exe
Now read this part again... 
Do you have an ImageList that is in a Resource File that is compiled into your EXE so that Images don't have to be stored on disk separately?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|