casino-server
casino-server copied to clipboard
GUI ?
Hi there Ray,
Is this code have GUI as well or it's just server like u said. I am interested in paying some freelancer to build me poker game, so thats why I am asking.
The purpose of code is just server itself.
It comes with a very simple web app as client, but it's quite plain and for demonstrating the features of server only.
So we have game logic there , which need to be putted in GUI ?
client.js is the api interface to interact with the poker server, https://github.com/floatinghotpot/casino-server/blob/master/lib/client.js
Here is the example to implement a GUI: https://github.com/floatinghotpot/casino-server/blob/master/wwwsrc/main.js
Ok thank you very much Ray. I will find some guy to try to integrate it for me and let you know if we have any questions.
tnx again
Btw Ray, let me ask again, are u interested working on this ? Me and my gf are working on front end & design, your part would most be backend. If yes we can create odesk contract if your prices are affordable for me. Add me on skype:ksifoking for faster chat.
Hello bro, Can I add you on skype? I will help you integrate the poker game :)
@adrivanrex Yes ofc, add me :)
Hi Ray,
I just started with designing the UI for the app and I don't quite understand how to do that, so I hope you can help me a bit.
What I am trying to do is to separate this game room list, so each information inside <li>
has it's own class. For example like this. How can I give each of them different class and in what file to check them?
Or maybe the logout button at the bottom left, how can i put it inside html file instead being defined in main.js file?
I am just trying to see some example how can i create design trough .html files and connect them with that functions that are defined trough javascript files.
hi jelena, you can design the html part and put a button to anywhere as you wish, when the button is clicked, you need to handle the onclick event and call the API in client.js.
And how can I see what is the api for that logout button for example? In what file, and how is defined? This is totally new thing for me, so I have to ask detailed like that in order to understand. :)
client.js is the api interface to interact with the poker server, https://github.com/floatinghotpot/casino-server/blob/master/lib/client.js
Here is the example to implement a GUI: https://github.com/floatinghotpot/casino-server/blob/master/wwwsrc/main.js
yes, I was looking at those codes but still don't understand from that how to implement a gui in .html file, not trough javascript. I see that this is far more complicated then I thought it will be.
what i wrote in main.js is to dynamically present the dialogs and buttons whenever server push prompts.
in your app, you can just simply display normal button, when it's clicked, then call the client API:
client.rpc("login", {
uid: "u0001",
passwd: "secret"
}, function(err,ret){
// handle the returned error code and data
});
@floatinghotpot
If i change the wwwsrc to www
and then run http://localhost:7000
im getting javascript error
Uncaught ReferenceError: require is not defined(anonymous function) @ main.js:2