PDA

View Full Version : Sleepy v1.3



SC_Modder
07-27-2006, 12:50 AM
My sleepyness at 4AM inspired me to make this.

This dll puts a hook in SC's drawing routines and calls Sleep(1) so that starcraft won't use 100% CPU.

v1.1: Added 5 second delay before the hook kicks in, that way those who load Starcraft with inhale's loader won't have slow load times.

v1.2: Updated to SC version 1.14.

v1.3: Fixed a crash whenever the dll was unloaded

Download Here (http://www.harvestourdemons.com/upload/files/25/Sleepy.rar)

You can inject the dll with this program:
http://www.bwhacks.com/forums/showthread.php?t=15385

Zaund
07-27-2006, 12:55 AM
O.o...I...I love you....

SC_Modder
07-27-2006, 12:56 AM
I'd like to add it is relatively untested, so go my forum minions! Test away.

JLTucker
07-27-2006, 12:59 AM
HAHAHHA. Untested?


DISCLAIMER:
This program has been throughly tested, and does not
cause harm to the user's computer, but I am NOT
responsible for any harm that comes to you via improper
use of this program.

SC_Modder
07-27-2006, 01:01 AM
I replaced "don't remember placing any calls to DeleteFile" with "throughly tested" in that case. :p There's only 69 lines of code (LOL 69 OMG) in it anyway.

It's basically a generic disclaimer I slap on every hack of mine now-a-days.

gamepin126
07-27-2006, 01:16 AM
SCM, you're sexy.

XGhozt
07-27-2006, 01:24 AM
Dude, thats so awsome, last time I played starcraft my mouse was moving slow, becuase trillian was open... Mabey this will help :) Props!

Permision to host files?

howardmeis
07-27-2006, 06:40 AM
This could be used for other games too. Maybe for dual boxing on L2 could have each one streaming. ^.^

SilentAgent
07-27-2006, 08:24 AM
Omg I love this.

Ideal Maxima
07-27-2006, 08:27 AM
SC's drawing routines and calls Sleep(1) so that starcraft won't use 100% CPU.


I don't get it. I run all my programs (Including Limewire) while playing sc. I don't get any lag or anything. How can this program help me? =\

SilentAgent
07-27-2006, 08:30 AM
You dont have to lag..the thing is...ugh nevermind someone else explaing why I dl this.

XpLoiTeD
07-27-2006, 08:36 AM
Some people (most) tend to lag if they have other programs running the same time Starcraft is. If you check your Taskbar Manager while Starcraft is open, U'll see that Starcraft uses 100% of your CPU to Run. I haven't downloaded this, but from what it says, im guessing this program stops that crappy part, using less of your computer, making you lag less, so your able to run other programs as you play. Say Winamp/Limewire/Aim/Msn anything that would normally make you lag, w/out this.

howardmeis
07-27-2006, 08:36 AM
So that SC doesn't use up 100% of your CPU. So you can do other things like scan for virus' or burn CD's/DVD's while playing.

Ideal Maxima
07-27-2006, 08:38 AM
oOo I got it, thanks.

Also, My brother and I play sc over battle.net all the time.

But lately, he's been lagging like a bitch.

Is this because we're both using the same wireless router and IP? Or is his Laptop just lagging? If it's his laptop, will this fix it?

howardmeis
07-27-2006, 08:51 AM
I've heard that b.net lags when you use the same router for it. I forgot how to fix it though, sorry. Do some searching, the answer's somewhere on here.

XpLoiTeD
07-27-2006, 09:16 AM
From seeing a few brothers play, I've only realized they cant join eachothers games, too much Lat from their routers, they didnt seem to lag tho. But its a good chance the lag is because you both are loading SC same time. Try Using this program, maybe it will get rid of the lag

Cryingsoul15
07-27-2006, 09:34 AM
Firefox, can't get a connection! :mad:

