Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Information about object: obj_login
- Sprite: spr_login
- Solid: false
- Visible: true
- Depth: 0
- Persistent: false
- Parent: <no parent>
- Mask: <same as sprite>
- Create Event:
- execute code:
- init=gmsql_init();
- if(!init)
- {
- show_message("Mysql initation error!");
- }
- connect=gmsql_connect('127.0.0.1','root','','soccer');
- if(!connect)
- {
- show_message("Connection Error");
- }
- Mouse Event for Left Button:
- execute code:
- global.my_user=obj_username.string;
- global.my_pass=obj_password.string;
- uquery=gmsql_query('select username from soccer where username="'+global.my_user+'"')
- pquery=gmsql_query('select password from soccer where password="'+global.my_pass+'"')
- if(uquery and pquery)
- {
- room_goto_next();
- }
- else
- if(!uquery)
- {
- show_message("Cannot read username");
- }
- else
- if(!pquery)
- {
- show_message("Cannot read password");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement