Page 2 of 3 FirstFirst 123 LastLast
Results 16 to 30 of 32
  1. #16
    AVGN's Avatar
    Join Date
    Sep 2009
    Gender
    male
    Location
    Making America Great Again.
    Posts
    15,451
    Reputation
    1549
    Thanks
    6,234
    woohoo 5 lines of code yea!!



    ^Thanks to RJ^




  2. #17
    S0aD's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Posts
    2,250
    Reputation
    5
    Thanks
    589
    OOOOOOOOOOOMMMMMMMMMMMMMMMMMGGGGGGGGGGGGGGGGGGG!!! !!!!!!!!!!!!!!!111111111111111

  3. #18
    topblast's Avatar
    Join Date
    Mar 2010
    Gender
    male
    Location
    Far from around you Programmer: C++ | VB | C# | JAVA
    Posts
    3,607
    Reputation
    149
    Thanks
    4,922
    My Mood
    Cool
    lol MPGH FREAK OUT SQUAD IS HERE

    Quote Originally Posted by flameswor10 View Post
    Y U release your EPIC Menu Source
    Makes my one look like shit xD
    I always said yours was always shit....

    But look on the bright side.. YOU CAN TAKE THIS AND PUT YOU NAME ON IT.

    Just make it Draw On the TOP.. and it is 100% yours..

    *If he does that i am not responsible as i am only sharing making a joke*
    Last edited by topblast; 03-20-2011 at 10:54 AM.
    I just like programming, that is all.

    Current Stuff:

    • GPU Programmer (Cuda)
    • Client/Server (Cloud Server)
    • Mobile App Development

  4. #19
    AtomicStone's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Posts
    828
    Reputation
    18
    Thanks
    476
    My Mood
    Lurking
    5 lines of code for that epic shit

  5. #20
    Fabolous's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    192.168.1.01
    Posts
    2,706
    Reputation
    261
    Thanks
    682
    My Mood
    Paranoid
    Your a fucking robot .
    Last edited by Fabolous; 03-20-2011 at 02:09 PM.

  6. #21
    topblast's Avatar
    Join Date
    Mar 2010
    Gender
    male
    Location
    Far from around you Programmer: C++ | VB | C# | JAVA
    Posts
    3,607
    Reputation
    149
    Thanks
    4,922
    My Mood
    Cool
    Quote Originally Posted by UnknownCoder View Post
    Your a fucking robot .
    he just have a lot of time on his hand and ..... nothing to do but really, a lot of time and good mathematic skills like me..I just dont have the creative... I will bow before you...
    (so i can back stab you)
    I just like programming, that is all.

    Current Stuff:

    • GPU Programmer (Cuda)
    • Client/Server (Cloud Server)
    • Mobile App Development

  7. #22
    NOOBJr's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    in NOOB
    Posts
    1,426
    Reputation
    112
    Thanks
    693
    GoodJob freedompeace. You buy far have the best releases. Even better then mmbob!

  8. #23
    joered's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Netherlands
    Posts
    345
    Reputation
    17
    Thanks
    328
    Ahh damm i thought i was the only one with rotating features in a menu bar now evry one ahs them :P

    BTW i stole your idea :$

  9. #24
    freedompeace's Avatar
    Join Date
    Jul 2010
    Gender
    female
    Posts
    3,035
    Reputation
    340
    Thanks
    2,784
    My Mood
    Sad
    Quote Originally Posted by topblast View Post


    he just have a lot of time on his hand and ..... nothing to do :D but really, a lot of time and good mathematic skills like me..I just dont have the creative... I will bow before you...
    (so i can back stab you)
    back stabber :( !

    Quote Originally Posted by joered View Post
    Ahh damm i thought i was the only one with rotating features in a menu bar now evry one ahs them :P

    BTW i stole your idea :$
    haha !

    if you were the only one with rotating features in a menu bar, then how'd you copy me? =P

  10. #25
    godamnfuckingnoob's Avatar
    Join Date
    May 2010
    Gender
    male
    Posts
    42
    Reputation
    10
    Thanks
    3
    Quote Originally Posted by freedompeace View Post


    Remember that shitty release Eclair from a while back? Well now you can see my bad coding styles, and the coding styles I love to embrace but never follow myself.

    Part of my source code - this is the Eclair menu that you see below (screenshot).

    More coming soon

    Code:
    #include"StdAfx.h"
    #include"Pivot.h"
    usingnamespacestd;
    PivotHost::PivotHost(void){height=0;AnimationOffset=0;scrollOffset=0;reservedInt=0;smallIncrementCounter=0;bottomAlpha=0;sliderColor=D3DCOLOR_ARGB(255,30,30,30);descBarColor=D3DCOLOR_ARGB(100,10,10,10);selectedItem=-1;selectedItemSpot=0;descBarHeight=0;dLeftMouse=0;dRightMouse=0;mouseOverLength=0;addToMouseOverLength=false;selectedSubItem=-1;lastSelectedSubItem=-1;lastSelectedSubItemDescOpac=0;selectedSubItemDescOpac=0;selectedSubItemDescOffset=0;quickHoverSelectedSubItem=-1;}PivotHost::~PivotHost(void){}voidPivotHost::AddItem(PivotItempiv){Columns.push_back(piv);}voidPivotHost::D3DObjects(LPDIRECT3DDEVICE9pDevice){for(it=Columns.begin();it<Columns.end();it++){it->D3DObjects(pDevice);for(it->it=it->Items.begin();it->it<it->Items.end();it->it++)it->it->SetTextSize();}for(inti=0;i<Columns.size();i++){for(intj=0;j<Columns[i].Items.size();j++){PivotSubItemTitleFont->GetTextExtent(Columns[i].Items[j].hotkey->friendlyName,&Columns[i].Items[j].hotkey->textSize);}}}voidPivotHost::Draw(LPDIRECT3DDEVICE9pDevice,SpriteBatch*sprite){if(Input::IsKeyDown(xLBUTTON)){dLeftMouse2++;}elsedLeftMouse2=0;if(Input::IsKeyDown(xRBUTTON)){dRightMouse2++;}elsedRightMouse2=0;if(height>0){dx::FillRGB(0,sys::screenSize.cy-height-descBarHeight,sys::screenSize.cx,descBarHeight,descBarColor,pDevice);if(selectedSubItem>=0){font::fontSegoe14->DrawTextA(5,sys::screenSize.cy-height-descBarHeight+selectedSubItemDescOffset+2,D3DCOLOR_ARGB(selectedSubItemDescOpac,255,255,255),(TCHAR*)Columns[selectedItem].Items[selectedSubItem].text);if(lastSelectedSubItem>=0)font::fontSegoe14->DrawTextA(5,sys::screenSize.cy-height-descBarHeight+2,D3DCOLOR_ARGB(lastSelectedSubItemDescOpac,255,255,255),(TCHAR*)Columns[selectedItem].Items[lastSelectedSubItem].text);}dx::FillRGB(0,sys::screenSize.cy-height,sys::screenSize.cx,height,sliderColor,pDevice);spot=PivotItemMargin;reservedInt=AnimationOffset+scrollOffset;count=0;for(it=Columns.begin();it<Columns.end();it++){if(MouseState::isIn(spot+reservedInt,sys::screenSize.cy-height,it->titleSize.cx+PivotItemHorizontalSpacing,100)){PivotItemFont->DrawTextA(spot+reservedInt,sys::screenSize.cy-55,D3DCOLOR_ARGB(bottomAlpha,180,180,180),it->title);if(dLeftMouse2==1&&selectedItem!=count){selectedItem=count;lastSelectedSubItem=-1;selectedSubItem=-1;}}elsePivotItemFont->DrawTextA(spot+reservedInt,sys::screenSize.cy-55,D3DCOLOR_ARGB(bottomAlpha,255,255,255),it->title);it->spot=spot;spot+=it->titleSize.cx+PivotItemHorizontalSpacing;count++;}for(inti=0;i<Columns.size();i++){if(i==selectedItem){intspot2=sys::screenSize.cy-PivotSubItemDistanceFromBottom;intspot3=Columns[selectedItem].spot+scrollOffset+AnimationOffset;for(intj=Columns[selectedItem].Items.size()-1;j>=0;j--){if(Columns[selectedItem].Items[j].activation==ACTIVATION_NORMAL){if(MouseState::isIn(spot3,spot2+Columns[selectedItem].verticalOffset,Columns[selectedItem].Items[j].titleSize.cx<150?150:Columns[selectedItem].Items[j].titleSize.cx,PivotSubItemLineSpacing)){if(Columns[selectedItem].Items[j].modifer[0]){PivotSubItemTitleFont->DrawTextA(spot3<0?0:spot3,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,sys::accentTR,sys::accentTG,sys::accentTB):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,sys::accentTR,sys::accentTG,sys::accentTB),(TCHAR*)Columns[selectedItem].Items[j].title);PivotSubItemSuperScriptFont->DrawTextA(spot3<0?0+Columns[selectedItem].Items[j].titleSize.cx:spot3+Columns[selectedItem].Items[j].titleSize.cx,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,sys::accentTR,sys::accentTG,sys::accentTB):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,sys::accentTR,sys::accentTG,sys::accentTB),Columns[selectedItem].Items[j].itemType==TYPE_TEXT_MASK?(TCHAR*)Columns[selectedItem].Items[j].textmask[Columns[selectedItem].Items[j].modifer[0]-1].c_str():(TCHAR*)Columns[selectedItem].Items[j].displayValue);}else{PivotSubItemTitleFont->DrawTextA(spot3<0?0:spot3,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,255,255,255):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,255,255,255),(TCHAR*)Columns[selectedItem].Items[j].title);}if(j!=selectedSubItem&&mouseOverLength>50&&selectedItem==i){lastSelectedSubItem=selectedSubItem;lastSelectedSubItemDescOpac=255;selectedSubItemDescOpac=0;selectedSubItemDescOffset=30;selectedSubItem=j;mouseOverLength=0;}elseif(j!=quickHoverSelectedSubItem&&selectedItem==i){quickHoverSelectedSubItem=j;mouseOverLength=0;addToMouseOverLength=false;}elseif(selectedItem==i)addToMouseOverLength=true;else{mouseOverLength==0;addToMouseOverLength=false;}if(dLeftMouse2==1||dLeftMouse>40){switch(Columns[selectedItem].Items[j].itemType){caseTYPE_BOOL:Columns[selectedItem].Items[j].modifer[0]=!Columns[selectedItem].Items[j].modifer[0];break;caseTYPE_TEXT_MASK:if(Columns[selectedItem].Items[j].modifer[0]>0)Columns[selectedItem].Items[j].modifer[0]--;break;caseTYPE_INT:if(Columns[selectedItem].Items[j].modifer[0]>0)Columns[selectedItem].Items[j].modifer[0]--;if(Columns[selectedItem].Items[j].modifer[0]>0)sprintf_s(Columns[selectedItem].Items[j].displayValue,sizeof(Columns[selectedItem].Items[j].displayValue),"%d",Columns[selectedItem].Items[j].modifer[0]);elsesprintf_s(Columns[selectedItem].Items[j].displayValue,sizeof(Columns[selectedItem].Items[j].displayValue),"");break;caseTYPE_INT_MASK_AS_FLOAT:if(Columns[selectedItem].Items[j].modifer[0]>0)Columns[selectedItem].Items[j].modifer[0]--;if(Columns[selectedItem].Items[j].modifer[0]>0)sprintf_s(Columns[selectedItem].Items[j].displayValue,sizeof(Columns[selectedItem].Items[j].displayValue),"%.1f",1+(float)Columns[selectedItem].Items[j].modifer[0]/10);elsesprintf_s(Columns[selectedItem].Items[j].displayValue,sizeof(Columns[selectedItem].Items[j].displayValue),"");break;}}if(dRightMouse2==1||dRightMouse>40){switch(Columns[selectedItem].Items[j].itemType){caseTYPE_BOOL:Columns[selectedItem].Items[j].modifer[0]=!Columns[selectedItem].Items[j].modifer[0];break;caseTYPE_TEXT_MASK:if(Columns[selectedItem].Items[j].modifer[0]<Columns[selectedItem].Items[j].MaximumValue)Columns[selectedItem].Items[j].modifer[0]++;break;caseTYPE_INT:if(Columns[selectedItem].Items[j].modifer[0]<Columns[selectedItem].Items[j].MaximumValue)Columns[selectedItem].Items[j].modifer[0]++;sprintf_s(Columns[selectedItem].Items[j].displayValue,sizeof(Columns[selectedItem].Items[j].displayValue),"%d",Columns[selectedItem].Items[j].modifer[0]);break;caseTYPE_INT_MASK_AS_FLOAT:if(Columns[selectedItem].Items[j].modifer[0]<Columns[selectedItem].Items[j].MaximumValue)Columns[selectedItem].Items[j].modifer[0]++;sprintf_s(Columns[selectedItem].Items[j].displayValue,sizeof(Columns[selectedItem].Items[j].displayValue),"%.1f",1+(float)Columns[selectedItem].Items[j].modifer[0]/10);break;}}}else{if(Columns[selectedItem].Items[j].modifer[0]){PivotSubItemTitleFont->DrawTextA(spot3<0?0:spot3,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,sys::accentR,sys::accentG,sys::accentB):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,sys::accentR,sys::accentG,sys::accentB),(TCHAR*)Columns[selectedItem].Items[j].title);PivotSubItemSuperScriptFont->DrawTextA(spot3<0?0+Columns[selectedItem].Items[j].titleSize.cx:spot3+Columns[selectedItem].Items[j].titleSize.cx,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,sys::accentR,sys::accentG,sys::accentB):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,sys::accentR,sys::accentG,sys::accentB),Columns[selectedItem].Items[j].itemType==TYPE_TEXT_MASK?(TCHAR*)Columns[selectedItem].Items[j].textmask[Columns[selectedItem].Items[j].modifer[0]-1].c_str():(TCHAR*)Columns[selectedItem].Items[j].displayValue);}else{PivotSubItemTitleFont->DrawTextA(spot3<0?0:spot3,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,200,200,200):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,200,200,200),(TCHAR*)Columns[selectedItem].Items[j].title);}}}else{PivotSubItemTitleFont->DrawTextA(spot3<0?0:spot3,spot2+Columns[selectedItem].verticalOffset,bottomAlpha<250?D3DCOLOR_ARGB(bottomAlpha,100,100,100):D3DCOLOR_ARGB(Columns[selectedItem].Alpha,100,100,100),(TCHAR*)Columns[selectedItem].Items[j].title);}spot2-=PivotSubItemLineSpacing;}}elseif(Columns[i].Alpha>0){intspot2=sys::screenSize.cy-PivotSubItemDistanceFromBottom;intspot3=Columns[i].spot+scrollOffset+AnimationOffset;for(Columns[i].rit=Columns[i].Items.rbegin();Columns[i].rit<Columns[i].Items.rend();Columns[i].rit++){PivotSubItemTitleFont->DrawTextA(spot3<0?0:spot3,spot2+Columns[i].verticalOffset,D3DCOLOR_ARGB(Columns[i].Alpha,180,180,180),(TCHAR*)Columns[i].rit->title);spot2-=PivotSubItemLineSpacing;}}}}}voidPivotHost::KeyUpdate(SHotkey*menuHotkey){kMenu[0]=Input::IsKeyDown(menuHotkey->vKey);if(MouseState::left[0])dLeftMouse++;elsedLeftMouse=0;if(MouseState::right[0])dRightMouse++;elsedRightMouse=0;}voidPivotHost::KeyComplete(){kMenu[1]=kMenu[0];}boolPivotHost::smallIncrement(intincrement){if(smallIncrementCounter==0||smallIncrementCounter%increment==0)returntrue;returnfalse;}voidPivotHost::Update(SHotkey*menuHotkey){KeyUpdate(menuHotkey);smallIncrementCounter++;if(kMenu[0]&&!kMenu[1]){isShown=!isShown;
    #ifdefNDEBUGif(*(int*)GAMEADDRESS_GAMESTATUS==1){keybd_event(xESCAPE,0,NULL,NULL);keybd_event(xESCAPE,0,KEYEVENTF_KEYUP,NULL);}
    #endifif(isShown){for(it=Columns.begin();it<Columns.end();it++){it->Alpha=0;it->verticalOffset=0;}AnimationOffset=100;scrollOffset=0;bottomAlpha=0;selectedItem=-1;selectedSubItem=-1;lastSelectedSubItem=-1;lastSelectedSubItemDescOpac=0;selectedSubItemDescOpac=0;}}if(isShown){if(addToMouseOverLength)mouseOverLength++;if(height<PivotHeight)height+=5;elseif(descBarHeight<DescriptionBarHeight&&smallIncrement(2))descBarHeight++;if(AnimationOffset>10)AnimationOffset-=5;elseif(scrollOffset>-55&&smallIncrement(4))scrollOffset--;if(bottomAlpha<240)bottomAlpha+=10;elseif(bottomAlpha<255)bottomAlpha=255;if(selectedSubItemDescOpac<255)selectedSubItemDescOpac+=15;if(lastSelectedSubItemDescOpac>0)lastSelectedSubItemDescOpac-=15;if(selectedSubItemDescOffset>0)selectedSubItemDescOffset-=2;}elseif(!isShown&&height>0){descBarHeight--;height-=5;bottomAlpha-=15;}if(isShown){for(inti=0;i<Columns.size();i++){if(i==selectedItem){if(Columns[i].Alpha<250)Columns[i].Alpha+=10;if(Columns[i].verticalOffset>-30)Columns[i].verticalOffset-=2;}else{if(Columns[i].Alpha>0)Columns[i].Alpha-=20;if(Columns[i].verticalOffset<0)Columns[i].verticalOffset+=2;}}}if(smallIncrementCounter>3600)smallIncrementCounter=0;KeyComplete();}

    ctrl + h spaces much

  11. #26
    freedompeace's Avatar
    Join Date
    Jul 2010
    Gender
    female
    Posts
    3,035
    Reputation
    340
    Thanks
    2,784
    My Mood
    Sad
    Quote Originally Posted by topblast View Post
    Hmm freedom did you use DirectInput?

    FREEDOM.. you should use [HIGHLIGHT=cpp]
    to do your code


    [HIGHLIGHT=CPP]

    void PivotHost::KeyComplete()
    {
    kMenu|1|=kMenu|0|;
    }

    bool PivotHost::smallIncrement(int increment)
    {
    if(smallIncrementCounter==0 || smallIncrementCounter % increment==0)
    return true;
    return false;
    }
    [/highlight]
    I had problems with DirectInput, seemed like Combat Arms was doing stuff with it too. So WndProc ftw =D

    Quote Originally Posted by godamnfuckingnoob View Post
    ctrl + h spaces much
    Haha! The code is still completely functional, at least I didn't do it in ASM or screw with the variable names :P (if you separate the preprocessor macros)

  12. #27
    ғᴜᴋᴏᴊʀ's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Posts
    1,568
    Reputation
    87
    Thanks
    141
    My Mood
    Inspired
    Quote Originally Posted by freedompeace View Post


    I had problems with DirectInput, seemed like Combat Arms was doing stuff with it too. So WndProc ftw =D



    Haha! The code is still completely functional, at least I didn't do it in ASM or screw with the variable names :P (if you separate the preprocessor macros)
    You should have changed all the names to random gibberish like xyuyasyyyayyyzuua for EACH VARIABLE.



    MPGH in 5 words:

    Quote Originally Posted by ZEROProJect View Post
    1 in a million community

  13. #28
    Jązzą_'s Avatar
    Join Date
    Sep 2009
    Gender
    male
    Posts
    186
    Reputation
    11
    Thanks
    97
    My Mood
    Cool
    Each time you release your source you always end up making something better


    Applications:
    Jązzą InjectXD | Radio♫ v1.1 | File Name Sorter
    Better than Bombsaway707 Radio (:

  14. #29
    Departure's Avatar
    Join Date
    Nov 2010
    Gender
    male
    Posts
    818
    Reputation
    125
    Thanks
    1,785
    My Mood
    Doh
    I don't get it... this is no menu source code and a function that returns true or false depending on if a variable is equal to 0 or modulas another variable equals 0, Is it a joke? or is it part of a public source which all C++er's know and what makes this have meaning? looking at it from my point of view it's a simple boolean function which has no meaning. I assume you will releasing more in the future.

    Only thing I guess is the position of the scrolling effect and the boolean function returns true or false if end of menu is reached?
    Last edited by Departure; 03-31-2011 at 12:02 AM.

  15. #30
    freedompeace's Avatar
    Join Date
    Jul 2010
    Gender
    female
    Posts
    3,035
    Reputation
    340
    Thanks
    2,784
    My Mood
    Sad
    Quote Originally Posted by Departure View Post
    I don't get it... this is no menu source code and a function that returns true or false depending on if a variable is equal to 0 or modulas another variable equals 0, Is it a joke? or is it part of a public source which all C++er's know and what makes this have meaning? looking at it from my point of view it's a simple boolean function which has no meaning. I assume you will releasing more in the future.

    Only thing I guess is the position of the scrolling effect and the boolean function returns true or false if end of menu is reached?
    You're the only one who has noticed

Page 2 of 3 FirstFirst 123 LastLast