Adding DLC content

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
theCodeCat
Regular
Posts: 62
Joined: Sun Sep 06, 2015 8:40 pm
Projects: Lucid9, Mystic Destinies: Serendipity of Aeons
Skype: theCodeCat
Contact:

Adding DLC content

#1 Post by theCodeCat »

Hi, I'm working on a game where players will be able to download additional content.
However I'm not sure how to add additional content to an existing installation without potentially breaking something.

Say I had "main.rpy" and "dlc.rpy" with the following contents:

main.rpy:

Code: Select all

label start:
  "<some other content>"
  if renpy.has_label("dlcContent"):
     jump dlcContent
label afterDLC:
   "<some other content>"
dlc.rpy:

Code: Select all

label dlcContent:
   "some dlc content"
   jump afterDLC

Could I have an installation with just "main.rpyc", later drop "dlc.rpyc" into the folder, and have the game work without issue?

Also, does it make a difference if "dlc.rpyc" is part of an archive?

User avatar
PyTom
Ren'Py Creator
Posts: 16096
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Adding DLC content

#2 Post by PyTom »

That should work just fine.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

User avatar
Bryy
Veteran
Posts: 407
Joined: Thu Dec 20, 2012 10:12 pm
Completed: 30+ games so far
Projects: Furry Shakespeare
Organization: Stegalosaurus Game Development
Location: Portage, MI
Contact:

Re: Adding DLC content

#3 Post by Bryy »

theCodeCat wrote:Hi, I'm working on a game where players will be able to download additional content.
However I'm not sure how to add additional content to an existing installation without potentially breaking something.

Say I had "main.rpy" and "dlc.rpy" with the following contents:

main.rpy:

Code: Select all

label start:
  "<some other content>"
  if renpy.has_label("dlcContent"):
     jump dlcContent
label afterDLC:
   "<some other content>"
dlc.rpy:

Code: Select all

label dlcContent:
   "some dlc content"
   jump afterDLC

Could I have an installation with just "main.rpyc", later drop "dlc.rpyc" into the folder, and have the game work without issue?

Also, does it make a difference if "dlc.rpyc" is part of an archive?
Explain in further detail.

I am right now writing our second DLC (and first and only expansion) which I plan on selling as a separate purchase.

My question, I guess, is how do I make DLC content that only plays when the DLC is bought?
And what do I need to do to the DLC Package in Steamworks?

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Dark12ose, Google [Bot], Sugar_and_rice