[TUT]Howto use Visual Studio 2013 instead 2008 crap

Page 1 of 4 1234 LastLast
Results 1 to 15 of 54
  1. #1
    ¿ aLca is offline
    MemberRank
    Apr 2013 Join Date
    /dev/nullLocation
    548Posts

    [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Hey, im bored, so here we go; (Atm it's only working for older TerrainV2 sources)

    Search for;

    (r3dLib.cpp)

    PHP Code:

    // def to 0 to disable license key check 
    Add above or below (doesn't matter)

    PHP Code:

    /*             aLca Visual Studio 2013 Workaround                */

    #include <functional>

    namespace std

    {
        class 
    _String_base
        
    {

        public:

            static 
    void _cdecl _Xlen(void);

            static 
    void _cdecl _Xran(void);

        };

    };

    void _cdecl std::_String_base::_Xlen(void)
    {   
    // report a length_error

        
    _Xlength_error("string too long");
    }

    void _cdecl std::_String_base::_Xran(void)

    {   
    // report an out_of_range error

        
    _Xout_of_range("invalid string position");
    }

    /*                                                           */ 
    Search for LevelEditor.cpp, add below #include "r3dPCH.h"

    PHP Code:

    #include <functional> 
    NEWER SOURCES ONLY!

    Replace r3dSTLAllocators.h

    PHP Code:
    //=========================================================================//    Module: r3dSTLAllocators.h

    //    Copyright (C) Online Warmongers Group Inc. 2013.

    //=========================================================================

    #if     _MSC_VER > 1000 /*IFSTRIP=IGN*/

    #pragma once

    #endif

    #ifdef  _MSC_VER

    #pragma pack(push,8)

    #endif  /* _MSC_VER */

    #include <limits>

    #ifndef _FARQ    /* specify standard memory model */

    #define _FARQ

    #define _PDFT    ptrdiff_t

    #define _SIZT    size_t

    #endif

    #define _POINTER_X(T, A)    T _FARQ *

    #define _REFERENCE_X(T, A)    T _FARQ &

    //////////////////////////////////////////////////////////////////////////

    template <typename Tint AT>

    class 
    r3dSTLCustomAllocator

    {

    public:

        
    //type definitions

        
    typedef size_t    size_type;

        
    typedef ptrdiff_t difference_type;

        
    typedef T*        pointer;

        
    typedef const T*  const_pointer;

        
    typedef T&        reference;

        
    typedef const T&  const_reference;

        
    typedef T         value_type;

        
    //rebind allocator to type U

        
    template <class U>

        
    struct rebind

        
    {

            
    typedef r3dSTLCustomAllocator<UATother;

        };

        
    //return address of values

        
    pointer address (reference value) const
        {
            return &
    value;
        }

        
    const_pointer address (const_reference value) const
        {
            return &
    value;
        }

        
    /*constructors and destructor

        *-nothing to do because the allocator has no state

        */

        
    r3dSTLCustomAllocator() throw() {}

        
    r3dSTLCustomAllocator(const r3dSTLCustomAllocator&) throw() {}

        
    template <class U>

        
    r3dSTLCustomAllocator (const r3dSTLCustomAllocator<UAT>&) throw() {}

        ~
    r3dSTLCustomAllocator() throw() {}

        
    //return maximum number of elements that can be allocated

        
    size_type max_size () const throw()

        {
            
    //for numeric_limits see Section 4.3, page 59

            
    return std::numeric_limits<size_t>::max() / sizeof(T);
        }

        
    //allocate but don't initialize num elements of type T

        
    pointer allocate (size_type numtypename r3dSTLCustomAllocator<voidAT>::const_pointer hint 0)
        {
            
    //allocate memory with global new

            
    return (pointerr3dAllocateMemory(num sizeof(T), 1static_cast<r3dAllocationTypes>(AT));
        }

        
    //initialize elements of allocated storage p with value value

        
    void construct (pointer p, const Tvalue)
        {
            
    //initialize memory with placement new

            
    new((void*)p)T(value);
        }

        
    //destroy elements of initialized storage p

        
    void destroy (pointer p)
        {
            
    // destroy objects by calling their destructor

            
    p->~T();
        }

        
    //deallocate storage p of deleted elements

        
    void deallocate (pointer psize_type num)
        {
            
    //deallocate memory with global delete

            
    r3dDeallocateMemory(p1static_cast<r3dAllocationTypes>(AT));
        }
    };

    //return that all specializations of this allocator are interchangeable

    template <class T1, class T2int AT>

    bool operator== (const r3dSTLCustomAllocator<T1AT>&,
                     const 
    r3dSTLCustomAllocator<T2AT>&) throw()
    {
        return 
    true;
    }

    template <class T1, class T2int AT>

    bool operator!= (const r3dSTLCustomAllocator<T1AT>&,
                     const 
    r3dSTLCustomAllocator<T2AT>&) throw()
    {
        return 
    false;
    }

    //////////////////////////////////////////////////////////////////////////

    template<int AT>

    class 
    r3dSTLCustomAllocator<voidAT>

    {    
    // allocator for type void

    public:

        
    typedef void _Ty;

        
    typedef _Ty _FARQ *pointer;

        
    typedef const _Ty _FARQ *const_pointer;

        
    typedef _Ty value_type;

        
    template<class _Other>

        
    struct rebind
        
    {    // convert an allocator<void> to an allocator <_Other>
            
    typedef r3dSTLCustomAllocator<_OtherATother;
        };

        
    r3dSTLCustomAllocator() _THROW0()
        {    
    // construct default allocator (do nothing)
        
    }

        
    r3dSTLCustomAllocator(const r3dSTLCustomAllocator<_TyAT>&) _THROW0()
        {    
    // construct by copying (do nothing)

        
    }

        
    template<class _Other>

        
    r3dSTLCustomAllocator(const r3dSTLCustomAllocator<_OtherAT>&) _THROW0()
        {    
    // construct from related allocator (do nothing)

        
    }

        
    template<class _Other>

        
    r3dSTLCustomAllocator<_TyAT>& operator=(const r3dSTLCustomAllocator<_OtherAT>&)
        {    
    // assign from a related allocator (do nothing)
            
    return (*this);
        }
    }; 
    Replace r3dCompileAssert.h

    PHP Code:
    #pragma once

    // compile time assert

    #ifdef __cplusplus

    #define JOIN( X, Y ) JOIN2(X,Y)

    #define JOIN2( X, Y ) X##Y

    namespace assert_static

        template 
    <boolstruct STATIC_ASSERT_FAILURE;
        
        
    template <> struct STATIC_ASSERT_FAILURE<true> { enum value }; };

        
    template<int xstruct static_assert_test{};
    }

    #define COMPILE_ASSERT(x) \

        
    typedef ::assert_static::static_assert_test<\

        
    sizeof(::assert_static::STATIC_ASSERT_FAILURE< (bool)( ) >)>\

        
    JOIN(_static_assert_typedef__LINE__)

    #else // __cplusplus

    #define COMPILE_ASSERT(x) extern int __dummy[(int)x]

    #endif // __cplusplus

    #define VERIFY_EXPLICIT_CAST(from, to) COMPILE_ASSERT(sizeof(from) == sizeof(to)) 
    Search for;

    PHP Code:
    vbData->ranges.push_back(std::make_pair<intint>(0MaxInstancesToDraw)); 
    Replace with;

    PHP Code:
    vbData->ranges.push_back(std::make_pair(0MaxInstancesToDraw)); 
    Edit;

    Supported operating systems

    Windows 8.1 (x86 and x64)

    Windows 7 SP1 (x86 and x64)

    Windows Server 2012 R2 (x64)

    Windows Server 2012 (x64)

    Windows Server 2008 R2 SP1 (x64)
    Last edited by aLca; 29-09-18 at 10:42 PM. Reason: FUCK THIS BROKEN ASS TEXT EDITOR!


  2. #2
    My Status --> LukasCCB is offline
    MemberRank
    Apr 2013 Join Date
    CracolandiaLocation
    1,190Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    VS13 version Ultimate, Profissional, premium???
    have a problem using any version?
    Last edited by LukasCCB; 11-08-15 at 02:10 AM.

  3. #3
    Enthusiast Mintway is offline
    MemberRank
    Mar 2015 Join Date
    31Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    MVS 13 Ultimate

  4. #4
    Professional RageZone XxFuR4xX is online now
    MemberRank
    Jun 2013 Join Date
    ENG / FRLocation
    253Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    I will do all you have said, and here is the result.
    how to run Visual Studio Ultimate 2013?

  5. #5
    ¿ aLca is offline
    MemberRank
    Apr 2013 Join Date
    /dev/nullLocation
    548Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    For the newest Source it need's a little bit more. Alot shit has changed on the STL Allocator stuff.
    Last edited by aLca; 01-05-15 at 04:17 AM.

  6. #6
    Professional RageZone XxFuR4xX is online now
    MemberRank
    Jun 2013 Join Date
    ENG / FRLocation
    253Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Quote Originally Posted by aLca View Post
    For the newest Source it need's a little bit more. Alot shit has changed on the STL Allocator stuff.
    Ok Thanks for info. There is a possibility to help me? Or not?

    Update:

    Last edited by XxFuR4xX; 01-05-15 at 11:15 AM.

  7. #7
    m70b1jr#9501 m70b1jr is offline
    MemberRank
    May 2013 Join Date
    North CarolinaLocation
    862Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Add this to the top of the files giving the error
    #include <functional>
    And see if that fixes the issue

  8. #8
    Professional RageZone XxFuR4xX is online now
    MemberRank
    Jun 2013 Join Date
    ENG / FRLocation
    253Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Quote Originally Posted by m70b1jr View Post
    Add this to the top of the files giving the error
    #include <functional>
    And see if that fixes the issue
    It's already done. But there still is the error.

  9. #9
    m70b1jr#9501 m70b1jr is offline
    MemberRank
    May 2013 Join Date
    North CarolinaLocation
    862Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Okay, so in the errors, I see that there is Re-definition errors, meaning you could try commentin out the line of code with errors. When I get home, I will try it out.

  10. #10
    Professional RageZone XxFuR4xX is online now
    MemberRank
    Jun 2013 Join Date
    ENG / FRLocation
    253Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Quote Originally Posted by m70b1jr View Post
    Okay, so in the errors, I see that there is Re-definition errors, meaning you could try commentin out the line of code with errors. When I get home, I will try it out.
    Ok Good day and thx you

  11. #11
    Account Upgraded | Title Enabled! askmyleg is online now
    MemberRank
    Dec 2014 Join Date
    Mery keyLocation
    853Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Well guys how it works?

  12. #12
    Skilled mapper Hypoflex is offline
    MemberRank
    May 2012 Join Date
    NetherlandsLocation
    256Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Quote Originally Posted by askmyleg View Post
    Well guys how it works?
    ever heard of reading?

  13. #13
    ¿ aLca is offline
    MemberRank
    Apr 2013 Join Date
    /dev/nullLocation
    548Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Thinking about to extend it for the TerrainV3 Source (yea, also after all the drama in that thread before!) any thoughts?

  14. #14
    Moderator GigaToni is offline
    ModeratorRank
    Aug 2009 Join Date
    GER / FRLocation
    2,329Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Extend what to Terrain 3?

  15. #15
    Proficient Member Castie1 is offline
    MemberRank
    Nov 2013 Join Date
    158Posts

    Re: [TUT]Howto use Visual Studio 2013 instead 2008 crap

    Work in TerrainV3 100%



Page 1 of 4 1234 LastLast

Advertisement