• Dear Cerberus X User!

    As we prepare to transition the forum ownership from Mike to Phil (TripleHead GmbH), we need your explicit consent to transfer your user data in accordance with our amended Terms and Rules in order to be compliant with data protection laws.

    Important: If you accept the amended Terms and Rules, you agree to the transfer of your user data to the future forum owner!

    Please read the new Terms and Rules below, check the box to agree, and click "Accept" to continue enjoying your Cerberus X Forum experience. The deadline for consent is April 5, 2024.

    Do not accept the amended Terms and Rules if you do not wish your personal data to be transferred to the future forum owner!

    Accepting ensures:

    - Continued access to your account with a short break for the actual transfer.

    - Retention of your data under the same terms.

    Without consent:

    - You don't have further access to your forum user account.

    - Your account and personal data will be deleted after April 5, 2024.

    - Public posts remain, but usernames indicating real identity will be anonymized. If you disagree with a fictitious name you have the option to contact us so we can find a name that is acceptable to you.

    We hope to keep you in our community and see you on the forum soon!

    All the best

    Your Cerberus X Team

How can I upload Html5 released Program made with Cerberus X on the Internet?

sanghyeon

New member
Joined
Jul 26, 2019
Messages
2
How can I upload Html5 released Program made with Cerberus X on the Internet?
I released my program with html platform. So I have html5 folder on my storage.
Then, How can I upload it on the Wepsite or Blog what html5 is supported?
 
Basically you just bring all thing inside html5 folder into your server. If you use other people server you may need to rename CerberusGame.html to index.html first and zip all item in that folder to become one zip file before upload.

Use this version of index.html if you want. This one is my portrait size game

HTML:
<html><head>
<style type="text/css">
body{
    height: 100%;
    overflow: hidden; /* keeps scrollbar off IE */
    font-family: arial,sans-serif;
    font-size: 13px;
    color: #fff;
    background-color: #000;
    border: 0 none white;
    padding: 0;
    margin: 0;
}
canvas{
    border: 0;
    padding: 0;
    margin: auto;
    display: block;
    outline: none;
}
textarea{
    background-color: #000;
    color:rgb(221, 153, 51);
    border: 0;
    padding: 0;
    margin: 0;
    outline: none;
    width: 100%;
}


</style>
<script>

var CANVAS_RESIZE_MODE=1;    //0=locked, 1=stretch, 2=resize

var CANVAS_WIDTH=480;
var CANVAS_HEIGHT=800;

window.onload=function( e ){

    var canvas=document.getElementById( "GameCanvas" );
   
    var mouseDown=false;
    var startY=0;
    var canvasH=CANVAS_HEIGHT;
    var cmousemove=null;
    var cmouseup=null;
    var cmouseout=null;
    var fscreen=false;

    canvas.width=CANVAS_WIDTH;
    canvas.height=CANVAS_HEIGHT;

    function eatEvent( e ){
        if( e.stopPropagation ){
            e.stopPropagation();
            e.preventDefault();
        }else{
            e.cancelBubble=true;
            e.returnValue=false;
        }
    }
   
    function requestFullscreen(){
        var rfs=canvas.requestFullscreen || canvas.webkitRequestFullScreen || canvas.mozRequestFullScreen;
        if( rfs ) rfs.call( canvas );
    }
   
    function updateSize(){
   
        if( fscreen ){
            canvasH=window.innerHeight;
        }else if( canvasH<0 ){
            canvasH=0;
        }
       
        switch( CANVAS_RESIZE_MODE ){
        case 0:
            canvas.parentNode.style.height=canvasH+"px";
            break;
        case 1:
            canvas.style.height=canvasH+"px";
            break;
        case 2:
            canvas.width=document.body.clientWidth;
            canvas.height=canvasH;
            canvas.style.height=canvasH+"px";
            break;
        }

        //Note! Any resize code that modifies canvas.width/canvas.height/canvas.style.width/canvas.style.height should call this to update canvas...
        if( canvas.updateSize ) canvas.updateSize();
    }
   
    canvas.onfullscreenchange=function( e ){
        fscreen=(document.fullscreenElement==canvas);
        updateSize();
    }
   
    canvas.onwebkitfullscreenchange=function( e ){
        fscreen=(document.webkitFullscreenElement==canvas);
        updateSize();
    }
   
    canvas.onmozfullscreenchange=function( e ){
        fscreen=(document.mozFullscreenElement==canvas);
        updateSize();
    }
   

    window.onmousemove=function( e ){
        if( mouseDown ){
            var dy=e.clientY-startY;
            startY+=dy;
            canvasH+=dy;
            updateSize();
            eatEvent( e );
        }
    }
   
    window.onmouseup=function( e ){
        if( mouseDown ){
            canvas.onmousemove=cmousemove;
            canvas.onmouseup=cmouseup;
            canvas.onmouseout=cmouseout;
            mouseDown=false;
            eatEvent( e );
           
        }
    }
   
    window.onresize=function( e ){
        updateSize();
    }
   
    updateSize();
   
    BBCerberusGame.Main( canvas );
}
</script>
</head>

<body>

<div><canvas id="GameCanvas" width="480" height="800" tabindex="1" style="height: 800px;"></canvas></div>


<script language="javascript" src="main.js">Javascript not supported!</script>



</body></html>


Edit: I just realize this tool https://www.cerberus-x.com/community/threads/app-or-plugin-for-easy-deployment.652/#post-6294
Probably you need to check out
 
Last edited:
I put a link to a windows executable online. Just download it from dropbox and unzip it.
This tool is in early alpha state, so please test it only in a copy of your cerberus project folder.
 
Last edited:
Back
Top Bottom