Please reupload here (http://www.rapidshare.de)

Edit: Nevermind! I got it.

putis
07-27-2006, 09:36 AM
Works fine for me.

Zephyrix
07-27-2006, 09:59 AM
Uh, taskmanager -> priority -> Low

punture
07-29-2006, 09:31 PM
GG CPU = NO DL

XGhozt
07-30-2006, 09:54 PM
I dont understand this, I load the hack and then the game free'z every like 2 seconds and it mess's everyone up. Thats useless.

SC_Modder
07-30-2006, 09:58 PM
It depends on your computer really. Other people might have better results.

gamepin126
07-30-2006, 10:09 PM
Can I suggest a 5 second delay before it kicks in?

SC_Modder
07-30-2006, 10:27 PM
Why? Are you loading at startup or something?

XGhozt
07-30-2006, 10:40 PM
It depends on your computer really. Other people might have better results.

Thats not the case, I had many other things open and they where running smoothly, as soon asi restart starcraft without your dll loaded, its fine.



Why? Are you loading at startup or something?

Are we not supposed to? :stare:

SC_Modder
07-30-2006, 10:56 PM
I added the 5 second delay, hence version 1.1.

For me, I leave task manager open and play about 30 seconds of SC in single player. Most of the time my CPU is less than or about 50%, when normally it would be 100%.

gamepin126
07-30-2006, 11:11 PM
gj

Cryingsoul15
07-31-2006, 08:43 AM
You should fix the memory leak in your firefox, Gampin.



You have probably noticed that Firefox takes a large amount of RAM after some browsing (sometimes over 100 MiB). This is not a real fix, but it helps greatly.

To do:
Opet Firefox;
In the adress bar type about:config;
Right click in the page and select New -> Boolean;
Type config.trim_on_minimize in the popup box and press Enter;
In the new box select True and press Enter;
Restart Firefox.After doing this, your Firefox (when minimized) will dump most of the taken memory (it will take less than 10 MiB). When restored, it will take less memory than when it is freshly started.


NOTE: This works only for Windows users.

howardmeis
07-31-2006, 08:51 AM
1337 crying thanks. +rep.

SC_Modder
07-31-2006, 10:35 AM
Gamepin, when SC is minimized the CPU is zero anyway. You have to leave the performance tab open and then look at your CPU graph afterwards.

SatansMessiah
07-31-2006, 10:56 AM
Blackbox.exe LOL!!!

hba
07-31-2006, 11:14 AM
God damnit, connection to HoD keeps timing out. I just got another new BW CD and I can't dl this. :frown:

Sinz
07-31-2006, 12:56 PM
/me can send it to you via aim or put it on rapidshare if its ok with SCM

hba
07-31-2006, 01:02 PM
Thanks for offer, but I got it from SCM via email.

707
07-31-2006, 01:18 PM
Very secksy. Gj

SC_Modder
07-31-2006, 05:43 PM
Updated for patch v1.14. As soon as dt fixes his injector you'll be able to use it. In case that won't be for a while I'm cooking up one in the meantime.

gamepin126
07-31-2006, 05:44 PM
Do I need inhale installed? I have other loaders.

SC_Modder
07-31-2006, 05:48 PM
It doesn't need inhale, in can stand on its own.

K? Pŕo?ćtiόnŹ
07-31-2006, 08:59 PM
Rename his dll inhale and use the loader =O

Bush_Master
07-31-2006, 10:33 PM
umm, you cant inject .dll files yet into sc :( need new loader b4 we can and if its not the loader then i dont know cuz, damnation says
Damnation v1.0 Created by Drakken
Brood War window found.
Unable to open the process!
WriteprocessMemory Failed!

LCS
07-31-2006, 10:48 PM
New patch, old hack, I'm closing it because of idiots like that.

rum
08-01-2006, 08:27 AM
The hack has been updated, LCS.

Reopened.

XpLoiTeD
08-01-2006, 05:23 PM
Hm What if you use BWLauncher and PP? I take it you cant use this?

gamepin126
08-01-2006, 06:03 PM
Nothing can detect this.

StarteR2
08-01-2006, 06:42 PM
You can use this program with this injector (http://www.bwhacks.com/forums/showthread.php?t=15385). Host already mentioned it. All you gotta fo is make a DIE say C:/Sleepy and put the injector's executable there + a text file with any name (ex. load.txt), write in the text file the dll's name including extations (ex. SleepY.dll) case sensitive and put the dll in same dir, it will work, i tested it with multi command, thanks SCM

preelude
08-01-2006, 07:08 PM
doesnt work for me, injected it with your loader and played a few games, cpu usage is still 100%

after i exit bw i get an error message

Brood War: starcraft.exe - Application Error
The instruction at "0x02151200" referenced memory at "0x004e40fa". The memory could not be "written".
Click on OK to terminate the program

must be the fifth time i tried... always an error when i exit bw with sleepy injected.

however if i only use kc.dll theres no error and multicmd works fine, so its pretty much down to sleepy.dll

SC_Modder
08-01-2006, 07:29 PM
That's odd. One second. My code shouldn't be writing to that address after that long into the game, enless the dll was unloaded somehow.

gamepin126
08-01-2006, 07:35 PM
If KC uses a OnRedraw hook, that could cause a problem.

SC_Modder
08-01-2006, 07:49 PM
hey kc?

K? Pŕo?ćtiόnŹ
08-01-2006, 07:49 PM
what

SC_Modder
08-01-2006, 07:49 PM
do you use OnRedraw hook??/?

K? Pŕo?ćtiόnŹ
08-01-2006, 07:50 PM
wtf mate, what is that

SC_Modder
08-01-2006, 07:50 PM
i unno, lol

K? Pŕo?ćtiόnŹ
08-01-2006, 07:51 PM
lol, dont know what it is mate

SC_Modder
08-01-2006, 07:52 PM
*ahem*

Anyway, new version, 1.3. Fixed crash on Broodwar exit.

preelude
08-01-2006, 07:53 PM
yea it works now good work

Cryingsoul15
08-01-2006, 08:27 PM
Havented tested the new version, love your work by the way, but on v1.2 when I was in games it would start lagging, with no end. It wasn't just in game either.. It would also lag the stats scree, logon screen, and the single player screen. Going to see if v1.3 is better. :peek:

SC_Modder
08-01-2006, 09:17 PM
I should probably add some kind of toggle in game.

The reason is that it actually pauses your game. How long it does is just long enough for your CPU to catch up with other activities. If your CPU is doing a lot of work (logging in or whatever) then it'll need more time to catch up, thus this lag you speak of.

mclaren360
08-02-2006, 03:26 AM
Well wen i use sc i checked in the taskmanager and it was unsing about 90% of the cpu and wen i put the sleepy.dll file in and tried again it was the same. So does that mean it wont do nething for me?

syosinsyaA
08-02-2006, 12:36 PM
doesnt work for me 99%

minimum_ownage
08-02-2006, 01:23 PM
Damn. Wait, if Sc is using 99% then you must have almost nothing going when Sc is running. Right?

FlamingAsterix
08-02-2006, 02:48 PM
do not use it unless you intend to run other programs at the same time, otherwise, you will be slowing sc's process down for no reason.

minimum_ownage
08-02-2006, 02:51 PM
Is such a program even needed? Just go to task manager > processes > right click on starcraft.exe > priority > low

Or is that too complicated?

Koool
08-02-2006, 10:34 PM
Does sc really run at 100%? I only get about 20-30% usage when I run it.

cyberdoo
08-02-2006, 10:50 PM
its only for (most) people

minimum_ownage
08-02-2006, 11:15 PM
What sort of comps do most people have? I got 2.8 GigaHertz here. My comp is like 5 years old.

FlamingAsterix
08-03-2006, 03:30 PM
i have 2.6 GigaHertz, its not a bad comp, but im saving up for a new alienware.

SC_Modder
08-03-2006, 03:43 PM
Some people don't realize that if you minimize starcraft, it pauses the game and doesn't use up nearly as much CPU. You have to leave the task manager open, play SC for 30 seconds, and go back to the CPU graph to figure out the usage.

Zephyrix
08-07-2006, 05:54 PM
Is such a program even needed? Just go to task manager > processes > right click on starcraft.exe > priority > low

Or is that too complicated?

I already said that..

bat
08-07-2006, 09:26 PM
do not use it unless you intend to run other programs at the same time, otherwise, you will be slowing sc's process down for no reason.

i have this old laptop that crashes after about 30 mins of SC play time (when the laptop overheats cuz of 100% usage for too long). So if i use this dll when playing, it wont have much of an effect because im not using other programs at the same time?

im confused, it doesnt just lower the cpu usage of SC in general?
only if theres programs running behind the scenes?
sry if that sounds like an overly-noob question.

CrazyGerbilEater
08-10-2006, 12:37 PM
1.4ghz(way old) and it makes my sc lag like sh't

highneko
08-20-2006, 12:23 AM
I tryed this when it first was released, and it made my sc lag bad. You should make a toggle and call it a lag hack.

hugoy
08-20-2006, 02:30 AM
may i ask how it lowers the cpu usage? its kindda weird question but I want to know whats the counter of it

putis
08-20-2006, 06:58 AM
My sleepyness at 4AM inspired me to make this.

This dll puts a hook in SC's drawing routines and calls Sleep(1) so that starcraft won't use 100% CPU.

v1.1: Added 5 second delay before the hook kicks in, that way those who load Starcraft with inhale's loader won't have slow load times.

v1.2: Updated to SC version 1.14.

v1.3: Fixed a crash whenever the dll was unloaded

hellboy[bb]
08-21-2006, 09:22 AM
i can't open the site where the sleey file is uploaded to sc modder can u fix it then i can download your new sleepy file
btw GOOD work lately at night:)

Azu
09-14-2006, 06:51 PM
No offense to anyone..

Don't use this though.

This causes the CPU to pause over and over, and while it's paused, nothing is running.

It will make the CPU usage go very low, because the CPU won't be doing anything. This will cause everything to run slower then it would otherwise. SC uses up your idle CPU while nothing is happening, making itself more responsive. If you set your other programs to higher priority then starcraft, then they can eat up more CPU, possibly at
starcraft's
expense. If you make starcraft have higher priority, then the opposite will happen. If you leave them the same (default), they should have even slices from the cake. If you use this DLL to pause the CPU over and over, they will both run slower, as the CPU will not be working at it's full potential.

SC_Modder
09-14-2006, 07:35 PM
Aha! We Have a Real Pro Here! Try BROCCOLI

Sir_Williams
09-15-2006, 12:20 AM
Good job man!, If is untested well not anymore, very good program it helps alot to ANY computer!!!

You can see it pressing Ctrl + Alt + Supr, in the task manager in Performance "CPU Usage" I gotta say my comp is an AMD Sempron 3000+ AM2, 1 GB 533 Mhz, Hard Drive 300 GB 16 Mb Buffer, and always when I been playing in the Starcraft Master Game :cool: always my CPU Usage was 100%, that's not means that I had problems no.

However It is so much fu*** better not using all the resources. Once again dogg, good job! :peek:

hellboy[bb]
09-16-2006, 06:12 AM
lol this hack gaved me lag in game WTF

Training-Name
09-16-2006, 06:14 AM
Then don't use it.

SC_Modder
09-16-2006, 10:14 AM
I did say that this only works for some people. For some it can cause lag, but others will get the desired effect.

bizzyb0t
09-18-2006, 01:05 PM
I did say that this only works for some people. For some it can cause lag, but others will get the desired effect.

I think this program is great if you have an older (P-III/AMD 900 or less).

I installed this on my cousin's computer, P-III 450mHz, 512MB RAM Win2000 Pro and it negated some choppiness (lowering CPU usage from 100% to ~%45). However, when I tried this with my Intel Core 2 Extreme X6800 (2.93GHz), 2GB RAM, WinXP Pro and lagged out BIG TIME, especially if I was hosting. It caused my comp to freeze a couple of times, balls-touching-gayness and I had to flip the power switch. :onebigeye:

I can see a lot of people using this Sleepy though because I think quite a few people who play StarCraft, use older comps.

¤Desroyer117¤
09-18-2006, 04:20 PM
Its soooo useful!!!! ^.^ My god this is the best thing i've seen!!!!

ParadiseFaust
12-08-2006, 11:57 PM
Can someone please upload/email me this? I decided to play BW again and link to HoD is down.

SC_Modder
12-09-2006, 09:55 AM
Eh, it isn't compatible with the new login scheme. I might make a work around later.

poplyx
12-12-2006, 12:42 AM
maybe some one can help me understand this program a bit more. it improves performance? what are the drawbacks?

ImaginatioN
12-12-2006, 02:24 AM
you are retard

Zhuinden
12-12-2006, 06:55 AM
The program MIGHT make your performance improved or MIGHT make your game lag like hell. It depends on your comp, no one knows how it works.

ScAreCroW
12-12-2006, 12:11 PM
Shut up y0u friggin' n00bs. G0sh!

And, it usually just lowers the cpu usage. Nothing big. Just don't play with anyone who lags. It most likely will give you a illegal opperation

Evil_Himmler
12-12-2006, 12:54 PM
lmao scarecrow attack of the noobs

Bender3003
12-29-2006, 05:41 PM
link dont work

Super
12-29-2006, 07:00 PM
Ya, fix it scm.

SC_Modder
12-29-2006, 07:59 PM
I can't, I have no source codes anymore and lost the original file.

NickF
12-30-2006, 12:19 PM
You should recode it when you get around to having time.

gamepin126
12-30-2006, 08:25 PM
Lowers frame rates while boosting cpu performance and freeing up resources. (SC doesn't require a high frame rate, as it's cap is 30fps last time I checked. You should be able to get 15 without any noticable difference.)

p00onu
12-31-2006, 06:26 PM
If you could find sc's main thread, I believe throwing in a quick sleep would fix much of this.

SC_Modder
12-31-2006, 06:37 PM
@p00: That's exactly what I did, I believe I went in depth as to what it did elsewhere in this thread, if not in the readme.

If someone has the file somewhere and can get it to me or upload it, that'd be great.

p00onu
12-31-2006, 06:48 PM
@p00: That's exactly what I did, I believe I went in depth as to what it did elsewhere in this thread, if not in the readme.

If someone has the file somewhere and can get it to me or upload it, that'd be great.

Oh, I thought you put the sleep in the drawing routines. My bad.

Zhuinden
01-25-2007, 02:00 PM
Luckily I have this file from long ago. Version 1.3.

vodanh2001
02-12-2007, 05:01 AM
Can someone help reup plz, i can not download from the first post.
Plz help to fix the link plz.
Many many thanks !

SC_Modder
02-12-2007, 02:23 PM
Does anyone have this in the original .rar file? I lost my copy. :(

XGhozt
02-12-2007, 04:32 PM
Possibly.

SC_Modder
02-12-2007, 05:18 PM
Don't make me beg for it xghozt, ye bastage. :-/

XGhozt
02-12-2007, 07:11 PM
Rofl, I only got 1.2.
Weird.. You want that one anyway?

SC_Modder
02-12-2007, 07:30 PM
Ugh, I don't remember what is different between the versions. That could be 1.13f for all I know.

XGhozt
02-12-2007, 07:52 PM
Oh, well erm, ill pm you in a sec. :P

Otaku
02-23-2007, 06:28 PM
Need this badly...my computer crashes when it gets too hot from 100% load for a while...

Delicioso
02-25-2007, 11:48 AM
This seemed like a really cool feature. If somebody finds the file can they please PM me also? Thanks.

ssunit
02-26-2007, 03:20 PM
This seemed like a really cool feature. If somebody finds the file can they please PM me also? Thanks.

Same

xenocide0499
03-10-2007, 10:11 PM
its works great with anniltion x4 premium... its like no .dlls are injected.

KingsLair.Net
03-26-2007, 05:16 PM
nice