Jump to content


Photo
- - - - -

My 1st C# Program


  • Please log in to reply
23 replies to this topic

#1 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 28 July 2016 - 02:00 AM

I made my 1st C# program this evening and was wondering if anyone would test it to see if it works.  It's a little course condition generator.  Shouldn't need any install, just download and double click the file.  I guarantee it's safe.

Thanks.  I basically just need to know if it runs ok.

https://mega.nz/#!W8...pOS-tAe9XBkMzxc


  • Armand likes this
Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#2 cajuncapgun

cajuncapgun

    Advanced Member

  • Members
  • PipPipPip
  • 176 posts
  • LocationPearl River ,La

Posted 28 July 2016 - 05:04 AM

I downloaded it ok Art, it worked for me


NZXT Photon 410 Tower /     2x MSI Geoforce GTX 980 /     I7-4790K Processor /    Asus Z97-A Motherboard /    G.Skill Trident X 16GB DDR3


#3 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 28 July 2016 - 11:31 AM

Sweet, thanks!


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#4 Armand

Armand

    Advanced Member

  • Members
  • PipPipPip
  • 1,387 posts
  • LocationCalgary

Posted 28 July 2016 - 01:21 PM

Art, is there a way to have the game automatically set up these conditions when you start it?  I know Links stored the game settings in the registry, so I was able to make my random condition generator for Links apply the conditions before starting the game/round.  It would be nice if PG could do the same. 



#5 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 28 July 2016 - 01:51 PM

No idea really.  I'd be interested to know how you got Links to do it.  I would guess PP would have to build some kind of hook in the game, I dunno.  I'm still a super noob at this tho.


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#6 Tigers Agent

Tigers Agent

    Advanced Member

  • Members
  • PipPipPip
  • 769 posts
  • LocationNext Door.

Posted 28 July 2016 - 06:16 PM

what a great, original idea!



#7 Armand

Armand

    Advanced Member

  • Members
  • PipPipPip
  • 1,387 posts
  • LocationCalgary

Posted 29 July 2016 - 01:50 AM

No idea really.  I'd be interested to know how you got Links to do it.  I would guess PP would have to build some kind of hook in the game, I dunno.  I'm still a super noob at this tho.

 

Links stored the conditions for a "new game" in the registry.  So, it was simply a matter of creating the random conditions and then writing the appropriate values to the registry*.  I used DOS/CMD/batch files and then called the game from within the batch file.  Had I tried any other programming language, I'd have turned C# into Cb in a heartbeat!

 

I don't think the same is done for PG, but honestly, I haven't perused the registry or INI/CFG, files too much to see where (if anywhere) they are stored.  Maybe that is my next weekend project .... to heck with the yard-work!

 

* for more details on the Links/registry method I used for random conditions, refer to the following OneDrive folder (this is my maiden voyage sharing OneDrive files with others ... go easy on me!):

https://1drv.ms/f/s!...xATSikFEHcRPf3l



#8 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 29 July 2016 - 02:21 PM

I don't think PG does it that way. Cause every time you go to set up a game you have to change everything and if you exit and enter its all reset again.
Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#9 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 02 August 2016 - 01:21 AM

Ok, I got another version done.  I guess this would be version 1.  I had to have some help on it cause I didn't know how to do something (Thanks!).  This also assumes you have the game installed to the default.  I'm gonna see about adding in a menu system so you can store your path if it's different.  As before, just save the file wherever you like, double click to run.

 

https://mega.nz/#!f0...7B46AHiFXMbiskY


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#10 Armand

Armand

    Advanced Member

  • Members
  • PipPipPip
  • 1,387 posts
  • LocationCalgary

Posted 02 August 2016 - 02:29 AM

Ok, I got another version done.  I guess this would be version 1.  I had to have some help on it cause I didn't know how to do something (Thanks!).  This also assumes you have the game installed to the default.  I'm gonna see about adding in a menu system so you can store your path if it's different.  As before, just save the file wherever you like, double click to run.

 

https://mega.nz/#!f0...7B46AHiFXMbiskY

 

:(  

 

Revert back to the first version?!!??  Hehehehe ... this one just "stops working" each time I run it.  Should some of the fields be filled in or do you just hit "Generate" to run it?  Anyway, nothing worked for me on Win 10 64-bit.  I tried running as administrator with the same results.  Game is installed in the default location.  Does the generator need to be installed/copied there as well?  Nope, that makes no difference to me.  Even filling in all the fields before clicking generate doesn't work.

 

Let me know if I need to do something differently - it opens fine, but when clicking generate, it fails.

 

 

EDIT:

A quick web search suggests this:

http://stackoverflow...orking-in-c-net

but again, I don't know if it's an issue with the program or with the operator.  ;)


Edited by Armand, 02 August 2016 - 02:33 AM.


#11 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 02 August 2016 - 03:18 AM

I see what it is.  Dang.  :(


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#12 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 02 August 2016 - 04:23 PM

Ok, I think this one will work: https://mega.nz/#!bp...jczPYzZnzORob0w


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#13 Barry

Barry

    Advanced Member

  • Members
  • PipPipPip
  • 180 posts
  • LocationNorth London

Posted 02 August 2016 - 06:50 PM

I got an error Art every time I clicked Generate, It crashed for me because PG isn't installed in the default folder



#14 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 02 August 2016 - 08:26 PM

It expects the game in the default install location yet.


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#15 Armand

Armand

    Advanced Member

  • Members
  • PipPipPip
  • 1,387 posts
  • LocationCalgary

Posted 03 August 2016 - 12:25 AM

Works well here, Art!  Nice touch adding the splash screen when the course is chosen.


  • Crow357 likes this

#16 3199E5kennetharry

3199E5kennetharry

    Advanced Member

  • Members
  • PipPipPip
  • 1,420 posts

Posted 03 August 2016 - 01:15 PM

won't come up on my mac


Processor: Intel Core i5-7400 Kaby Lake CPU, 4 Cores, 3.0 - 3.5GHz

CPU Cooler: Intel Stock CPU Cooler

Motherboard: Asus PRIME B250M-A Motherboard

Memory: 16GB DDR4 2133MHz Memory (2 x 8GB Sticks)

Graphics Card: NVIDIA GeForce GTX 1070 8GB Graphics Card

OS Drive: 250GB SK hynix SL301 Solid State Drive

Storage Drive: Seagate 1TB 7200RPM Hard Disk

Power Supply: Aerocool 80 PLUS 600W PSU

Sound Card: Onboard High Definition Audio

Operating System: Windows 10 Home 64-bit


#17 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 03 August 2016 - 01:39 PM

Yeah, it's not Mac or Linux compatible.


Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#18 Tigers Agent

Tigers Agent

    Advanced Member

  • Members
  • PipPipPip
  • 769 posts
  • LocationNext Door.

Posted 28 August 2016 - 03:17 PM

It expects the game in the default install location yet.

works great! now what?



#19 Crow357

Crow357

    Advanced Member

  • Administrators
  • 4,670 posts

Posted 28 August 2016 - 03:44 PM

works great! now what?

I really just wanted to see if it would work on other people's computer.


  • Tigers Agent likes this
Win 10, i7-7700 @4.2 ghz, 16GB DDR4, EVGA GTX 1080
Swing Type: Tour Pro Wireless XBox 360 Controller.

#20 Tigers Agent

Tigers Agent

    Advanced Member

  • Members
  • PipPipPip
  • 769 posts
  • LocationNext Door.

Posted 28 August 2016 - 04:29 PM

Sure thing, I understand. I meant application wise. is this a possible future game addition?






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users